.gitlab-ci.yml 632 Bytes
Newer Older
Christophe Benz's avatar
Christophe Benz committed
1
image: jailbreakparis/validata-doc:latest
Christophe Benz's avatar
Christophe Benz committed
2

3
build_gitbook:
Christophe Benz's avatar
Christophe Benz committed
4
  stage: build
5 6 7 8 9 10 11 12 13 14
  script:
    - ./build.sh
  artifacts:
    paths:
      - _book/

deploy_gitbook:
  stage: deploy
  only:
    - master
15
  variables:
Christophe Benz's avatar
Christophe Benz committed
16
    PDF_FILE: Socle Commun des Données Locales.pdf
17 18 19 20 21 22
  before_script:
    # Load SSH agent
    - eval $(ssh-agent -s)
    - ssh-add <(echo "$SSH_PRIVATE_KEY")
    - mkdir -p ~/.ssh
    - ssh-keyscan -t rsa go.validata.fr >> ~/.ssh/known_hosts
Christophe Benz's avatar
Christophe Benz committed
23
  script:
Christophe Benz's avatar
Christophe Benz committed
24
    - rsync -avz --delete _book/ "$PDF_FILE" validata@go.validata.fr:validata-doc-html/
25 26 27
  environment:
    name: documentation
    url: https://scdl.opendatafrance.net/docs/