kind: pipeline
name: default

steps:
- name: submodules
  image: alpine/git
  commands:
  - git submodule update --init --recursive --remote

- name: build
  image: plugins/hugo
  settings:
    hugo_version: 0.80.0
    pull: always
    validate: true

- name: deploy
  image: appleboy/drone-scp
  settings:
    host: 192.168.1.150
    target: /mnt/data/websites/recipes/site/
    source: public/*
    username:
      from_secret: ssh_username
    password:
      from_secret: ssh_password
    port:
      from_secret: ssh_port
  when:
    branch:
    - master
    event:
      exclude:
      - pull_request