Browse Source
Merge pull request #3 from Anatole-DC/netlify_doc
Netlify doc
pull/4/head
Anatole De Chauveron
4 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
3 changed files with
65 additions and
1 deletions
-
.circleci/config.yml
-
.gitignore
-
netlify.toml
|
|
@ -71,6 +71,38 @@ jobs: |
|
|
exit 1 |
|
|
exit 1 |
|
|
fi |
|
|
fi |
|
|
|
|
|
|
|
|
|
|
|
server-doc-build: |
|
|
|
|
|
<<: *shared-config |
|
|
|
|
|
steps: |
|
|
|
|
|
- checkout |
|
|
|
|
|
- restore_cache: |
|
|
|
|
|
key: dependencies-{{ checksum "package.json" }}-v1 |
|
|
|
|
|
- run: yarn doc:build |
|
|
|
|
|
- run: |
|
|
|
|
|
name: Copy deployment artifacts to workspace |
|
|
|
|
|
command: | |
|
|
|
|
|
cp docs/ /tmp/server-doc -r |
|
|
|
|
|
- store_artifacts: |
|
|
|
|
|
path: /tmp/server-doc |
|
|
|
|
|
- persist_to_workspace: |
|
|
|
|
|
root: /tmp |
|
|
|
|
|
paths: |
|
|
|
|
|
- server-doc |
|
|
|
|
|
|
|
|
|
|
|
server-doc-deploy: |
|
|
|
|
|
<<: *shared-config |
|
|
|
|
|
working_directory: ~/deploy-doc-server |
|
|
|
|
|
steps: |
|
|
|
|
|
- attach_workspace: |
|
|
|
|
|
at: /tmp |
|
|
|
|
|
- run: |
|
|
|
|
|
name: Install netlify |
|
|
|
|
|
command: | |
|
|
|
|
|
yarn add -D netlify-cli |
|
|
|
|
|
- run: |
|
|
|
|
|
name: Deploy app |
|
|
|
|
|
command: yarn netlify deploy --auth $NETLIFY_AUTH_TOKEN --dir /tmp/server-doc --site $NETLIFY_SITE_ID --prod |
|
|
|
|
|
|
|
|
workflows: |
|
|
workflows: |
|
|
version: 2 |
|
|
version: 2 |
|
|
build-test-and-lint: |
|
|
build-test-and-lint: |
|
|
@ -94,3 +126,12 @@ workflows: |
|
|
filters: |
|
|
filters: |
|
|
branches: |
|
|
branches: |
|
|
only: main |
|
|
only: main |
|
|
|
|
|
- server-doc-build: |
|
|
|
|
|
requires: |
|
|
|
|
|
- build |
|
|
|
|
|
- lint |
|
|
|
|
|
- back-test-e2e |
|
|
|
|
|
- back-test-unit |
|
|
|
|
|
filters: |
|
|
|
|
|
branches: |
|
|
|
|
|
only: main |
|
|
@ -35,3 +35,5 @@ lerna-debug.log* |
|
|
!.vscode/extensions.json |
|
|
!.vscode/extensions.json |
|
|
.env |
|
|
.env |
|
|
docs/ |
|
|
docs/ |
|
|
|
|
|
# Local Netlify folder |
|
|
|
|
|
.netlify |
|
|
@ -0,0 +1,21 @@ |
|
|
|
|
|
# example netlify.toml |
|
|
|
|
|
[build] |
|
|
|
|
|
command = "yarn run build" |
|
|
|
|
|
functions = "netlify/functions" |
|
|
|
|
|
publish = "." |
|
|
|
|
|
|
|
|
|
|
|
## Uncomment to use this redirect for Single Page Applications like create-react-app. |
|
|
|
|
|
## Not needed for static site generators. |
|
|
|
|
|
#[[redirects]] |
|
|
|
|
|
# from = "/*" |
|
|
|
|
|
# to = "/index.html" |
|
|
|
|
|
# status = 200 |
|
|
|
|
|
|
|
|
|
|
|
## (optional) Settings for Netlify Dev |
|
|
|
|
|
## https://github.com/netlify/cli/blob/main/docs/netlify-dev.md#project-detection |
|
|
|
|
|
#[dev] |
|
|
|
|
|
# command = "yarn start" # Command to start your dev server |
|
|
|
|
|
# port = 3000 # Port that the dev server will be listening on |
|
|
|
|
|
# publish = "dist" # Folder with the static content for _redirect file |
|
|
|
|
|
|
|
|
|
|
|
## more info on configuring this file: https://www.netlify.com/docs/netlify-toml-reference/ |