Skip to content

Commit

Permalink
docs: arg_lock and setup (OP5dev#262)
Browse files Browse the repository at this point in the history
* replace `tf_version` with dedicated setup action

Signed-off-by: Rishav Dhar <19497993+RDhar@users.noreply.github.com>

* add `arg_lock`

Signed-off-by: Rishav Dhar <19497993+RDhar@users.noreply.github.com>

---------

Signed-off-by: Rishav Dhar <19497993+RDhar@users.noreply.github.com>
  • Loading branch information
rdhar authored Jul 30, 2024
1 parent fef6afe commit 3fec94a
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/examples/pr_merge_matrix.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,6 @@ jobs:
with:
arg_chdir: directory/path
arg_command: ${{ github.event_name == 'merge_group' && 'apply' || 'plan' }}
arg_lock: ${{ github.event_name == 'merge_group' && 'true' || 'false' }}
arg_var_file: env/${{ matrix.deployment }}.tfvars
arg_workspace: ${{ matrix.deployment }}
arg_lock: ${{ github.event_name == 'merge_group' && 'true' || 'false' }}
1 change: 1 addition & 0 deletions .github/examples/pr_push_auth.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -35,3 +35,4 @@ jobs:
with:
arg_chdir: directory/path
arg_command: ${{ github.event_name == 'push' && 'apply' || 'plan' }}
arg_lock: ${{ github.event_name == 'push' && 'true' || 'false' }}
1 change: 1 addition & 0 deletions .github/workflows/tf_tests.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ jobs:
with:
arg_chdir: tests/${{ matrix.path }}
arg_command: ${{ github.event.pull_request.merged && 'apply' || 'plan' }}
arg_lock: ${{ github.event.pull_request.merged && 'true' || 'false' }}
tf_tool: ${{ matrix.tool }}
tf_version: ~> 1.8.0

Expand Down
7 changes: 4 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -75,13 +75,14 @@ jobs:

steps:
- uses: actions/checkout@v4
- uses: opentofu/setup-opentofu@v1
- uses: devsectop/tf-via-pr@v11
with:
arg_command: ${{ github.event_name == 'push' && 'apply' || 'plan' }}
arg_chdir: sample/directory/path
arg_workspace: development
arg_command: ${{ github.event_name == 'push' && 'apply' || 'plan' }}
arg_lock: ${{ github.event_name == 'push' && 'true' || 'false' }}
arg_var_file: env/dev.tfvars
tf_version: ~> 1.8.0
arg_workspace: development
```
> [!TIP]
Expand Down

0 comments on commit 3fec94a

Please sign in to comment.