Skip to content

chroot: add apply_, sls and highstate for state execution - #55345

Merged
dwoz merged 12 commits into
saltstack:masterfrom
aplanas:fix_chroot
Dec 3, 2019
Merged

chroot: add apply_, sls and highstate for state execution#55345
dwoz merged 12 commits into
saltstack:masterfrom
aplanas:fix_chroot

Conversation

@aplanas

@aplanas aplanas commented Nov 18, 2019

Copy link
Copy Markdown
Contributor

What does this PR do?

Based on the code from the SSH client wrapper, add apply_, sls and highstate for the execution of Salt states inside a chroot environment.

Tests written?

Yes

@aplanas
aplanas requested a review from a team as a code owner November 18, 2019 14:03
@ghost
ghost requested a review from twangboy November 18, 2019 14:03
@aplanas aplanas changed the title Support the execution of Salt states inside chroot chroot: add apply_, sls and highstate for state execution Nov 18, 2019
@aplanas

aplanas commented Nov 18, 2019

Copy link
Copy Markdown
Contributor Author

This commit is on top of #54959. If this gets merged, I will rebase this one.

@aplanas
aplanas force-pushed the fix_chroot branch 2 times, most recently from a42e4fe to a239990 Compare November 18, 2019 14:54
@Akm0d Akm0d added the Feature new functionality including changes to functionality and code refactors, etc. label Nov 20, 2019
@Akm0d Akm0d added this to the Approved milestone Nov 20, 2019
@Akm0d

Akm0d commented Nov 20, 2019

Copy link
Copy Markdown
Contributor

re-run full pycryptodomex

Comment thread tests/unit/modules/test_chroot.py Outdated
Comment thread tests/unit/modules/test_chroot.py Outdated
Comment thread tests/unit/modules/test_chroot.py Outdated
@Akm0d

Akm0d commented Nov 20, 2019

Copy link
Copy Markdown
Contributor

I don't imagine the chroot module works on windows so we can probably just add a @skipIf(salt.utils.platform.is_windows()) to the top of the test class.

@aplanas

aplanas commented Nov 21, 2019

Copy link
Copy Markdown
Contributor Author

I don't imagine the chroot module works on windows so we can probably just add a @skipIf(salt.utils.platform.is_windows()) to the top of the test class.

I will do this. Thanks for the reviews!!!!

Also reformulate one test to avoid random ordering of kwargs parameters.
Some bug in Salt is preventing to use `archive.tar` inside chroot, we we
want to untar the salt_thin.tgz.

This bug is related with how much deep is the stack of __salt__ calls,
and do not clossing some connections to the master.

Tracking the AsyncZeroMQChannel connections to master:4506, we can see
that one is not closed once the actions ends, hanging the salt-call CLI.

This commit will be reverted once the root cause in found, and the bug
fixed.
Based on the code from the SSH client wrapper, add apply_, sls and
highstate for the execution of Salt states inside a chroot environment.
@dwoz
dwoz merged commit 6986d03 into saltstack:master Dec 3, 2019
@aplanas

aplanas commented Dec 3, 2019

Copy link
Copy Markdown
Contributor Author

Thanks!

@aplanas
aplanas deleted the fix_chroot branch December 3, 2019 09:56
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Feature new functionality including changes to functionality and code refactors, etc.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants