Skip to content

Instantly share code, notes, and snippets.

@antpb
Created July 19, 2020 14:20
Show Gist options
  • Save antpb/0b8bc8f29e089913b42bcf1ad4209c01 to your computer and use it in GitHub Desktop.
Save antpb/0b8bc8f29e089913b42bcf1ad4209c01 to your computer and use it in GitHub Desktop.
Hubs Circle Configuration
version: 2
jobs:
build:
docker:
- image: circleci/node:10-browsers
working_directory: ~/repo
steps:
- checkout
- restore_cache:
keys:
- v1-dependencies-{{ checksum "package-lock.json" }}
- v1-dependencies-
- run: npm ci
- save_cache:
paths:
- node_modules
key: v1-dependencies-{{ checksum "package-lock.json" }}
- run: npm test
- store_artifacts:
path: dist
deploy:
docker:
- image: circleci/node:10-browsers
working_directory: ~/repo
steps:
- checkout
- restore_cache:
keys:
- v1-dependencies-{{ checksum "package-lock.json" }}
- v1-dependencies-
- run: npm ci
- save_cache:
paths:
- node_modules
key: v1-dependencies-{{ checksum "package-lock.json" }}
- run: npm run login-bp
- run: npm run deploy
- store_artifacts:
path: dist
workflows:
version: 2
build-and-deploy:
jobs:
- build
- deploy:
requires:
- build
filters:
branches:
only: production
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment