37
.gitea/workflows/deploy.yml
Normal file
37
.gitea/workflows/deploy.yml
Normal file
@@ -0,0 +1,37 @@
|
||||
name: Deploy
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- main
|
||||
paths:
|
||||
- tf/**
|
||||
|
||||
jobs:
|
||||
deploy:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
- name: Check out repository
|
||||
uses: actions/checkout@v4.2.2
|
||||
|
||||
- name: Setup OpenTofu
|
||||
uses: opentofu/setup-opentofu@v1
|
||||
|
||||
- name: OpenTofu init
|
||||
id: init
|
||||
run: tofu init
|
||||
|
||||
- name: OpenTofu validate
|
||||
id: validate
|
||||
run: tofu validate -no-color
|
||||
|
||||
- name: OpenTofu refresh
|
||||
id: validate
|
||||
run: tofu refresh
|
||||
|
||||
- name: OpenTofu plan
|
||||
id: plan
|
||||
run: tofu plan -no-color -out /tmp/plan.tfplan
|
||||
|
||||
- name: OpenTofu apply
|
||||
id: apply
|
||||
run: tofu apply /tmp/plan.tfplan
|
Reference in New Issue
Block a user