Compare commits

..

5 commits

Author SHA1 Message Date
5c404dca87
fix: update octopus_exporter to v1.1.1 (#81)
Some checks failed
Deploy (on merge) / Discover hosts (push) Waiting to run
Deploy (on merge) / Deploy → (push) Blocked by required conditions
Terraform / Plan (push) Has been cancelled
Terraform / Apply (push) Has been cancelled
2026-04-26 21:01:24 +01:00
d76be4828c
fix: add ssh key resource (#80) 2026-04-26 20:08:45 +01:00
19928358c5
fix: Update node version for gha (#79)
* fix: update checkout version to dodge deprecation

* fix: more deprecations

* forgot one
2026-04-26 18:35:15 +01:00
7c3fec983b
fix: Update node version for gha (#78)
* fix: update checkout version to dodge deprecation

* fix: more deprecations
2026-04-26 18:23:22 +01:00
98be03c273
fix: update checkout version to dodge deprecation (#77) 2026-04-26 18:13:38 +01:00
11 changed files with 58 additions and 52 deletions

View file

@ -5,7 +5,7 @@ on:
branches: branches:
- main - main
paths-ignore: paths-ignore:
- 'terraform/**' - "terraform/**"
# Requires these repository secrets: # Requires these repository secrets:
# TAILSCALE_CLIENT_ID — Tailscale OAuth client ID (federated identity) # TAILSCALE_CLIENT_ID — Tailscale OAuth client ID (federated identity)
@ -20,7 +20,7 @@ jobs:
outputs: outputs:
hosts: ${{ steps.discover.outputs.hosts }} hosts: ${{ steps.discover.outputs.hosts }}
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Read hosts from inventory - name: Read hosts from inventory
id: discover id: discover
@ -40,7 +40,7 @@ jobs:
host: ${{ fromJson(needs.discover.outputs.hosts) }} host: ${{ fromJson(needs.discover.outputs.hosts) }}
fail-fast: false fail-fast: false
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Set up Tailscale - name: Set up Tailscale
uses: tailscale/github-action@v4 uses: tailscale/github-action@v4

View file

@ -4,15 +4,15 @@ on:
workflow_dispatch: workflow_dispatch:
inputs: inputs:
target: target:
description: 'Target host (e.g. helsinki-a, london-b, all)' description: "Target host (e.g. helsinki-a, london-b, all)"
required: true required: true
type: string type: string
playbook: playbook:
description: 'Ansible playbook to run (e.g. site.yml, update.yml)' description: "Ansible playbook to run (e.g. site.yml, update.yml)"
required: true required: true
type: string type: string
dry_run: dry_run:
description: 'Dry run (--check mode)' description: "Dry run (--check mode)"
required: false required: false
type: boolean type: boolean
default: true default: true
@ -30,7 +30,7 @@ jobs:
outputs: outputs:
hosts: ${{ steps.prepare.outputs.hosts }} hosts: ${{ steps.prepare.outputs.hosts }}
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Build host matrix - name: Build host matrix
id: prepare id: prepare
@ -48,7 +48,7 @@ jobs:
needs: prepare needs: prepare
name: Deploy ${{ inputs.playbook }} → ${{ matrix.host }} name: Deploy ${{ inputs.playbook }} → ${{ matrix.host }}
runs-on: ubuntu-latest runs-on: ubuntu-latest
environment: production # requires manual approval in repo settings environment: production # requires manual approval in repo settings
permissions: permissions:
id-token: write id-token: write
strategy: strategy:
@ -56,7 +56,7 @@ jobs:
host: ${{ fromJson(needs.prepare.outputs.hosts) }} host: ${{ fromJson(needs.prepare.outputs.hosts) }}
fail-fast: false fail-fast: false
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Set up Tailscale - name: Set up Tailscale
uses: tailscale/github-action@v4 uses: tailscale/github-action@v4

View file

@ -8,7 +8,7 @@ jobs:
name: ansible-lint name: ansible-lint
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Check for Ansible files - name: Check for Ansible files
id: check id: check

View file

@ -8,7 +8,7 @@ jobs:
name: docker compose config name: docker compose config
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Stub missing env files referenced by Compose - name: Stub missing env files referenced by Compose
run: | run: |

View file

@ -4,8 +4,8 @@ on:
push: push:
branches: [main] branches: [main]
paths: paths:
- 'terraform/**' - "terraform/**"
- '.github/workflows/terraform.yml' - ".github/workflows/terraform.yml"
# Requires these repository secrets: # Requires these repository secrets:
# AGE_SECRET_KEY — age private key for SOPS decryption # AGE_SECRET_KEY — age private key for SOPS decryption
@ -15,10 +15,10 @@ jobs:
name: Plan name: Plan
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Install OpenTofu - name: Install OpenTofu
uses: opentofu/setup-opentofu@v1 uses: opentofu/setup-opentofu@v2
with: with:
tofu_version: latest tofu_version: latest
@ -53,7 +53,7 @@ jobs:
- name: Upload plan - name: Upload plan
if: github.event_name == 'push' && github.ref == 'refs/heads/main' if: github.event_name == 'push' && github.ref == 'refs/heads/main'
uses: actions/upload-artifact@v4 uses: actions/upload-artifact@v7
with: with:
name: tfplan name: tfplan
path: terraform/tfplan path: terraform/tfplan
@ -66,10 +66,10 @@ jobs:
runs-on: ubuntu-latest runs-on: ubuntu-latest
environment: production environment: production
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Install OpenTofu - name: Install OpenTofu
uses: opentofu/setup-opentofu@v1 uses: opentofu/setup-opentofu@v2
with: with:
tofu_version: latest tofu_version: latest
@ -99,7 +99,7 @@ jobs:
run: tofu init run: tofu init
- name: Download plan - name: Download plan
uses: actions/download-artifact@v4 uses: actions/download-artifact@v8
with: with:
name: tfplan name: tfplan
path: terraform/ path: terraform/

View file

@ -8,7 +8,7 @@ jobs:
name: caddy validate name: caddy validate
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Check for Caddyfile - name: Check for Caddyfile
id: check id: check

View file

@ -8,10 +8,10 @@ jobs:
name: tofu validate name: tofu validate
runs-on: ubuntu-latest runs-on: ubuntu-latest
steps: steps:
- uses: actions/checkout@v4 - uses: actions/checkout@v6
- name: Install OpenTofu - name: Install OpenTofu
uses: opentofu/setup-opentofu@v1 uses: opentofu/setup-opentofu@v2
with: with:
tofu_version: latest tofu_version: latest

View file

@ -4,7 +4,7 @@
services: services:
octopus-exporter: octopus-exporter:
image: rwejlgaard/octopus_exporter:v1.1.0 image: rwejlgaard/octopus_exporter:v1.1.1
container_name: octopus_exporter container_name: octopus_exporter
restart: unless-stopped restart: unless-stopped
ports: ports:

View file

@ -1,39 +1,40 @@
resource "hcloud_server" "nuremberg-a" { resource "hcloud_server" "nuremberg-a" {
name = "nuremberg-a" name = "nuremberg-a"
image = "debian-13" image = "debian-13"
server_type = "cx23" server_type = "cx23"
location = "nbg1" location = "nbg1"
delete_protection = true delete_protection = true
rebuild_protection = true rebuild_protection = true
keep_disk = true keep_disk = true
labels = { labels = {
"role" = "mail" "role" = "mail"
} }
public_net { public_net {
ipv4_enabled = true ipv4_enabled = true
ipv6_enabled = true ipv6_enabled = true
} }
} }
resource "hcloud_server" "helsinki-a" { resource "hcloud_server" "helsinki-a" {
name = "helsinki-a" name = "helsinki-a"
image = "debian-13" image = "debian-13"
server_type = "cax11" server_type = "cax11"
location = "hel1" location = "hel1"
delete_protection = true delete_protection = true
rebuild_protection = true rebuild_protection = true
keep_disk = true keep_disk = true
labels = { labels = {
"role" = "ingress" "role" = "ingress"
} }
public_net {
ipv4_enabled = true
ipv6_enabled = true
}
}
public_net {
ipv4_enabled = true
ipv6_enabled = true
}
}

View file

@ -0,0 +1,4 @@
resource "hcloud_ssh_key" "personal" {
name = "personal"
public_key = "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDlU2h+JgVMVsHkkcxed9WbrUCKWfuUrY6yErmGIIREP6X2cua2qE4H+329FSJXQs0Yd0OiNwsXzfW88kl0+aMopQXaccY3q8109KR43RNrRrril9od+PidVvT/fvV8eNYVE9M4gyT1c9t8ZLD85vJf9rILFWbLG4DqqFL3z33W2u//Bl8uVLoY3tSgBmukVt45If9g9mxVfSstLmZj7j75rghS0EbE2kzwgUH397mJGMlJJdFhzRtP+/D09hE+zgFxl45V6dszEu9ggawRRGvEcR1dXDB0g6n3/7h6M+pb8/77ZAxk4AwD6CzZi8k7SlVkzCKZQRPpge+C0xLdm9EAY7byj30XdGgpo80eiCJmVImYm4VmPnjh39IumQWkDgpXkYQ9aj9jUDvcSrEmwTBRJOqmaO7BW0sVbP0BDW3UjCyeUQ8zprmWsUscoB0u9r4bMOLnhNldXljjKcDRdX2JciIILiCEfnn781Q3uxLgOoHEnYto0tSxbLQI/o9WB4M="
}

View file

@ -4,6 +4,7 @@ terraform {
required_providers { required_providers {
cloudflare = { cloudflare = {
source = "cloudflare/cloudflare" source = "cloudflare/cloudflare"
version = "~> 5.19"
} }
hcloud = { hcloud = {