2023-02-28 11:47:54 +01:00
|
|
|
stages:
|
2023-02-28 16:11:09 +01:00
|
|
|
- build-deps
|
2023-02-28 11:47:54 +01:00
|
|
|
- build
|
|
|
|
- deploy
|
2023-02-28 16:11:09 +01:00
|
|
|
|
|
|
|
variables:
|
|
|
|
GIT_SUBMODULE_STRATEGY: recursive
|
2023-02-28 11:47:54 +01:00
|
|
|
|
|
|
|
prepare_folders:
|
|
|
|
environment: $CI_COMMIT_BRANCH
|
|
|
|
stage: .pre
|
|
|
|
image: alpine:latest
|
|
|
|
script:
|
|
|
|
- mkdir -p .public
|
2023-02-28 16:11:09 +01:00
|
|
|
- mkdir -p .public/docs
|
|
|
|
- chown -R 1000:1000 .public/docs
|
2023-02-28 11:47:54 +01:00
|
|
|
cache:
|
|
|
|
paths:
|
|
|
|
- .public
|
2023-02-28 16:11:09 +01:00
|
|
|
rules:
|
|
|
|
- if: $CI_COMMIT_BRANCH =~ /^make/
|
|
|
|
|
|
|
|
render_pdf:
|
|
|
|
environment: $CI_COMMIT_BRANCH
|
|
|
|
stage: build-deps
|
|
|
|
when: manual
|
|
|
|
image:
|
|
|
|
name: astefanutti/decktape
|
|
|
|
entrypoint: ["/bin/sh", "-c"]
|
|
|
|
script:
|
|
|
|
- "node /decktape/decktape.js -s 2560x1440 reveal --chrome-path chromium-browser --chrome-arg=--no-sandbox --chrome-arg=--disable-web-security index.html .public/docs/slide.pdf"
|
|
|
|
cache:
|
2023-02-28 11:47:54 +01:00
|
|
|
paths:
|
|
|
|
- .public
|
2023-02-28 16:11:09 +01:00
|
|
|
artifacts:
|
|
|
|
paths:
|
|
|
|
- .public/docs
|
|
|
|
expire_in: 2 week
|
2023-02-28 11:47:54 +01:00
|
|
|
rules:
|
|
|
|
- if: $CI_COMMIT_BRANCH =~ /^make/
|
|
|
|
|
2023-02-28 16:11:09 +01:00
|
|
|
render_ppt:
|
|
|
|
needs: [render_pdf]
|
2023-02-28 11:47:54 +01:00
|
|
|
environment: $CI_COMMIT_BRANCH
|
|
|
|
stage: build
|
|
|
|
when: manual
|
|
|
|
image:
|
2023-02-28 16:11:09 +01:00
|
|
|
name: linuxserver/libreoffice
|
2023-02-28 11:47:54 +01:00
|
|
|
entrypoint: ["/bin/sh", "-c"]
|
|
|
|
script:
|
2023-02-28 16:11:09 +01:00
|
|
|
- 'soffice --headless --infilter="impress_pdf_import" --convert-to "pptx:Impress Office Open XML" .public/docs/slide.pdf --outdir .public/docs/'
|
2023-02-28 11:47:54 +01:00
|
|
|
cache:
|
|
|
|
paths:
|
|
|
|
- .public
|
|
|
|
artifacts:
|
|
|
|
paths:
|
2023-02-28 16:11:09 +01:00
|
|
|
- .public/docs
|
|
|
|
expire_in: 2 week
|
2023-02-28 11:47:54 +01:00
|
|
|
rules:
|
|
|
|
- if: $CI_COMMIT_BRANCH =~ /^make/
|
2023-02-27 11:25:08 +01:00
|
|
|
|
|
|
|
pages:
|
2023-02-27 22:08:46 +01:00
|
|
|
environment: $CI_COMMIT_BRANCH
|
|
|
|
stage: deploy
|
|
|
|
when: manual
|
2023-02-27 11:25:08 +01:00
|
|
|
script:
|
|
|
|
- cp -r * .public
|
2023-02-27 22:08:46 +01:00
|
|
|
- mv .public/custom_files/gulpfile.js .public/reveal.js/
|
|
|
|
- '[ -d "public/$CI_COMMIT_BRANCH" ] && { rm -rf public/$CI_COMMIT_BRANCH/*; mv .public/* public/$CI_COMMIT_BRANCH/; } || { mkdir -p public/$CI_COMMIT_BRANCH; mv .public/* public/$CI_COMMIT_BRANCH/; }'
|
|
|
|
cache:
|
|
|
|
paths:
|
2023-02-28 11:47:54 +01:00
|
|
|
- .public
|
2023-02-27 22:08:46 +01:00
|
|
|
- public
|
|
|
|
rules:
|
|
|
|
- if: $CI_COMMIT_BRANCH =~ /^make/
|