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

[BUG] file_roots to relative path seems broken #66588

Open
dtzampanakis opened this issue May 23, 2024 · 7 comments
Open

[BUG] file_roots to relative path seems broken #66588

dtzampanakis opened this issue May 23, 2024 · 7 comments
Assignees
Labels
Bug broken, incorrect, or confusing behavior

Comments

@dtzampanakis
Copy link

Description
Upgrading from salt-ssh version 3007.0 (Chlorine)
to 3007.1 (Chlorine), seems to broke the file_roots that i use in my master file.

root_dir: "."
conf_file: ./master
cachedir: /tmp/salt
gpg_keydir: /etc/salt/gpgkeys
file_roots:
  base:
    - ./states
pillar_roots:
  base:
    - ./pillar

Pillars are working, but when i try to state.apply i am unable to apply any state with

serverx:
    - No matching sls found for 'ntp' in env 'base'

Working only if i change the file_roots with an absolute path.

I installed 3006.8(Sulfur) to make it work again with relative path since i am unable to go back to 3007.0.

@dtzampanakis dtzampanakis added Bug broken, incorrect, or confusing behavior needs-triage labels May 23, 2024
@petrows
Copy link

petrows commented May 24, 2024

I have the same issue, all my scripts are broken now after update. I also have downgraded to previous version.

@bendikro
Copy link

b0e7c62 by @hurzhurz is what caused this regression. @s0undt3ch

@dwoz dwoz removed the needs-triage label Jun 3, 2024
@dwoz dwoz self-assigned this Jun 3, 2024
@hartwork
Copy link

hartwork commented Jun 19, 2024

This is crazy, it makes 3007.1 unusable. Could this be fixed please?

@hurzhurz
Copy link
Contributor

@dtzampanakis Can you tell a bit more about how you run the master with this example config?

I wanted to try it, but I can't get it working, even with 3006.8.

I made a file structure like this in a test VM:

/root/master-test/
/root/master-test/master (your mentioned config)
/root/master-test/states/
/root/master-test/states/abc (dummy file)
/root/master-test/pillar/

And I started the master like this:
cd /root/master-test/ && salt-master -c .

The master actually uses the file structure in /root/master-test/ for minion keys, cache, etc.
But a cp.list_master against a connected minion doesn't list anything.

It looks like the master worker threads have / as CWD. So with "./states" they actually look in "/states".
And if I create "/states/" and a file "/states/abc", cp.list_master actually shows the file "abc".

Am I missing a step? Or do you use anything special to run the master, like docker or so?

@hartwork
Copy link

@hurzhurz this is about salt-ssh. Have you tried salt-ssh?

@hurzhurz
Copy link
Contributor

@hartwork Thanks for the hint! I somehow overlooked and also didn't expect that...

@dwoz
Copy link
Contributor

dwoz commented Jun 22, 2024

@hurzhurz Assigned this to you assuming you are up for the task. :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug broken, incorrect, or confusing behavior
Projects
None yet
Development

No branches or pull requests

6 participants