This repository has been archived on 2026-01-10. You can view files and clone it, but cannot push or open issues or pull requests.
coder-templates/.drone.yml
Steve McMaster 86e7374bc8
All checks were successful
continuous-integration/drone/push Build is passing
use wget
2022-11-05 12:24:51 -04:00

22 lines
691 B
YAML

kind: pipeline
name: default
type: docker
steps:
- name: push templates
image: alpine:3.16
environment:
CODER_URL: http://coder.coder.svc.cluster.local
CODER_SESSION_TOKEN:
from_secret: CODER_SESSION_TOKEN
CODER_TEMPLATE_VERSION: $${DRONE_COMMIT_SHA}
commands:
- apk add git
- wget -O- https://github.com/coder/coder/releases/download/v0.11.0/coder_0.11.0_linux_amd64.tar.gz | tar -xzf - -C /usr/local/bin
- |
for template in * ; do
[ -e "$template/main.tf" ] || continue
coder templates push -d $template --yes $template || \
coder templates create -d $template --yes $template
done