Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: add post-job step for cleaning temp dir #384

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

sfreydin
Copy link

@sfreydin sfreydin commented Dec 18, 2023

Add post-job step for cleaning temp dir

Description

By default, setup-terraform action is downloading terraform file to temporary directory. It should be cleaned in the self-hosted runners because it gets cluttered with unused file with time.
Also, I can't set condition into action.yaml to runs.post-if directive due to issue

Changes Made

  • Added support post-job step for cleaning temporary directory for terraform bin file.

How to Use

  1. Set parameter cleanup_workspace.

Example workflow configuration:

steps:
- uses: hashicorp/setup-terraform@v3
  with:
     cleanup_workspace: true

@hashicorp-cla
Copy link

hashicorp-cla commented Dec 18, 2023

CLA assistant check
All committers have signed the CLA.

@sfreydin sfreydin marked this pull request as ready for review December 20, 2023 08:15
@sfreydin sfreydin requested a review from a team as a code owner December 20, 2023 08:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants