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
Description
The file state module has custom check_cmd logic for running with a temporary file.
This used to work for file.symlink, but has regressed in 3006 (LTS).
Setup
For example, a onedir installation managing a Debian webserver:
Steps to Reproduce the behavior
Apply the above state:
[INFO] Running state [/etc/nginx/sites-enabled/default] at time 11:13:20.485750
[INFO] Executing state file.symlink for [/etc/nginx/sites-enabled/default]
[INFO] Executing command 'n' in directory '/root'
[DEBUG] stdout: /bin/sh: 1: n: not found
[DEBUG] retcode: 127
[DEBUG] Last command return code: 127
[ERROR] check_cmd determined the state failed
[INFO] Completed state [/etc/nginx/sites-enabled/default] at time 11:13:20.492677 (duration_in_ms=6.927)
Expected behavior
As in previous versions, it should create a temporary symlink first and then pass append that to the given command.
Versions Report
salt --versions-report
Salt 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: 18.6.1cryptography: 42.0.5dateutil: 2.8.1docker-py: Not Installedgitdb: Not Installedgitpython: Not InstalledJinja2: 3.1.4libgit2: Not Installedlooseversion: 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: Not Installedpython-gnupg: 0.4.8PyYAML: 6.0.1PyZMQ: 23.2.0relenv: 0.17.0smmap: Not Installedtimelib: 0.2.4Tornado: 4.5.3ZMQ: 4.3.4System Versions:
dist: ubuntu 24.04.1 noblelocale: utf-8machine: x86_64release: 6.8.0-45-genericsystem: Linuxversion: Ubuntu 24.04.1 noble
Description
The
file
state module has customcheck_cmd
logic for running with a temporary file.This used to work for
file.symlink
, but has regressed in 3006 (LTS).Setup
For example, a onedir installation managing a Debian webserver:
Steps to Reproduce the behavior
Apply the above state:
Expected behavior
As in previous versions, it should create a temporary symlink first and then pass append that to the given command.
Versions Report
salt --versions-report
Additional context
Presumably caused by #63970
The text was updated successfully, but these errors were encountered: