drone.io + Jekyll + FTP deploy

13 Jun 2019

Today I decided to move my blog from Github Pages to my web host. I installed drone.io on my server, opened docs and tried to write a simple pipeline that will build Jekyll page and deploy it using FTP connection.

.drone.yml

pipeline:
  build:
    image: jekyll/builder
    commands:
      - chown -R jekyll /drone/src
      - jekyll build
  deploy:
    image: cschlosser/drone-ftps
    hostname: s12.mydevil.net:21
    secrets: [ftp_username, ftp_password]
    dest_dir: /domains/motyka.pro/public_html
    src_dir: /_site
    clean_dir: true

There is two secrets that you need to provide in drone.io settings:

  • ftp_username
  • ftp_password

You will also need to change ftp server host and directory in .drone.yml, just replace s12.mydevil.net:21 and /domains/motyka.pro/public_html with something else.