Repository navigation
Replies: 1 comment
|
One regression case for #4275: The fresh-deploy test can check three properties together: no write access for other users, a tracked executable like |
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
Deployer Version
7.5.12 (v8.0.5 and master are affected too: same
deploy:update_codein recipe/shopware.php)Target OS
Ubuntu 24.04.5 LTS
Which PHP version are you using?
PHP 8.5
Content of deploy.php or deploy.yaml
Steps to reproduce
The Shopware recipe replaces
deploy:update_codewith an rsync upload of the local checkout:upload()runsrsync -azP, and-aincludes-p, so the file modes of the local checkout are copied to the server. CI runners usually check out with umask0000(e.g. the GitLab Runner Docker executor), so the checkout is666/777.recipe/shopware.phpfrom a checkout made with umask0000(or runchmod -R a+w .on the local checkout first).find ~/shop/current/ -xdev -perm -o+w -not -type l | wc -l.Expected:
0. Modes follow the remote umask, like with the default git-baseddeploy:update_code(git archive | tar -xapplies the umask when extracting as a non-root user).Actual:
-rw-rw-rw-drwxrwxrwxvendor/, cache, compiled theme) follow the remote umask, e.g.664/775Every other user on the host (web server, mail, monitoring agents, other shell users) can therefore modify PHP code and config in the active release.
Proposed fix: add
--no-perms --chmod=ugo=rwXto the upload options, so new files get the remote umask and executable bits are kept. PR: #4275All reactions