You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Please be as specific as possible and give set-up details.
on-prem machine
VM (Virtualbox, KVM, etc. please specify)
VM running on a cloud service, please be explicit and add details
container (Kubernetes, Docker, containerd, etc. please specify)
or a combination, please be explicit
jails if it is FreeBSD
classic packaging
onedir packaging
used bootstrap to install
Steps to Reproduce the behavior
# salt salt01 saltutil.runner git_pillar.update
salt01:
Exception occurred in runner git_pillar.update: Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 513, in __init__
self.new = self.init_remote()
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 2016, in init_remote
self.repo = pygit2.Repository(self._cachedir)
File "/opt/saltstack/salt/extras-3.10/pygit2/repository.py", line 1606, in __init__
path_backend = init_file_backend(path, flags)
_pygit2.GitError: Repository not found at /var/cache/salt/master/git_pillar/git_salt_pillar/_
During handling of the above exception, another exception occurred:
Traceback (most recent call last):
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/client/mixins.py", line 388, in low
data["return"] = func(*args, **kwargs)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/loader/lazy.py", line 159, in __call__
ret = self.loader.run(run_func, *args, **kwargs)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/loader/lazy.py", line 1245, in run
return self._last_context.run(self._run_as, _func_or_method, *args, **kwargs)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/loader/lazy.py", line 1260, in _run_as
ret = _func_or_method(*args, **kwargs)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/runners/git_pillar.py", line 70, in update
pillar = salt.utils.gitfs.GitPillar(
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 2557, in __init__
self.init_remotes(
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 2616, in init_remotes
repo_obj = self.git_providers[self.provider](
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 1740, in __init__
super().__init__(
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 521, in __init__
failhard(self.role)
File "/opt/saltstack/salt/lib/python3.10/site-packages/salt/utils/gitfs.py", line 229, in failhard
raise FileserverConfigError(f"Failed to load {role}")
salt.exceptions.FileserverConfigError: Failed to load git_pillar
Screenshots
If applicable, add screenshots to help explain your problem.
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)
salt --versions-reportSalt Version:
Salt: 3006.9Python Version:
Python: 3.10.14 (main, Jun 26 2024, 11:44:37) [GCC 11.2.0]Dependency Versions:
cffi: 1.14.6cherrypy: unknowncryptography: 42.0.5dateutil: 2.8.1docker-py: Not Installedgitdb: Not Installedgitpython: Not InstalledJinja2: 3.1.4libgit2: 1.5.0looseversion: 1.0.2M2Crypto: Not InstalledMako: Not Installedmsgpack: 1.0.2msgpack-pure: Not Installedmysql-python: Not Installedpackaging: 22.0pycparser: 2.21pycrypto: Not Installedpycryptodome: 3.19.1pygit2: 1.11.1python-gnupg: 0.4.8PyYAML: 6.0.1PyZMQ: 23.2.0relenv: 0.17.0smmap: Not Installedtimelib: 0.2.4Tornado: 4.5.3ZMQ: 4.3.4Salt Extensions:
saltext.bitwarden: 0.0.1b15System Versions:
dist: almalinux 8.10 Cerulean Leopardlocale: utf-8machine: x86_64release: 4.18.0-553.30.1.el8_10.x86_64system: Linuxversion: AlmaLinux 8.10 Cerulean Leopard
Additional context
This is used in an orch to update my Salt masters when they receive an event (via webhook) from the hosted git provider that the repo has been updated. Previously worked (although not entirely sure which version broke).
The text was updated successfully, but these errors were encountered:
# cd /var/cache/salt/master/git_pillar/git_salt_pillar/_ && sudo -u salt git status
On branch master
nothing to commit, working tree clean
Although if I run it as root:
# cd /var/cache/salt/master/git_pillar/git_salt_pillar/_ && git status
fatal: detected dubious ownership in repository at '/var/cache/salt/master/git_pillar/git_salt_pillar/_'
To add an exception for this directory, call:
git config --global --add safe.directory /var/cache/salt/master/git_pillar/git_salt_pillar/_
I wonder if it could be a result of the change to running master as salt, while the minion is running as root.
Description
The
git_pillar.update
runner, when called fromsaltutil.runner
, returns a FileServerConfigError exception.Setup
Please be as specific as possible and give set-up details.
Steps to Reproduce the behavior
It works fine if the runner is called directly:
Expected behavior
Screenshots
If applicable, add screenshots to help explain your problem.
Versions Report
salt --versions-report
(Provided by running salt --versions-report. Please also mention any differences in master/minion versions.)Additional context
This is used in an orch to update my Salt masters when they receive an event (via webhook) from the hosted git provider that the repo has been updated. Previously worked (although not entirely sure which version broke).
The text was updated successfully, but these errors were encountered: