Skip to content

Instantly share code, notes, and snippets.

@westhouseit
Created June 28, 2019 11:44
Show Gist options
  • Save westhouseit/5310a21ca6e6218ebc20ba94530bb0a6 to your computer and use it in GitHub Desktop.
Save westhouseit/5310a21ca6e6218ebc20ba94530bb0a6 to your computer and use it in GitHub Desktop.
Deploy via FTP from GitLab
variables:
STAGE_FTP_HOST: "{hostname or ip}"
deploy_staging:
stage: deploy
environment: Staging
script:
- apt-get update -qq && apt-get install -y -qq git-ftp
# Set user and pass in Gitlab > Settings > CI/CD > Variables
- git-ftp push -u $STAGE_FTP_USER $STAGE_FTP_HOST -p $STAGE_FTP_PASS --syncroot .
# See .git-ftp-ignore
only:
- master
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment