fix: removed redundant step from drone
continuous-integration/drone/push Build is passing Details

This commit is contained in:
Giles Bradshaw 2020-08-04 21:54:49 +01:00
parent dbe2734076
commit f11b192cbd
2 changed files with 16 additions and 64 deletions

View File

@ -180,39 +180,24 @@ local images = {
images.wait(15),
util.compose(
std.map(
function(secret) util.printEnv('afile', secret),
publicSecrets,
)
)(
images.ssh {
name: 'will print ssh-host again',
settings +: {
script +: [
'rm afile'
],
},
},
),
util.compose(
std.map(
function(s) util.envSet(s),
publicSecrets + secretSecrets
) +
std.map(
function(s) function(step) step {
settings +: {
script +: [
'export %(env)s="$${%(env)s}"' % {
env: util.environment(s),
},
'echo "$${%s}"' % util.environment(s),
],
},
function(s) util.envSet(s),
publicSecrets + secretSecrets
) +
std.map(
function(s) function(step) step {
settings +: {
script +: [
'export %(env)s="$${%(env)s}"' % {
env: util.environment(s),
},
'echo "$${%s}"' % util.environment(s),
],
},
publicSecrets + secretSecrets
)
},
publicSecrets + secretSecrets
)
)
(
images.ssh {
name: 'deploy squid',

View File

@ -29,39 +29,6 @@ steps:
commands:
- sleep 15
- name: will print ssh-host again
image: appleboy/drone-ssh
settings:
envs:
- drone_tag
- drone_commit
- drone_build_number
- drone_repo_name
- drone_repo_namespace
- ssh_host
- ssh_user
- ssh_root_user
host:
from_secret: ssh-host
password:
from_secret: ssh-password
port:
from_secret: ssh-port
script:
- rm afile
- "echo \"export SSH_HOST='$${SSH_HOST}'\" >> afile # \"ssh-host\""
- "echo \"export SSH_USER='$${SSH_USER}'\" >> afile # \"ssh-user\""
- "echo \"export SSH_ROOT_USER='$${SSH_ROOT_USER}'\" >> afile # \"ssh-root-user\""
username:
from_secret: ssh-user
environment:
SSH_HOST:
from_secret: ssh-host
SSH_ROOT_USER:
from_secret: ssh-root-user
SSH_USER:
from_secret: ssh-user
- name: deploy squid
image: appleboy/drone-ssh
settings: