Compare commits

..

No commits in common. "44ad0306a955e37279dbcd6db0b2490f6a72b6db" and "140067aa150bd64e4febf36416962645ad7bd460" have entirely different histories.

6 changed files with 31 additions and 37 deletions

View File

@ -1,36 +1,30 @@
type: docker
kind: pipeline kind: pipeline
name: Serverctl name: Serverctl
steps: steps:
- name: test - name: terraform plan
image: harbor.front.kjuulh.io/docker-proxy/library/bash:latest image: alpine
environment:
HCLOUD_TOKEN:
from_secret: serverctl_hcloud_token
ACCESS_KEY:
from_secret: serverctl_access_key
SECRET_KEY:
from_secret: serverctl_secret_key
SSH_ZIP_KEY:
from_secret: serverctl_ssh_zip_key
HCLOUD_SSH_KEY_ID:
from_secret: serverctl_hcloud_ssh_key_id
commands: commands:
- echo 'Run tests' - apk --update add curl zip ansible python3
# - cd infrastructure && ./unzip-ssh-keys.sh "$SSH_ZIP_KEY" && cd ..
# - name: terraform plan - curl --silent --output terraform.zip "https://releases.hashicorp.com/terraform/1.1.6/terraform_1.1.6_linux_amd64.zip"
# image: alpine - unzip terraform.zip ; rm -f terraform.zip; chmod +x terraform
# environment: - mkdir -p ${HOME}/bin ; export PATH=${PATH}:${HOME}/bin; mv terraform ${HOME}/bin/
# HCLOUD_TOKEN: - terraform -v
# from_secret: serverctl_hcloud_token - cd infrastructure/create-resources
# ACCESS_KEY: - terraform init -backend-config="access_key=$ACCESS_KEY" -backend-config="secret_key=$SECRET_KEY"
# from_secret: serverctl_access_key - terraform validate
# SECRET_KEY: - terraform apply -auto-approve -var "hcloud_token=$HCLOUD_TOKEN" -var "pvt_key=../ssh_keys/id_ed25519" -var "pub_key=../ssh_keys/id_ed25519.pub" -var "hcloud_serverctl_ssh_key_id=$HCLOUD_SSH_KEY_ID"
# from_secret: serverctl_secret_key - cd ansible
# SSH_ZIP_KEY: - ANSIBLE_HOST_KEY_CHECKING=False /usr/bin/ansible-playbook -u root --key-file '../../ssh_keys/id_ed25519' -e 'pub_key=../../ssh_keys/id_ed25519.pub' site.yml
# from_secret: serverctl_ssh_zip_key
# HCLOUD_SSH_KEY_ID:
# from_secret: serverctl_hcloud_ssh_key_id
# commands:
# - apk --update add curl zip ansible python3
# - cd infrastructure && ./unzip-ssh-keys.sh "$SSH_ZIP_KEY" && cd ..
# - curl --silent --output terraform.zip "https://releases.hashicorp.com/terraform/1.1.6/terraform_1.1.6_linux_amd64.zip"
# - unzip terraform.zip ; rm -f terraform.zip; chmod +x terraform
# - mkdir -p ${HOME}/bin ; export PATH=${PATH}:${HOME}/bin; mv terraform ${HOME}/bin/
# - terraform -v
# - cd infrastructure/create-resources
# - terraform init -backend-config="access_key=$ACCESS_KEY" -backend-config="secret_key=$SECRET_KEY"
# - terraform validate
# - terraform apply -auto-approve -var "hcloud_token=$HCLOUD_TOKEN" -var "pvt_key=../ssh_keys/id_ed25519" -var "pub_key=../ssh_keys/id_ed25519.pub" -var "hcloud_serverctl_ssh_key_id=$HCLOUD_SSH_KEY_ID"
# - cd ansible
# - ANSIBLE_HOST_KEY_CHECKING=False /usr/bin/ansible-playbook -u root --key-file '../../ssh_keys/id_ed25519' -e 'pub_key=../../ssh_keys/id_ed25519.pub' site.yml

View File

@ -55,7 +55,7 @@ services:
# Logging # Logging
loki: loki:
image: grafana/loki:2.6.1 image: grafana/loki:2.4.2
ports: ports:
- 3100 - 3100
networks: networks:
@ -66,7 +66,7 @@ services:
logging: *loki-logging logging: *loki-logging
promtail: promtail:
image: grafana/promtail:2.6.1 image: grafana/promtail:2.4.2
volumes: volumes:
- ./services/logs/promtail/config.yaml:/mnt/config/promtail-config.yaml - ./services/logs/promtail/config.yaml:/mnt/config/promtail-config.yaml
- /var/lib/docker/containers:/host/containers - /var/lib/docker/containers:/host/containers

View File

@ -2,7 +2,7 @@ terraform {
required_providers { required_providers {
hcloud = { hcloud = {
source = "hetznercloud/hcloud" source = "hetznercloud/hcloud"
version = "1.35.2" version = "1.32.2"
} }
} }

View File

@ -1,4 +1,4 @@
FROM golang:1.19-bullseye FROM golang:1.17-bullseye
RUN go install github.com/jackc/tern@latest RUN go install github.com/jackc/tern@latest

View File

@ -1,4 +1,4 @@
FROM golang:1.19-bullseye FROM golang:1.17-bullseye
RUN go install github.com/cosmtrek/air@latest RUN go install github.com/cosmtrek/air@latest
# Development don't need this # Development don't need this

View File

@ -1,6 +1,6 @@
module serverctl module serverctl
go 1.19 go 1.17
require ( require (
github.com/Microsoft/go-winio v0.4.17 // indirect github.com/Microsoft/go-winio v0.4.17 // indirect