.
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
7e95348e7a
commit
1c16cd026f
13
.drone.star
13
.drone.star
|
@ -8,6 +8,8 @@ def environment(env):
|
||||||
)
|
)
|
||||||
def map(fn, l):
|
def map(fn, l):
|
||||||
return [fn(x) for x in l]
|
return [fn(x) for x in l]
|
||||||
|
def echo(x):
|
||||||
|
return "echo {secret}=${environment} >> env-stack".format(secret = x, environment = x.replace("-", "_"))
|
||||||
def identity(x): return x
|
def identity(x): return x
|
||||||
def printSecrets(env):
|
def printSecrets(env):
|
||||||
envv = map(identity, env)
|
envv = map(identity, env)
|
||||||
|
@ -23,15 +25,8 @@ def printSecrets(env):
|
||||||
"username": fromSecret("ssh-user"),
|
"username": fromSecret("ssh-user"),
|
||||||
"password": fromSecret("ssh-password"),
|
"password": fromSecret("ssh-password"),
|
||||||
"script": [
|
"script": [
|
||||||
"echo $(($(date +%s%N)/1000000))",
|
"rm -f env.stack",
|
||||||
"echo SSH_HOST=$SSH_HOST > env-stack",
|
] + map(echo, env)
|
||||||
"sleep 5",
|
|
||||||
"echo SSH_PORT=$SSH_PORT >> env-stack",
|
|
||||||
"echo LOCAL_DOCKER_REGISTRY=$LOCAL_DOCKER_REGISTRY >> env-stack",
|
|
||||||
"echo $(($(date +%s%N)/1000000))",
|
|
||||||
"echo $(($(date +%s%N)/1000000)) >> env-stack",
|
|
||||||
|
|
||||||
]
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
def steps(name, dependsOn):
|
def steps(name, dependsOn):
|
||||||
|
|
Reference in New Issue