• 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.

Forwarded to devs Git deploy actions script not recognising end of if

captainhook

Basic Pleskian
Username:

TITLE

Git deploy actions script not recognising end of if

PRODUCT, VERSION, OPERATING SYSTEM, ARCHITECTURE

Plesk Obsidian v18.0.52_build1800230516.12 os_RedHat el8, Rocky Linux 8.8 (Green Obsidian),

PROBLEM DESCRIPTION

Git deploy actions seems to not be parsing if statement correctly and causing deployment to fail.

STEPS TO REPRODUCE

  1. Add Git repo to site
  2. Modify deploy actions with code below
  3. Deploy the repository

Bash:
if [ "$remotehash" != "$localhash" ]; then
  echo "change found"
else
  echo "no change found, deploy skipped"
fi

ACTUAL RESULT

When I hit deploy, I see the following error:
/bin/sh: -c: line 1: syntax error: unexpected end of file

EXPECTED RESULT

The deployment should not fail.

ANY ADDITIONAL INFORMATION

(DID NOT ANSWER QUESTION)

YOUR EXPECTATIONS FROM PLESK SERVICE TEAM

Confirm bug
 
Could you please explain where exactly the deploy actions are modified? E.g. in which file or dialog?
 
Hi Peter,

The deploy actions are modified under domain > Git > Repository Settings > Deploy actions

To my knowledge, this is the only place deploy actions are set.
 
According to developers the product issue is already known in the scope of another issue. The recommended workaround is to switch the domain to /bin/bash shell and to put additional actions into the bash script. Then call this script from "additional deployment actions". Internal ID EXTGIT-22.
 
Back
Top