forked from prijindal/kuzzle_dart
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[ci] Move CI to cross-repo doc build & deploy
- Loading branch information
Showing
5 changed files
with
91 additions
and
194 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains 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 characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,28 +3,6 @@ name: Pull request checks | |
on: [pull_request] | ||
|
||
jobs: | ||
# dead-links: | ||
# name: Dead links | ||
# runs-on: ubuntu-latest | ||
# timeout-minutes: 30 | ||
# steps: | ||
# - uses: actions/checkout@v2 | ||
# - name: Cache node modules | ||
# uses: actions/cache@v2 | ||
# env: | ||
# cache-name: cache-node-modules | ||
# with: | ||
# path: ~/.npm | ||
# key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
# restore-keys: | | ||
# ${{ runner.os }}-build-${{ env.cache-name }}- | ||
# ${{ runner.os }}-build- | ||
# ${{ runner.os }}- | ||
# - uses: actions/[email protected] | ||
# with: | ||
# node-version: "12" | ||
# - uses: ./.github/actions/dead-links | ||
|
||
doc-snippets: | ||
name: Doc Snippets | ||
runs-on: ubuntu-latest | ||
|
@@ -55,3 +33,26 @@ jobs: | |
- uses: actions/checkout@v2 | ||
- uses: cedx/setup-dart@v2 | ||
- uses: ./.github/actions/tests | ||
|
||
doc-dead-links: | ||
name: Check dead-links | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
fetch-depth: 0 | ||
- name: Extract references from context | ||
shell: bash | ||
id: extract-refs | ||
run: | | ||
echo "::set-output name=version::$(git describe --abbrev=0 --tags | cut -d. -f 1)" | ||
echo "::set-output name=repo::$(echo $GITHUB_REPOSITORY | cut -d/ -f 2)" | ||
echo "::set-output name=fw-branch::$(if [ $BASE_BRANCH == master ]; then echo master; else echo develop; fi)" | ||
- uses: convictional/[email protected] | ||
with: | ||
owner: kuzzleio | ||
repo: documentation | ||
github_token: ${{ secrets.ACCESS_TOKEN_CI }} | ||
workflow_file_name: dead_links.workflow.yml | ||
ref: ${{ steps.extract-refs.outputs.fw-branch }} | ||
inputs: '{"repo_name": "${{ steps.extract-refs.outputs.repo }}", "branch": "${{ github.head_ref }}", "version": "${{ steps.extract-refs.outputs.version }}"}' |
This file contains 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 characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,30 +7,28 @@ on: | |
- 2-dev | ||
|
||
jobs: | ||
dead-links: | ||
name: Dead links | ||
doc-dead-links: | ||
name: Check dead-links | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Cache node modules | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- uses: actions/[email protected] | ||
fetch-depth: 0 | ||
- name: Extract references from context | ||
shell: bash | ||
id: extract-refs | ||
run: | | ||
echo "::set-output name=version::$(git describe --abbrev=0 --tags | cut -d. -f 1)" | ||
echo "::set-output name=repo::$(echo $GITHUB_REPOSITORY | cut -d/ -f 2)" | ||
echo "::set-output name=fw-branch::$(if [ $BASE_BRANCH == master ]; then echo master; else echo develop; fi)" | ||
- uses: convictional/[email protected] | ||
with: | ||
node-version: "12" | ||
- uses: webfactory/[email protected] | ||
with: | ||
ssh-private-key: ${{ secrets.SSH_KEY }} | ||
- uses: ./.github/actions/dead-links | ||
owner: kuzzleio | ||
repo: documentation | ||
github_token: ${{ secrets.ACCESS_TOKEN_CI }} | ||
workflow_file_name: dead_links.workflow.yml | ||
ref: ${{ steps.extract-refs.outputs.fw-branch }} | ||
inputs: '{"repo_name": "${{ steps.extract-refs.outputs.repo }}", "branch": "${{ github.head_ref }}", "version": "${{ steps.extract-refs.outputs.version }}"}' | ||
|
||
doc-snippets: | ||
name: Doc Snippets | ||
|
@@ -63,39 +61,25 @@ jobs: | |
- uses: cedx/setup-dart@v2 | ||
- uses: ./.github/actions/tests | ||
|
||
doc-dev: | ||
name: Deployment Doc Dev | ||
doc-deploy: | ||
name: Deploy Doc to NEXT | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
# needs: [dead-links, doc-snippets, tests] | ||
needs: [doc-snippets, tests] | ||
needs: [doc-snippets, tests, doc-dead-links] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Cache node modules | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- uses: actions/setup-node@v1 | ||
with: | ||
node-version: "12" | ||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.9" | ||
- uses: ./.github/actions/deploy-doc | ||
env: | ||
NODE_OPTIONS: "--max_old_space_size=4096" | ||
fetch-depth: 0 | ||
- name: Extract references from context | ||
shell: bash | ||
id: extract-refs | ||
run: | | ||
echo "::set-output name=version::$(git describe --abbrev=0 --tags | cut -d. -f 1)" | ||
echo "::set-output name=repo::$(echo $GITHUB_REPOSITORY | cut -d/ -f 2)" | ||
- uses: convictional/[email protected] | ||
with: | ||
S3_BUCKET: docs-next.kuzzle.io | ||
CLOUDFRONT_ID: E2ZCCEK9GRB49U | ||
REGION: us-west-2 | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
FRAMEWORK_BRANCH: develop | ||
owner: kuzzleio | ||
repo: documentation | ||
github_token: ${{ secrets.ACCESS_TOKEN_CI }} | ||
workflow_file_name: child_repo.workflow.yml | ||
ref: develop | ||
inputs: '{"repo_name": "${{ steps.extract-refs.outputs.repo }}", "branch": "${{ github.head_ref }}", "version": "${{ steps.extract-refs.outputs.version }}"}' |
This file contains 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 characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -7,30 +7,28 @@ on: | |
- 1-stable | ||
|
||
jobs: | ||
dead-links: | ||
name: Dead links | ||
doc-dead-links: | ||
name: Check dead-links | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Cache node modules | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- uses: actions/[email protected] | ||
fetch-depth: 0 | ||
- name: Extract references from context | ||
shell: bash | ||
id: extract-refs | ||
run: | | ||
echo "::set-output name=version::$(git describe --abbrev=0 --tags | cut -d. -f 1)" | ||
echo "::set-output name=repo::$(echo $GITHUB_REPOSITORY | cut -d/ -f 2)" | ||
echo "::set-output name=fw-branch::$(if [ $BASE_BRANCH == master ]; then echo master; else echo develop; fi)" | ||
- uses: convictional/[email protected] | ||
with: | ||
node-version: "12" | ||
- uses: webfactory/[email protected] | ||
with: | ||
ssh-private-key: ${{ secrets.SSH_KEY }} | ||
- uses: ./.github/actions/dead-links | ||
owner: kuzzleio | ||
repo: documentation | ||
github_token: ${{ secrets.ACCESS_TOKEN_CI }} | ||
workflow_file_name: dead_links.workflow.yml | ||
ref: ${{ steps.extract-refs.outputs.fw-branch }} | ||
inputs: '{"repo_name": "${{ steps.extract-refs.outputs.repo }}", "branch": "${{ github.head_ref }}", "version": "${{ steps.extract-refs.outputs.version }}"}' | ||
|
||
doc-snippets: | ||
name: Doc Snippets | ||
|
@@ -63,42 +61,28 @@ jobs: | |
- uses: cedx/setup-dart@v2 | ||
- uses: ./.github/actions/tests | ||
|
||
doc-prod: | ||
name: Deployment Doc Prod | ||
doc-deploy: | ||
name: Deploy Doc to Prod | ||
runs-on: ubuntu-latest | ||
timeout-minutes: 30 | ||
# needs: [dead-links, doc-snippets] | ||
needs: [doc-snippets] | ||
needs: [doc-snippets, tests, doc-dead-links] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Cache node modules | ||
uses: actions/cache@v2 | ||
env: | ||
cache-name: cache-node-modules | ||
with: | ||
path: ~/.npm | ||
key: ${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }} | ||
restore-keys: | | ||
${{ runner.os }}-build-${{ env.cache-name }}- | ||
${{ runner.os }}-build- | ||
${{ runner.os }}- | ||
- uses: actions/setup-node@v1 | ||
with: | ||
node-version: "12" | ||
- name: Set up Python | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: "3.9" | ||
- uses: ./.github/actions/deploy-doc | ||
env: | ||
NODE_OPTIONS: "--max_old_space_size=4096" | ||
fetch-depth: 0 | ||
- name: Extract references from context | ||
shell: bash | ||
id: extract-refs | ||
run: | | ||
echo "::set-output name=version::$(git describe --abbrev=0 --tags | cut -d. -f 1)" | ||
echo "::set-output name=repo::$(echo $GITHUB_REPOSITORY | cut -d/ -f 2)" | ||
- uses: convictional/[email protected] | ||
with: | ||
FRAMEWORK_BRANCH: master | ||
S3_BUCKET: docs.kuzzle.io | ||
CLOUDFRONT_ID: E3D6RP0POLCJMM | ||
REGION: us-west-2 | ||
AWS_SECRET_ACCESS_KEY: ${{ secrets.AWS_SECRET_ACCESS_KEY }} | ||
AWS_ACCESS_KEY_ID: ${{ secrets.AWS_ACCESS_KEY_ID }} | ||
owner: kuzzleio | ||
repo: documentation | ||
github_token: ${{ secrets.ACCESS_TOKEN_CI }} | ||
workflow_file_name: child_repo.workflow.yml | ||
ref: develop | ||
inputs: '{"repo_name": "${{ steps.extract-refs.outputs.repo }}", "branch": "${{ github.head_ref }}", "version": "${{ steps.extract-refs.outputs.version }}"}' | ||
|
||
deploy-package: | ||
name: Publish Package | ||
|