watchdog-proxy/.circleci/config.yml

44 строки
1.0 KiB
YAML

version: 2
jobs:
test:
docker:
- image: circleci/node:8.11.4@sha256:372dbff602066c00561c11b8a19d85665001b9c13ec82f87247e1910e9fbd63b
working_directory: ~/repo
steps:
- checkout
- restore_cache:
keys:
- v1-dependencies-{{ checksum "package.json" }}
- v1-dependencies-
- run: npm install
- save_cache:
paths:
- node_modules
key: v1-dependencies-{{ checksum "package.json" }}
- run: npm run lint
- run: npm test
- persist_to_workspace:
root: .
paths:
- ./*
deploy_dev:
docker:
- image: circleci/node:8.11.4@sha256:372dbff602066c00561c11b8a19d85665001b9c13ec82f87247e1910e9fbd63b
working_directory: ~/repo
steps:
- attach_workspace:
at: .
- run: npm run deploy:master
workflows:
version: 2
test_and_deploy:
jobs:
- test
- deploy_dev:
requires:
- test
filters:
branches:
only: master