In most cases, file publishing is not enough to finish web site
deployment. For example, if you are using frameworks like Ruby on Rails,
you may need to run a data migration task after deployment with a
command like this: bin/rails db:migrate
.
Plesk gives you the ability to set a number of additional actions that
will be performed each time the files are deployed to the web site.
Go to Websites & Domains > Git, click Repository Settings,
select Enable additional deploy actions, and specify one or more
shell commands that should be run every time this repository is
deployed. Each command should be started on a new line.
Note: If SSH is forbidden for the user on Linux, all the specified commands
will run in a chrooted environment. The home directory of a
subscription’s system user is treated as the file system root for
that subscription, and no executable files outside the chroot jail
can be run. For example, if the path to your site is
/var/www/vhosts/example.com/httpdocs
, then, in a chrooted
environment, the path will be ./httpdocs
, so you will not be able
to execute commands outside one level above the /httpdocs
directory.