Skip to content

Instantly share code, notes, and snippets.

@gmmcal
Created August 17, 2018 21:20
Show Gist options
  • Save gmmcal/05421658b82e2a6c30f0ec7d7244e452 to your computer and use it in GitHub Desktop.
Save gmmcal/05421658b82e2a6c30f0ec7d7244e452 to your computer and use it in GitHub Desktop.
FTP deployment with Dandelion gem and Gitlab
before_script:
- apt-get update -qq && apt-get install -y -qq pkg-config cmake
- ruby -v
- which ruby
- gem install dandelion --no-ri --no-rdoc
- gem install net-sftp --no-ri --no-rdoc
deploy:
script:
- dandelion deploy $CI_COMMIT_SHA
environment:
name: production
only:
- master
# Required
scheme: <%= ENV['FTP_SCHEME'] %> # sftp
host: <%= ENV['FTP_HOST'] %> # ftp.example.com
username: <%= ENV['FTP_USERNAME'] %>
password: <%= ENV['FTP_PASSWORD'] %>
path: <%= ENV['FTP_PATH'] %>
# for more options, check https://github.com/scttnlsn/dandelion
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment