Skip to content

Commit

Permalink
deploy pipeline for docs
Browse files Browse the repository at this point in the history
  • Loading branch information
ludamad0 committed Nov 18, 2023
1 parent 9a970f9 commit 3b5449d
Show file tree
Hide file tree
Showing 5 changed files with 21 additions and 7 deletions.
12 changes: 9 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -922,12 +922,18 @@ jobs:
steps:
- *checkout
- *setup_env
- run:
name: "Copy docs dockerignore"
command: cp docs/.dockerignore .
- run:
name: "Build docs"
command: build docs
- run:
name: "Deploy docs
command:
if [ "$CIRCLE_BRANCH" == "master" ]; then
echo "Deploying docs (on master)."
docs/deploy_netlify.sh
else
echo "Skipping doc deploy (not on master)."
fi

e2e-join:
docker:
Expand Down
1 change: 1 addition & 0 deletions build_manifest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -173,6 +173,7 @@ docs:
rebuildPatterns:
- ^docs/
- ^.*.cpp$
- ^.*.hpp$
- ^.*.ts$
- ^.release-please-manifest.json$
- ^.*/noir-version.json$
Expand Down
5 changes: 1 addition & 4 deletions docs/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,4 @@ FROM 278380418400.dkr.ecr.eu-west-2.amazonaws.com/yarn-project
WORKDIR /usr/src
COPY . .
WORKDIR /usr/src/docs
RUN ls node_modules >&2 && false
RUN npm install netlify-cli -g
RUN yarn && yarn build
RUN netlify deploy
RUN yarn && yarn build
1 change: 1 addition & 0 deletions docs/Dockerfile.dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@
**/processed-docs-cache
# rebuild patterns
!**/*.cpp
!**/*.hpp
!**/*.ts
!**/.release-please-manifest.json
!**/noir-version.json
Expand Down
9 changes: 9 additions & 0 deletions docs/deploy_netlify.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#!/bin/bash
[ -n "${BUILD_SYSTEM_DEBUG:-}" ] && set -x # conditionally trace
set -eu

extract_repo docs /usr/src .
cd usr/src/docs
npm install netlify-cli -g
netlify deploy
netlify deploy --prod

0 comments on commit 3b5449d

Please sign in to comment.