Skip to content
Permalink
Branch: master
Find file Copy path
Find file Copy path
Fetching contributors…
Cannot retrieve contributors at this time
41 lines (39 sloc) 1008 Bytes
version: 2
jobs:
build:
docker:
- image: cibuilds/hugo:0.57
working_directory: ~/hugo
steps:
- run: apk update && apk add git
- checkout
- run: hugo --gc --minify
- persist_to_workspace:
root: .
paths:
- public
deploy:
docker:
- image: circleci/node:10
environment:
IPFS_DEPLOY_CLOUDFLARE__ZONE: hacdias.com
IPFS_DEPLOY_CLOUDFLARE__RECORD: _dnslink.hacdias.com
BUILD_DIR: public
steps:
- attach_workspace:
at: /tmp/workspace
- run:
name: Pin website, post notification for PRs or update DNS on master
command: |
if [ "$CIRCLE_BRANCH" == "master" ] ; then
npx ipfs-deploy /tmp/workspace/$BUILD_DIR -C -O -u ipfs-cluster -p pinata -d cloudflare
fi
workflows:
version: 2
build-deploy:
jobs:
- build
- deploy:
context: ipfs-deploy
requires:
- build
You can’t perform that action at this time.