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

PRELIM mont type block failing #35

Closed
zac90 opened this issue Jun 29, 2023 · 1 comment
Closed

PRELIM mont type block failing #35

zac90 opened this issue Jun 29, 2023 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@zac90
Copy link

zac90 commented Jun 29, 2023

Describe the Issue
The prelim.yml file has a block that checks the tmp mount type. It registers a variable that is then overwritten if the fstab option is run which causes the next task in the block to fail as it is looking for a value that is no longer in the original variable.

register: tmp_mnt_type

This variable is then used in both when: to look for "generated" . However, the task changes this variable if it is found. tmp_mnt_type: fstab

Expected Behavior
The original variable shouldn't be touched and a new variable should be set indicating the mnt type.

Actual Behavior
The tmp_mnt_type variable changes and loses its original value which causes the third task in the block to fail if the second task succeeded.

Possible Solution
Either change the variable name that is used to assign the stdout of the systemctl is-enabled tmp.mount command.
Or, add an extra item to the when: to only do the third task if the second task was skipped.

@zac90 zac90 added the bug Something isn't working label Jun 29, 2023
@uk-bolly uk-bolly self-assigned this Jul 6, 2023
uk-bolly added a commit that referenced this issue Jul 6, 2023
fixed variable reuse error

Signed-off-by: Mark Bolwell <mark.bollyuk@gmail.com>
@uk-bolly
Copy link
Member

uk-bolly commented Jul 6, 2023

Hi @zac90

Thank you once again for your continued feedback with these issues, its truly helping us to improve things. I have pulled this issue into the July23_issues branch. Which i will leave for a couple of days before requesting merge to devel.

Many thanks once again

uk-bolly

Jason-Hendry added a commit to Jason-Hendry/UBUNTU22-CIS that referenced this issue Jul 19, 2023
Signed-off-by: Jason Hendry <jason@rain.com.au>
Jason-Hendry added a commit to Jason-Hendry/UBUNTU22-CIS that referenced this issue Jul 19, 2023
Signed-off-by: Jason Hendry <jason@rain.com.au>
This was referenced Aug 8, 2023
@uk-bolly uk-bolly closed this as completed Sep 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants