Create initial module #1
Workflow file for this run
This file contains hidden or 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
| # This workflow releases a new version of the Terraform module. | |
| name: Release | |
| # Only trigger when a pull request into main branch is merged. | |
| on: | |
| pull_request: | |
| types: [closed] | |
| branches: | |
| - main | |
| jobs: | |
| release: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout Repository | |
| uses: actions/checkout@v4 | |
| - name: Get module version | |
| id: get-version | |
| run: echo "version=$(cat VERSION.txt)" >> $GITHUB_OUTPUT | |
| - name: Create Release | |
| uses: actions/create-release@v1 | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # This token is provided by Actions, no need to create your own. | |
| with: | |
| tag_name: ${{ steps.get-version.outputs.version }} | |
| release_name: ${{ github.event.pull_request.title }} | |
| body: ${{ github.event.pull_request.body }} | |
| draft: false | |
| prerelease: false |