.
continuous-integration/drone/push Build is passing
Details
continuous-integration/drone/push Build is passing
Details
This commit is contained in:
parent
500b33e16f
commit
9d066af7bb
|
@ -1,82 +0,0 @@
|
||||||
load("@this//:from-secret.star", "fromSecret")
|
|
||||||
load("@this//:print-secrets.star", "printSecrets")
|
|
||||||
|
|
||||||
load("@this//:map.star", "map")
|
|
||||||
load("@this//:environment.star", "environment")
|
|
||||||
load("@this//:echo.star", "echo")
|
|
||||||
load("@this//:export.star", "export")
|
|
||||||
load("@this//:echo-secret.star", "echoSecret")
|
|
||||||
load("@this//:wait.star", "wait")
|
|
||||||
load("@this//:build.star", "build")
|
|
||||||
load("@this//:scp.star", "scp")
|
|
||||||
load("@this//stack:public-secrets.star", "publicSecrets")
|
|
||||||
load("@this//stack:secret-secrets.star", "secretSecrets")
|
|
||||||
load("@this//:pull.star", "pull")
|
|
||||||
load("@this//:deploy.star", "deploy")
|
|
||||||
load("@this//:build-folder.star", "buildFolder")
|
|
||||||
load("@this//:build-docker-folder.star", "buildDockerFolder")
|
|
||||||
load("@this//:pipeline.star", "pipeline")
|
|
||||||
load("@this//:clear.star", "clear")
|
|
||||||
|
|
||||||
def main(ctx):
|
|
||||||
if ctx.build.branch == 'do':
|
|
||||||
return [
|
|
||||||
pipeline(
|
|
||||||
'do',
|
|
||||||
[
|
|
||||||
printSecrets(
|
|
||||||
"env-stack",
|
|
||||||
publicSecrets,
|
|
||||||
secretSecrets,
|
|
||||||
),
|
|
||||||
clear("/home/giles/stack-deploy"),
|
|
||||||
wait(15, "wait"),
|
|
||||||
build("guacamole-postgresql"),
|
|
||||||
build("letsencrypt-nginx"),
|
|
||||||
build("drone-starlark"),
|
|
||||||
|
|
||||||
buildDockerFolder(
|
|
||||||
"Dockerfile.do",
|
|
||||||
"$${LOCAL_DOCKER_REGISTRY}letsencrypt-nginx",
|
|
||||||
"$${LOCAL_DOCKER_REGISTRY}letsencrypt-do",
|
|
||||||
"letsencrypt-nginx",
|
|
||||||
"do",
|
|
||||||
),
|
|
||||||
scp("/root/stack-deploy"),
|
|
||||||
pull([
|
|
||||||
"letsencrypt-do",
|
|
||||||
"drone-starlark",
|
|
||||||
"guacamole-postgresql",
|
|
||||||
]),
|
|
||||||
deploy(
|
|
||||||
"docker-compose-do.yml",
|
|
||||||
"gitea",
|
|
||||||
"/root/stack-deploy",
|
|
||||||
publicSecrets + secretSecrets,
|
|
||||||
),
|
|
||||||
],
|
|
||||||
[],
|
|
||||||
[
|
|
||||||
{
|
|
||||||
"name": "ca",
|
|
||||||
"host": {
|
|
||||||
"path": "/root/stack-deploy/.ca",
|
|
||||||
},
|
|
||||||
}
|
|
||||||
],
|
|
||||||
[
|
|
||||||
{
|
|
||||||
"name": "ca",
|
|
||||||
"path": "/etc/docker/certs.d",
|
|
||||||
},
|
|
||||||
]
|
|
||||||
),
|
|
||||||
]
|
|
||||||
else:
|
|
||||||
return pipeline(
|
|
||||||
ctx.build.branch,
|
|
||||||
[],
|
|
||||||
[],
|
|
||||||
[],
|
|
||||||
[],
|
|
||||||
)
|
|
|
@ -1,14 +1,19 @@
|
||||||
|
|
||||||
load("@this//stack:drone.star", "drone")
|
load("@this//stack:drone.star", "drone")
|
||||||
|
load("@this//stack:stack-name.star", "stackName")
|
||||||
|
load("@this//stack:stack-root.star", "stackRoot")
|
||||||
|
|
||||||
|
|
||||||
def main(ctx):
|
def main(ctx):
|
||||||
return drone(
|
return drone(
|
||||||
ctx,
|
ctx,
|
||||||
"do",
|
"do",
|
||||||
"/root/stack-deploy",
|
stackRoot,
|
||||||
"gitea",
|
stackName,
|
||||||
[
|
[
|
||||||
"docker service scale gitea_chat=1",
|
"docker service scale {name}_chat=1".format(name=stackName),
|
||||||
|
"docker service scale {name}_letsencrypt-drone=1".format(name=stackName),
|
||||||
|
"docker service scale {name}_letsencrypt-git=1".format(name=stackName),,
|
||||||
]
|
]
|
||||||
)
|
)
|
||||||
|
|
Reference in New Issue