.gitlab-ci.yml 548 Bytes
Newer Older
1 2 3
stages:
  - build
  - deploy
4

5 6 7 8 9 10 11 12
beamer-build:
  image: aergus/latex
  stage: build
  script:
    - make
  artifacts:
    paths:
      - "*.pdf"
Quentin Duchemin's avatar
Quentin Duchemin committed
13
  tags: [build]
14 15

synchronize:
Quentin Duchemin's avatar
Quentin Duchemin committed
16
  image: debian:stable-slim
17 18 19
  stage: deploy
  before_script:
    - apt-get update -y
Quentin Duchemin's avatar
Quentin Duchemin committed
20
    - apt-get install -y openssh-client sshpass
21
  script:
Quentin Duchemin's avatar
Quentin Duchemin committed
22
    - sshpass -p ${SFTP_PASSWORD} sftp -o StrictHostKeyChecking=no -P 2222 ${SFTP_USER}@${SFTP_HOST}:uploads <<< $'mkdir api\n cd api\n put *.pdf linux_adv.pdf'
23 24
  dependencies:
    - beamer-build
Quentin Duchemin's avatar
Quentin Duchemin committed
25
  tags: [build]
26
  only:
Quentin Duchemin's avatar
Quentin Duchemin committed
27
    - master