# This is a sample build configuration for PHP.
# Check our guides at https://confluence.atlassian.com/x/e8YWN for more examples.
# Only use spaces to indent your .yml configuration.
# -----
# You can specify a custom docker image from Docker Hub as your build environment.
image: samueldebruyn/debian-git
pipelines:
  branches:
    master:
    - step:
        caches:
          - composer
        script:
          - apt-get update
          - apt-get -qq install git-ftp
          - git config git-ftp.url "$FTP_HOST"
          - git config git-ftp.user "$FTP_USERNAME"
          - git config git-ftp.password "$FTP_PASSWORD"
          - git ftp push -v
    develop:
      - step:
          caches:
            - composer
          script:
            - apt-get update
            - apt-get -qq install git-ftp
            - git config git-ftp.url "$FTP_HOST"
            - git config git-ftp.user "$FTP_USERNAME_DEV"
            - git config git-ftp.password "$FTP_PASSWORD_DEV"
            - git ftp push -v