feat: nomad development environment #1
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | ||
on: | ||
push: | ||
branches: [main] | ||
pull_request: | ||
env: | ||
consul_version: 1.20.1 # renovate: datasource=github-releases depName=hashicorp/consul | ||
jobs: | ||
example: | ||
runs-on: ubuntu-latest | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
permissions: | ||
id-token: write # Required by hetznercloud/tps-action | ||
defaults: | ||
run: | ||
working-directory: example | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: opentofu/setup-opentofu@v1 | ||
with: | ||
tofu_version: v1.8.7 # renovate: datasource=github-releases depName=opentofu/opentofu | ||
tofu_wrapper: false | ||
- uses: hashicorp/setup-nomad@main | ||
id: setup | ||
with: | ||
version: 1.9.3 # renovate: datasource=github-releases depName=hashicorp/nomad | ||
- name: setup consul binary | ||
run: | | ||
Check failure on line 40 in .github/workflows/test.yml GitHub Actions / TestInvalid workflow file
|
||
curl -o consul.zip https://releases.hashicorp.com/consul/${{ consul_version }}/consul_${{ consul_version }}_linux_amd64.zip | ||
unzip consul.zip | ||
mv consul /usr/local/bin/ | ||
- uses: hetznercloud/tps-action@main | ||
- name: Swap module source | ||
run: sed -i -e 's|source = ".*"|source = "./.."|' example/main.tf | ||
- name: Setup environment | ||
run: make -C example up | ||
- name: Verify environment | ||
run: | | ||
source example/files/env.sh | ||
nomad node status | ||
- name: Cleanup | ||
if: always() | ||
run: make -C example down |