-
-
Save dotob/2405dab957f6c3e288eabb1911edcaf2 to your computer and use it in GitHub Desktop.
Revisions
-
dotob created this gist
Sep 4, 2019 .There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,103 @@ # this job builds the project and its dependencies r4c: stage: build image: node:8 # only: # changes: # - r4c/**/* # - types/**/* script: - yarn run writeVersions - cd types - yarn --cache-folder ../.yarn-cache - cd - - cd base - yarn --cache-folder ../.yarn-cache - cd - - cd common-ui - yarn --cache-folder ../.yarn-cache - cd - - cd r4c - yarn --cache-folder ../.yarn-cache - yarn build - cd doc - node md2html.js - cp help.html ../dist - mkdir ../dist/screens - cp screens/* ../dist/screens - cd - artifacts: expire_in: 1 week paths: - r4c/dist/ cache: paths: - .yarn-cache/ # deploy template .deploy_r4c_template: stage: deploy image: node:8 dependencies: - r4c before_script: - cd r4c - yarn --cache-folder ../.yarn-cache cache: policy: pull paths: - .yarn-cache/ # this jobs deploys the app on branches to a temp url r4c2test: extends: .deploy_r4c_template environment: name: r4c_test script: - yarn deploytest when: manual except: - master # this job deploys the app manually to staging on any branch but master r4c2staging_manual: extends: .deploy_r4c_template environment: name: r4c_staging url: https://r4c-staging.rose.dental script: - yarn deploystaging when: manual except: - master # this job deploys the app automatically to staging on the master branch r4c2staging: extends: .deploy_r4c_template environment: name: r4c_staging url: https://r4c-staging.rose.dental script: - yarn deploystaging only: - master r4c2prod: extends: .deploy_r4c_template environment: name: r4c_prod url: https://r4c.rose.dental script: - yarn deployprod when: manual only: - master r4c2demo: extends: .deploy_r4c_template environment: name: r4c_demo url: https://r4c-demo.rose.dental script: - yarn deploydemo when: manual