Release 1.4.0 #175
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: Tests | |
on: | |
push: | |
branches: [main] | |
paths-ignore: | |
- 'README.md' | |
pull_request: | |
types: ['opened', 'synchronize'] | |
paths: | |
- '**.go' | |
- 'vendor/**' | |
- '.github/workflows/**' | |
workflow_dispatch: | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
jobs: | |
build: | |
name: Build | |
runs-on: ubuntu-latest | |
timeout-minutes: 5 | |
steps: | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v4 | |
- name: Set up Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version-file: .go-version | |
cache: true | |
- name: Get dependencies | |
run: go mod download | |
- name: Build | |
run: go build -v . | |
generate: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: .go-version | |
cache: true | |
- run: go generate ./... | |
- name: git diff | |
run: | | |
git diff --compact-summary --exit-code || \ | |
(echo; echo "Unexpected difference in directories after code generation. Run 'go generate ./...' command and commit."; exit 1) | |
test: | |
name: Terraform Provider Acceptance Tests | |
needs: build | |
runs-on: ubuntu-latest | |
timeout-minutes: 15 | |
strategy: | |
fail-fast: false | |
matrix: | |
terraform: | |
- '1.0.*' | |
- '1.1.*' | |
- '1.2.*' | |
- '1.4.*' | |
include: | |
- terraform: '1.0.*' | |
domain: 'dnsimple-1-0-terraform.bio' | |
registrant_contact_id: 10854 | |
registrant_change_domain: 'peoa1hvrl5s7q7os1bqadhd29uar81nnc4m0oyaloxex9kapsn20u6nr8z6l5h.eu' | |
- terraform: '1.1.*' | |
domain: 'dnsimple-1-1-terraform.bio' | |
registrant_contact_id: 10169 | |
registrant_change_domain: '9qy9lpesl2f2o5ya45zyujrggori1mh8sl6k2oz37usv48lhn3ziistg3u5kgv.eu' | |
- terraform: '1.2.*' | |
domain: 'dnsimple-1-2-terraform.bio' | |
registrant_contact_id: 10854 | |
registrant_change_domain: 'lqyivkga231hkiqihu0k7bjic2ixd01xs5vex8rmn2iaw0l7gxvhcbicigpfm3.eu' | |
- terraform: '1.4.*' | |
domain: 'dnsimple-1-4-terraform.bio' | |
registrant_contact_id: 10169 | |
registrant_change_domain: 'z0u2w48bo5fzgdsh1g7zjpflbpt0tiyl6tmc75ltzzm6dbphghrgepbaxs6zrm.eu' | |
steps: | |
- uses: actions/checkout@v4 | |
- uses: actions/setup-go@v5 | |
with: | |
go-version-file: .go-version | |
cache: true | |
- uses: hashicorp/setup-terraform@v3 | |
with: | |
terraform_version: ${{ matrix.terraform }} | |
terraform_wrapper: false | |
- run: go mod download | |
- env: | |
TF_ACC: "1" | |
DNSIMPLE_SANDBOX: true | |
DNSIMPLE_ACCOUNT: ${{ secrets.DNSIMPLE_ACCOUNT }} | |
DNSIMPLE_TOKEN: ${{ secrets.DNSIMPLE_TOKEN }} | |
DNSIMPLE_DOMAIN: ${{ matrix.domain }} | |
DNSIMPLE_CONTACT_ID: ${{ secrets.DNSIMPLE_CONTACT_ID }} | |
DNSIMPLE_REGISTRANT_CHANGE_DOMAIN: ${{ matrix.registrant_change_domain }} | |
DNSIMPLE_REGISTRANT_CHANGE_CONTACT_ID: ${{ matrix.registrant_contact_id }} | |
run: go test -v -cover ./internal/... -timeout 15m | |
timeout-minutes: 10 | |
- run: make sweep | |
if: always() | |
env: | |
DNSIMPLE_SANDBOX: true | |
DNSIMPLE_ACCOUNT: ${{ secrets.DNSIMPLE_ACCOUNT }} | |
DNSIMPLE_TOKEN: ${{ secrets.DNSIMPLE_TOKEN }} | |
DNSIMPLE_DOMAIN: ${{ matrix.domain }} | |
DNSIMPLE_REGISTRANT_CHANGE_DOMAIN: ${{ matrix.registrant_change_domain }} | |
slack-workflow-status: | |
if: always() | |
name: Post Workflow Status To Slack | |
needs: | |
- test | |
runs-on: ubuntu-latest | |
steps: | |
- name: Slack Workflow Notification | |
uses: Gamesight/slack-workflow-status@master | |
with: | |
repo_token: ${{secrets.GITHUB_TOKEN}} | |
slack_webhook_url: ${{secrets.SLACK_WEBHOOK_URL_DEVELOPMENT}} |