Skip to content

Commit 1dde6ff

Browse files
author
alrex
authored
chore: migrate to circleci (open-telemetry#828)
1 parent 675334b commit 1dde6ff

File tree

2 files changed

+203
-117
lines changed

2 files changed

+203
-117
lines changed

.circleci/config.yml

Lines changed: 91 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,24 @@
11
version: 2.1
22

33
executors:
4-
python38:
4+
py38:
55
docker:
66
- image: circleci/python:3.8
7+
py37:
8+
docker:
9+
- image: circleci/python:3.7
10+
py36:
11+
docker:
12+
- image: circleci/python:3.6
13+
py35:
14+
docker:
15+
- image: circleci/python:3.5
16+
py34:
17+
docker:
18+
- image: circleci/python:3.4
19+
pypy3:
20+
docker:
21+
- image: pypy:3
722

823
commands:
924
setup_tox:
@@ -31,27 +46,100 @@ commands:
3146
paths:
3247
- ".tox"
3348

49+
run_tox_scenario:
50+
description: "Run scripts/run-tox-scenario with setup, caching and persistence"
51+
parameters:
52+
pattern:
53+
type: string
54+
steps:
55+
- checkout
56+
- setup_tox
57+
- restore_tox_cache
58+
- run:
59+
name: "Run scripts/run-tox-scenario"
60+
command: tox -f '<< parameters.pattern >>'
61+
- save_tox_cache
62+
3463
jobs:
3564
docs:
36-
executor: python38
65+
executor: py38
3766
steps:
3867
- checkout
3968
- setup_tox
4069
- restore_tox_cache
4170
- run: tox -e docs
4271
- save_tox_cache
4372

73+
docker-tests:
74+
machine:
75+
image: ubuntu-1604:201903-01
76+
steps:
77+
- checkout
78+
- run:
79+
name: "Get pyenv list"
80+
command: pyenv versions
81+
- run:
82+
name: "Set Python Version"
83+
command: pyenv global 3.7.0
84+
- run:
85+
name: "Update pip"
86+
command: pip install -U pip
87+
- setup_tox
88+
- restore_tox_cache
89+
- run: tox -e docker-tests
90+
- save_tox_cache
91+
4492
lint:
45-
executor: python38
93+
executor: py38
4694
steps:
4795
- checkout
4896
- setup_tox
4997
- restore_tox_cache
5098
- run: tox -e lint
5199
- save_tox_cache
52100

101+
build-py34:
102+
parameters:
103+
package:
104+
type: string
105+
default: "core"
106+
executor: py34
107+
steps:
108+
- checkout
109+
- run:
110+
name: "Install tox"
111+
command: sudo pip install -U tox virtualenv tox-factor
112+
- restore_tox_cache
113+
- run:
114+
name: "Run scripts/run-tox-scenario"
115+
command: tox -f py34-<< parameters.package >>
116+
- save_tox_cache
117+
118+
build:
119+
parameters:
120+
version:
121+
type: string
122+
default: "py38"
123+
package:
124+
type: string
125+
default: "core"
126+
executor: << parameters.version >>
127+
steps:
128+
- run_tox_scenario:
129+
pattern: << parameters.version >>-<< parameters.package >>
130+
53131
workflows:
54132
main:
55133
jobs:
134+
- build:
135+
matrix:
136+
parameters:
137+
version: ["py38", "py37", "py36", "py35", "pypy3"]
138+
package: ["core", "exporter", "instrumentation"]
139+
- build-py34:
140+
matrix:
141+
parameters:
142+
package: ["core", "exporter", "instrumentation"]
56143
- docs
57144
- lint
145+
- docker-tests

0 commit comments

Comments
 (0)