Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
24 changes: 1 addition & 23 deletions .github/workflows/opentofu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,7 @@ on:
runs-on:
description: Runner label
type: string
default: ubuntu-latest
container:
description: Container image to use
type: string
default: ghcr.io/makeitworkcloud/tfroot-runner:latest
default: arc-tf
setup-ssh:
description: Whether to setup SSH keys
type: boolean
Expand All @@ -35,8 +31,6 @@ jobs:
test:
name: Pre-commit Tests
runs-on: ${{ inputs.runs-on }}
container:
image: ${{ inputs.container }}
env:
SOPS_AGE_KEY: ${{ secrets.SOPS_AGE_KEY }}
steps:
Expand All @@ -52,10 +46,6 @@ jobs:
key: ${{ secrets.SSH_PRIVATE_KEY }}
known_hosts: ${{ secrets.SSH_KNOWN_HOSTS }}

- name: Copy SSH area
if: ${{ inputs.setup-ssh }}
run: cp -r /root/.ssh /github/home/

- name: Fetch canonical pre-commit config
run: |
curl -sSL -o .pre-commit-config.yaml \
Expand All @@ -70,8 +60,6 @@ jobs:
plan:
name: OpenTofu Plan
runs-on: ${{ inputs.runs-on }}
container:
image: ${{ inputs.container }}
if: github.event_name == 'pull_request'
needs: [test]
env:
Expand All @@ -87,10 +75,6 @@ jobs:
key: ${{ secrets.SSH_PRIVATE_KEY }}
known_hosts: ${{ secrets.SSH_KNOWN_HOSTS }}

- name: Copy SSH area
if: ${{ inputs.setup-ssh }}
run: cp -r /root/.ssh /github/home/

- name: OpenTofu Plan
id: plan
run: |
Expand Down Expand Up @@ -125,8 +109,6 @@ jobs:
apply:
name: OpenTofu Apply
runs-on: ${{ inputs.runs-on }}
container:
image: ${{ inputs.container }}
if: github.event_name == 'push' && github.ref == 'refs/heads/main'
needs: [test]
environment: ${{ inputs.environment }}
Expand All @@ -143,9 +125,5 @@ jobs:
key: ${{ secrets.SSH_PRIVATE_KEY }}
known_hosts: ${{ secrets.SSH_KNOWN_HOSTS }}

- name: Copy SSH area
if: ${{ inputs.setup-ssh }}
run: cp -r /root/.ssh /github/home/

- name: OpenTofu Apply
run: make apply
Loading