coder-template/.drone.yml
Peter 96755de9fa
Some checks failed
Hetzner Cloud template / hetzner-cloud-template (pull_request) Failing after 28s
chore(deps): update ghcr.io/coder/coder docker tag to v2.18.0
2024-12-04 04:11:35 +00:00

41 lines
No EOL
971 B
YAML

---
kind: pipeline
type: docker
name: default
trigger:
event:
- push
- pull_request
- tag
steps:
- name: Lint
image: docker.io/hashicorp/terraform
network_mode: host
commands:
- cd hetzner-cloud/
- terraform init
- terraform validate
- name: Push
image: ghcr.io/coder/coder:v2.18.0
network_mode: host
commands:
- |
coder templates push \
--name "$DRONE_COMMIT" \
--directory "hetzner-cloud" \
--variable hcloud_token="$HCLOUD_TOKEN" \
--variable use_subdomain=true \
--variable private_network_id="$HCLOUD_PRIVATE_NETWORK_ID" \
--yes \
"Hetzner-Cloud"
environment:
CODER_URL: https://ide.icb4dc0.de
CODER_SESSION_TOKEN:
from_secret: coder_token
HCLOUD_TOKEN:
from_secret: hcloud_token
HCLOUD_PRIVATE_NETWORK_ID:
from_secret: hcloud_private_network_id