update lang for runniner yaml
This commit is contained in:
parent
5d76371dfc
commit
0603f8fd9f
1 changed files with 14 additions and 19 deletions
|
|
@ -1,35 +1,30 @@
|
||||||
name: PVE2 Infrastructure Deploy
|
name: PVE2 Infrastructure Deploy
|
||||||
on:
|
on: [push]
|
||||||
push:
|
|
||||||
branches:
|
|
||||||
- main # Only deploy when we push to main
|
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
terraform:
|
terraform:
|
||||||
runs-on: pve2 # This targets the runner we just installed
|
runs-on: pve2
|
||||||
steps:
|
steps:
|
||||||
- name: Checkout Code
|
- name: Native Git Checkout
|
||||||
uses: actions/checkout@v4
|
run: |
|
||||||
|
# Clean the workspace so we don't have old files hanging around
|
||||||
|
rm -rf ./*
|
||||||
|
# Clone using the temporary token Gitea provides for this job
|
||||||
|
git clone http://${{ gitea.token }}@172.16.201.201:3002/${{ gitea.repository }} .
|
||||||
|
|
||||||
- name: Terraform Init
|
- name: Terraform Init
|
||||||
run: |
|
run: |
|
||||||
cd terraform
|
cd terraform
|
||||||
terraform init
|
terraform init
|
||||||
|
|
||||||
- name: Terraform Plan
|
- name: Terraform Plan & Apply
|
||||||
run: |
|
|
||||||
cd terraform
|
|
||||||
terraform plan
|
|
||||||
env:
|
|
||||||
PM_API_TOKEN_ID: ${{ secrets.PM_API_TOKEN_ID }}
|
|
||||||
PM_API_TOKEN_SECRET: ${{ secrets.PM_API_TOKEN_SECRET }}
|
|
||||||
PM_API_URL: "https://localhost:8006/api2/json"
|
|
||||||
|
|
||||||
- name: Terraform Apply
|
|
||||||
run: |
|
run: |
|
||||||
cd terraform
|
cd terraform
|
||||||
terraform apply -auto-approve
|
terraform apply -auto-approve
|
||||||
env:
|
env:
|
||||||
PM_API_TOKEN_ID: ${{ secrets.PM_API_TOKEN_ID }}
|
PM_API_TOKEN_ID: ${{ secrets.PM_API_TOKEN_ID }}
|
||||||
PM_API_TOKEN_SECRET: ${{ secrets.PM_API_TOKEN_SECRET }}
|
PM_API_TOKEN_SECRET: ${{ secrets.PM_API_TOKEN_SECRET }}
|
||||||
|
# Since the runner is ON the host, we can use localhost
|
||||||
PM_API_URL: "https://localhost:8006/api2/json"
|
PM_API_URL: "https://localhost:8006/api2/json"
|
||||||
|
# This prevents Terraform from failing if your PVE SSL cert is self-signed
|
||||||
|
PM_TLS_INSECURE: "true"
|
||||||
Loading…
Reference in a new issue