kind: pipeline
type: docker
name: bogazici-admin

trigger:
  event:
    - push
  branch:
    - test

steps:
  - name: deploy-test-admin
    image: appleboy/drone-ssh
    when:
      branch:
        - test
    settings:
      host:
        from_secret: SERVER_HOST
      username:
        from_secret: SERVER_USER
      key:
        from_secret: SERVER_SSH_KEY
      port: 22
      script:
        - cd /opt/projects/bogazici/corporate-admin/test/admin
        - bash scripts/deploy-test.sh
