Collin J. Doering
913c2f0e67
* .drone.yml: Update file after updates to .drone.jsonnet * .drone.jsonnet: Relocate guix_pipeline, guix_step, and deployStep to .drone/ci.libsonnet library. Adjust existing function names to match new names in library. Explicitly pass PLAN environment variable to ci.awsDeployStep for plan and apply stages
22 lines
716 B
Plaintext
22 lines
716 B
Plaintext
local ci = import '.drone/ci.libsonnet';
|
|
|
|
[
|
|
ci.guix.pipeline("validate").withTrigger(ci.trigger.new().withEvent(["push", "pull_request", "tag"])).withSteps([
|
|
ci.guix.stepTimeMachine("build", "build -f guix.scm"),
|
|
ci.promoteStep("staging"),
|
|
ci.promoteStep("production"),
|
|
]),
|
|
|
|
ci.guix.pipeline("deploy").withTrigger(ci.trigger.new().withEvent("promote")).withSteps([
|
|
ci.awsDeployStep("init", "setup"),
|
|
ci.awsDeployStep("plan").withEnv({
|
|
PLAN: "out.plan"
|
|
}).withRuntimeEnvVar({
|
|
TF_VAR_site_static_files_dir: "$(guix time-machine -C channels.scm -- build -f guix.scm | grep -e '^.*-site$')"
|
|
}),
|
|
ci.awsDeployStep("deploy").withEnv({
|
|
PLAN: "out.plan"
|
|
}),
|
|
])
|
|
]
|