Deploy to FTPS server from Drone CI build
Go to file
Christoph Schlosser 30922df403
Merge pull request #16 from nagos/master
FTP connection max retries
2020-03-30 21:40:43 +02:00
Dockerfile Use alpine:edge to get lftp 4.8.4 2018-09-12 21:54:07 +02:00
LICENSE Create LICENSE 2017-10-26 02:37:13 +02:00
README.md Required vs optional 2019-05-17 20:17:33 +02:00
upload.sh FTP connection max retries 2020-03-28 19:17:38 +03:00

Deploy to FTP(S) server from Drone CI

Docker Stars Docker Pulls Docker Build Docker Layers

Usage

You have to set the username and password for your FTP server in the FTP_USERNAME and FTP_PASSWORD secret.

Required settings

environment:
    FTP_USERNAME:
      from_secret: username
    FTP_PASSWORD:
      from_secret: password
    PLUGIN_HOSTNAME: example.com:21

Optional settings

environment:
    PLUGIN_DEST_DIR: /path/to/dest (default /)
    PLUGIN_SRC_DIR: /path/to/dest (default ./)
    PLUGIN_SECURE: true | false (default true)
    PLUGIN_VERIFY: false
    PLUGIN_EXCLUDE: (egrep like pattern matching)
    PLUGIN_INCLUDE: (egrep like pattern matching)

Full file example

kind: pipeline
name: default

steps:
- name: master_build
  image: cschlosser/drone-ftps
  environment:
    FTP_USERNAME:
      from_secret: username
    FTP_PASSWORD:
      from_secret: password
    PLUGIN_HOSTNAME: example.com:21

    PLUGIN_SECURE: false
    PLUGIN_VERIFY: false
    PLUGIN_EXCLUDE: ^\.git/$
  when:
    branch:
    - master
    event:
    - push

- name: develop_build
  image: cschlosser/drone-ftps
  environment:
    FTP_USERNAME:
      from_secret: username
    FTP_PASSWORD:
      from_secret: password
    PLUGIN_HOSTNAME: example.com:21
    PLUGIN_DEST_DIR: /develop
    PLUGIN_SECURE: false
    PLUGIN_VERIFY: false
    PLUGIN_EXCLUDE: ^\.git/$
  when:
    branch:
    - develop
    event:
    - push