• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved schedule operations after git pull event

paskuale

Basic Pleskian
Server operating system version
Debian 10.13
Plesk version and microupdate number
Obsidian v.18.0.53
Hi, every time I pull from the repository I have a small difference in the .htaccess file that forces me to manually update each pull operation, is there a way to schedule the operation ?
Thanks
 
Hello,

If you are using Git extension to pull your changes from a remote repo, you can use Deploy Action in Domain -> Git -> Settings (lower right corner of Git overview card). There you can enable "Enable additional deployment actions" checkbox and write any shell code you want. This code will be executed on every Deploy, both for manually from extension UI, and automatic using extension hooks.
 
Thanks so much for the suggestion @EvgeniyKovrizhnikov , it was just what I was looking for :) he advises me to insert a command for each new line, but a command of this type works if I execute it from the shell, if I insert it as an addition deployment actions it does not recognize it. Where am I wrong?
the command is this:
/opt/plesk/php/8.1/bin/php ./bin/console cache:clear
error return this:
-: /opt/plesk/php/8.1/bin/php: No such file or directory
thanks ;)
 
Hi all,
I continue on this thread because the problem is close to the previous case... every time I run a git pull it overwrites (rightly) the .htaccess file, and I promptly have to update a string within the same file:
Code:
Options +FollowSymlinks
in -->
Code:
Options +SymLinksIfOwnerMatch
any suggestions to overcome this boring step ? Thanks
 
Disabling "Restrict the ability to follow symbolic links" on the "Websites & Domains" > "Hosting & DNS" > "Apache & Nginx" page would allow you to use the "+FollowSymlinks" option. If you are no on a shared hosting environment and control your code yourself, it is a low risk change.
 
Back
Top