deployer
deployer copied to clipboard
current_path not updated after deploy:symlink or rollback
| Q | A |
|---|---|
| Issue Type | Bug - Feature Request |
| Deployer Version | N/A |
| Local Machine OS | Any |
| Remote Machine OS | Any |
Description
The variable current_path does not updated on deploy:symlink or rollback.
It would be good to have a task to update it, or to make it part of these two tasks.
Steps to reproduce
Use the current_path inside a run command before deploy:symlink or rollback, and after.
You will notice the current_path is not refreshed.
Content of deploy.php
task("doSomethingWithCurrentPath", function () {
run("cd {{current_path}} && pwd");
});
desc('Deploy your project');
task('deploy', [
'deploy:info',
'deploy:prepare',
'deploy:lock',
'deploy:release',
'deploy:update_code',
'deploy:shared',
'deploy:vendors',
'doSomethingWithCurrentPath',
'deploy:writable',
'artisan:storage:link',
'artisan:view:clear',
'artisan:config:cache',
'artisan:optimize',
'deploy:symlink',
'doSomethingWithCurrentPath',
'deploy:unlock',
'cleanup',
]);
Output log
N/A
I've been stuck on this for a day too and tried multiple suggestions from both GitHub and Stack Overflow. I wonder if anyone knows what the fix is.
I am cleaning up on issues. Fill free to reopen if needed. Also, we have a new section available: discussions.