• Our team is looking to connect with folks who use email services provided by Plesk, or a premium service. If you'd like to be part of the discovery process and share your experiences, we invite you to complete this short screening survey. If your responses match the persona we are looking for, you'll receive a link to schedule a call at your convenience. We look forward to hearing from you!
  • We are looking for U.S.-based freelancer or agency working with SEO or WordPress for a quick 30-min interviews to gather feedback on XOVI, a successful German SEO tool we’re looking to launch in the U.S.
    If you qualify and participate, you’ll receive a $30 Amazon gift card as a thank-you. Please apply here. Thanks for helping shape a better SEO product for agencies!
  • The BIND DNS server has already been deprecated and removed from Plesk for Windows.
    If a Plesk for Windows server is still using BIND, the upgrade to Plesk Obsidian 18.0.70 will be unavailable until the administrator switches the DNS server to Microsoft DNS. We strongly recommend transitioning to Microsoft DNS within the next 6 weeks, before the Plesk 18.0.70 release.
  • The Horde component is removed from Plesk Installer. We recommend switching to another webmail software supported in Plesk.

Issue yarn: command not found when running Git deployment using non-admin account

captainhook

Basic Pleskian
I have granted chrooted SSH access on the domain's hosting settings.

I have also added all the binaries in /opt/plesk/node/18/bin/ to the domain's chroot.

However when I run a git deployment with the following code in the additional deployment actions:
Bash:
#!/bin/bash
rm -rf tmp
(PATH=/opt/plesk/node/18/bin/:$PATH; yarn install && sed -i 's/const defaultCommand = "dev";/const defaultCommand = "start";/g' node_modules/next/dist/bin/next && yarn build &> npm-install.log)
mkdir tmp
touch tmp/restart.txt

I get this error:
Bash:
-: yarn: command not found

I appear to be able to run something like 'yarn --version' successfully under the domain > Node.js > Run Node.js commands. So I'm confused why it fails in the git deployment's additional actions step.
 
Have you tried the same with the fully qualified path to yarn starting at /var/www/vhosts/<your subscription>/.....<your binary path> etc.?
 
Yeap, same thing:
-: /var/www/vhosts/domain.com/opt/plesk/node/18/bin/yarn: No such file or directory

I also tried running yarn through the terminal:
bash: opt/plesk/node/18/bin/yarn: /opt/plesk/node/18/bin/node: bad interpreter: No such file or directory
 
I tried replacing the Git additional deployment script with the following:
#!/bin/bash
rm -rf tmp
/opt/plesk/node/18/bin/yarn install &> npm-install.log
sed -i 's/const defaultCommand = "dev";/const defaultCommand = "start";/g' node_modules/next/dist/bin/next &>> npm-install.log
/opt/plesk/node/18/bin/yarn build &>> npm-install.log
mkdir tmp
touch tmp/restart.txt

I got:
-: /opt/plesk/node/18/bin/yarn: /opt/plesk/node/18/bin/node: bad interpreter: No such file or directory
 
Has this been reproducible internally? I can run deployments with these additional commands using the admin account, but no other accounts can.
 
Back
Top