|
1 | 1 | version: 2 |
2 | 2 |
|
3 | 3 | jobs: |
4 | | - build_and_test_python36: |
| 4 | + circleci_is_disabled_job: |
5 | 5 | docker: |
6 | | - - image: circleci/python:3.6 |
7 | | - - image: rabbitmq:3 |
8 | | - - image: mongo:3.4 |
9 | | - |
10 | | - working_directory: ~/repo |
11 | | - |
12 | | - environment: |
13 | | - VIRTUALENV_DIR: "~/virtualenv" |
14 | | - # Don't install various StackStorm dependencies which are already |
15 | | - # installed by CI again in the various check scripts |
16 | | - ST2_INSTALL_DEPS: "0" |
17 | | - |
| 6 | + - image: cimg/base:stable |
18 | 7 | steps: |
19 | | - - checkout |
20 | | - - restore_cache: |
21 | | - key: v1-dependency-cache-py36-{{ checksum "requirements.txt" }} |
22 | | - - run: |
23 | | - name: Download dependencies |
24 | | - # NOTE: We don't want to use default "-e" option because this means |
25 | | - # step will fail immediately on one of the commands failures and we |
26 | | - # can't intercept the error and cause non-fatal exit in case pack |
27 | | - # doesn't declare support for Python 3 |
28 | | - shell: /bin/bash |
29 | | - # TODO: delete last 3 lines when StackStorm-Exchange/ci#101 is merged |
30 | | - command: | |
31 | | - git clone -b master git://github.com/stackstorm-exchange/ci.git ~/ci |
32 | | - ~/ci/.circle/dependencies ; ~/ci/.circle/exit_on_py3_checks $? |
33 | | - echo "Setting up custom pack testing environment with tests/setup_testing_env.sh" |
34 | | - source ~/virtualenv/bin/activate |
35 | | - tests/setup_testing_env.sh |
36 | 8 | - run: |
37 | | - name: Run tests (Python 3.6) |
38 | | - # NOTE: We don't want to use default "-e" option because this means |
39 | | - # step will fail immediately on one of the commands failures and we |
40 | | - # can't intercept the error and cause non-fatal exit in case pack |
41 | | - # doesn't declare support for Python 3 |
42 | 9 | shell: /bin/bash |
43 | | - # eventlet monkey_patch as early as possible (has to be in activate as nosetests gets reinstalled during test phase) |
44 | | - command: | |
45 | | - echo "grep -q monkey_patch ~/virtualenv/bin/nosetests || sed -i -e '/^import re$/i from st2common.util.monkey_patch import monkey_patch\nmonkey_patch()\n' ~/virtualenv/bin/nosetests" >> ~/virtualenv/bin/activate |
46 | | - echo "grep -q pyopenssl\\.inject ~/virtualenv/bin/nosetests || sed -i -e '/^import re$/i from urllib3.contrib import pyopenssl\npyopenssl.inject_into_urllib3()\n' ~/virtualenv/bin/nosetests" >> ~/virtualenv/bin/activate |
47 | | - ~/ci/.circle/test ; ~/ci/.circle/exit_on_py3_checks $? |
48 | | - - save_cache: |
49 | | - key: v1-dependency-cache-py36-{{ checksum "requirements.txt" }} |
50 | | - paths: |
51 | | - - ~/.cache/pip |
52 | | - - ~/.apt-cache |
53 | | - # NOTE: We use virtualenv files from Python 3.6 step in "deploy" job so we |
54 | | - # only persist paths from this job |
55 | | - - persist_to_workspace: |
56 | | - root: / |
57 | | - paths: |
58 | | - - home/circleci/ci |
59 | | - - home/circleci/virtualenv |
60 | | - - tmp/st2 |
61 | | - - home/circleci/repo |
62 | | - - home/circleci/.gitconfig |
63 | | - |
64 | | - |
65 | | - deploy: |
66 | | - docker: |
67 | | - - image: circleci/python:3.6 |
68 | | - |
69 | | - working_directory: ~/repo |
70 | | - |
71 | | - environment: |
72 | | - VIRTUALENV_DIR: "~/virtualenv" |
73 | | - |
74 | | - steps: |
75 | | - - checkout |
76 | | - - restore_cache: |
77 | | - key: v1-dependency-cache-py36-{{ checksum "requirements.txt" }} |
78 | | - - attach_workspace: |
79 | | - at: / |
80 | | - - run: |
81 | | - name: Install dependencies |
82 | | - command: | |
83 | | - sudo apt-get update |
84 | | - sudo apt -y install gmic optipng |
85 | | - ~/ci/.circle/install_gh |
86 | | - - run: |
87 | | - # NOTE: We try to retry the script up to 5 times if it fails. The command could fail due |
88 | | - # to the race (e.g. we try to push changes to index, but index has been updated by some |
89 | | - # other pack in the mean time) |
90 | | - name: Update exchange.stackstorm.org |
91 | | - command: ~/ci/.circle/retry_on_failure.sh ~/ci/.circle/deployment |
| 10 | + command: echo CircleCI disabled on StackStorm-Exchange |
92 | 11 |
|
93 | 12 | workflows: |
94 | 13 | version: 2 |
95 | | - # Workflow which runs on each push |
96 | | - build_test_deploy_on_push: |
97 | | - jobs: |
98 | | - - build_and_test_python36 |
99 | | - - deploy: |
100 | | - requires: |
101 | | - - build_and_test_python36 |
102 | | - filters: |
103 | | - branches: |
104 | | - only: master |
105 | | - build_test_weekly: |
| 14 | + circleci_is_disabled: |
106 | 15 | jobs: |
107 | | - - build_and_test_python36 |
108 | | - # Workflow which runs nightly - note we don't perform deploy job on nightly |
109 | | - # build |
110 | | - triggers: |
111 | | - # Run nightly build for the pack |
112 | | - - schedule: |
113 | | - # NOTE: We run it at 1 am UTC on every Saturday |
114 | | - cron: "0 1 * * 6" |
115 | | - filters: |
116 | | - branches: |
117 | | - only: |
118 | | - - master |
| 16 | + - circleci_is_disabled_job |
0 commit comments