Commit 91469d29 authored by Andreas Böttger's avatar Andreas Böttger 😬
Browse files

Merge branch '5-veranstaltungsskript-baut-nicht-mehr' into 'master'

Resolve "Veranstaltungsskript baut nicht mehr"

Closes #5

See merge request !4
parents 57aaadf1 1a4c4979
...@@ -6,27 +6,25 @@ stages: ...@@ -6,27 +6,25 @@ stages:
- review - review
- deploy - deploy
build_pandoc: #pdfs:
stage: build # stage: build
only: # only:
- branches # - branches
tags: # tags:
- development # - development
script: # script:
- pwd # - pwd
- sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/pandoc4gitbook # - sudo docker pull docker.rz.tu-harburg.de:5000/docker/pandoc4gitbook-glr:latest
- sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/pandoc --list-extensions # - sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/pandoc4gitbook-glr
- mkdir -p book_pdf; sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/pandoc .pandoc-config.yml book.md -o book_pdf/pandocbook.pdf --template=gitbook.latex --latex-engine=xelatex -H preamble.tex -f markdown+autolink_bare_uris --highlight-style=zenburn # - sudo docker pull docker.rz.tu-harburg.de:5000/docker/pandoc-glr:latest
- sudo chown -R gitlab-runner:gitlab-runner $HOME # - mkdir -p book_pdf; sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/pandoc-glr .pandoc-config.yml book.md -o book_pdf/pandocbook.pdf
# artifacts:
# name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
# paths:
# # Was hier nicht gelistet ist, landet auch nicht in der `review`-Phase
# - book_pdf
artifacts: static_sites:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
paths:
# Was hier nicht gelistet ist, landet auch nicht in der `review`-Phase
- book_pdf
build_gitbook:
stage: build stage: build
only: only:
- branches - branches
...@@ -34,14 +32,10 @@ build_gitbook: ...@@ -34,14 +32,10 @@ build_gitbook:
- development - development
script: script:
- pwd - pwd
#- gitbook install - sudo docker pull docker.rz.tu-harburg.de:5000/docker/gitbook-glr:latest
#- gitbook build - sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/gitbook-glr install
# Quick and dirty hack: The creation of the PDF document does not always work. This seems to be a bug. - sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/gitbook-glr build
#- mkdir -p book_pdf; until gitbook pdf ./ ./book_pdf/book.pdf; do printf "$s\n" "failure, next try …"; done - mkdir -p book_pdf; sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/gitbook-glr pdf ./ ./book_pdf/book.pdf
- sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/gitbook install
- sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/gitbook build
- mkdir -p book_pdf; sudo docker run --rm -v $(pwd):/source docker.rz.tu-harburg.de:5000/docker/gitbook pdf ./ ./book_pdf/book.pdf
- sudo chown -R gitlab-runner:gitlab-runner $HOME
artifacts: artifacts:
name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}" name: "${CI_JOB_NAME}_${CI_COMMIT_REF_NAME}"
...@@ -93,9 +87,11 @@ deploy: ...@@ -93,9 +87,11 @@ deploy:
tags: tags:
- production - production
script: script:
- pwd
- sshpass -p "$SSH_PASSWD" ssh -p "$SSH_PORT" $SSH_USER@$HOST_NAME "mkdir -p /usr/share/nginx/html/production" - sshpass -p "$SSH_PASSWD" ssh -p "$SSH_PORT" $SSH_USER@$HOST_NAME "mkdir -p /usr/share/nginx/html/production"
- sshpass -p "$SSH_PASSWD" scp -P "$SSH_PORT" -r _book/* $SSH_USER@$HOST_NAME:/usr/share/nginx/html/production - sshpass -p "$SSH_PASSWD" scp -P "$SSH_PORT" -r _book/* $SSH_USER@$HOST_NAME:/usr/share/nginx/html/production
- sshpass -p "$SSH_PASSWD" scp -P "$SSH_PORT" -r book_pdf $SSH_USER@$HOST_NAME:/usr/share/nginx/html/production - sshpass -p "$SSH_PASSWD" scp -P "$SSH_PORT" -r book_pdf $SSH_USER@$HOST_NAME:/usr/share/nginx/html/production
environment: environment:
name: production name: production
url: https://$PROXY_HOST_NAME/$CI_PROJECT_PATH/ #url: http://$HOST_NAME$COLON$HTTP_PORT/production/
url: https://$PROXY_HOST_NAME/$CI_PROJECT_PATH/
\ No newline at end of file
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment