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

Plan steps run with -lock=false #3844

Closed
1 task
Eugst opened this issue Oct 11, 2023 · 9 comments
Closed
1 task

Plan steps run with -lock=false #3844

Eugst opened this issue Oct 11, 2023 · 9 comments
Labels
feature New functionality/enhancement

Comments

@Eugst
Copy link

Eugst commented Oct 11, 2023

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request. Searching for pre-existing feature requests helps us consolidate datapoints for identical requirements into a single place, thank you!
  • Please do not leave "+1" or other comments that do not add relevant new information or questions, they generate extra noise for issue followers and do not help prioritize the request.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.

Describe the user story
I would like to have the opportunity to not lock after successful plan with custom run, for example:

workflows:
  wf1:
    plan:
      steps:
        - run: terragrunt run-all plan

Currently extra_args: ["-lock=false"] is only possible for steps init/plan, but not run.

Describe the solution you'd like

workflows:
  wf1:
    plan:
      steps:
        - run: terragrunt run-all plan
          extra_args: ["-lock=false"]

Describe the drawbacks of your solution

Describe alternatives you've considered
Any possible solution to make possible run custom plans without locks.

@Eugst Eugst added the feature New functionality/enhancement label Oct 11, 2023
@jamengual
Copy link
Contributor

But you can just pass that to the terragrunt command on the same run line.

@Eugst
Copy link
Author

Eugst commented Oct 11, 2023

@jamengual thank you for your reply! do you mean like

workflows: wf1: plan: steps: - run: terragrunt run-all plan -lock=false

It will recognize as terragrunt parameter, isn't it? With any other command it will work the same?

@jamengual
Copy link
Contributor

jamengual commented Oct 11, 2023 via email

@Eugst
Copy link
Author

Eugst commented Oct 11, 2023

Thanks @jamengual !
Let's say I have custom command:

run: echo "hello world!";

Where I need to put lock parameter?

@jamengual
Copy link
Contributor

run command is basically running a one-liner on a shell.
so whatever is the correct way to add a parameter to your command, that is how you do it in the run command.

@Eugst
Copy link
Author

Eugst commented Oct 11, 2023

@jamengual could you provide any example, please?

@jamengual
Copy link
Contributor

- run: terraform plan -lock=false should work

@Eugst
Copy link
Author

Eugst commented Oct 11, 2023

just tried tflint -lock=false
and got:

Failed to parse CLI options; `lock=false` is unknown option. Please run `tflint --help

kinda the same with help.

So back to the core of issue - I would to run custom command and if it's run successfully - make ability to not add the lock to the atlantis.

@jamengual
Copy link
Contributor

you are confusing TF locks with atlantis locks, those are 2 different things.
you showed a terragrunt command before and that is a terrafrom level lock.

#2876

@Eugst Eugst closed this as completed Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature New functionality/enhancement
Projects
None yet
Development

No branches or pull requests

2 participants