Skip to content

Commit 2bdffd0

Browse files
authored
Merge pull request #886 from moreati/prepare-0.3.1
Prepare 0.3.1
2 parents 74e7bc2 + b19223c commit 2bdffd0

File tree

173 files changed

+1156
-566
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

173 files changed

+1156
-566
lines changed

.ci/README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,6 @@ for doing `setup.py install` while pulling a Docker container, for example.
2828

2929
### Environment Variables
3030

31-
* `VER`: Ansible version the `_install` script should install. Default changes
32-
over time.
3331
* `TARGET_COUNT`: number of targets for `debops_` run. Defaults to 2.
3432
* `DISTRO`: the `mitogen_` tests need a target Docker container distro. This
3533
name comes from the Docker Hub `mitogen` user, i.e. `mitogen/$DISTRO-test`

.ci/ansible_install.py

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -3,25 +3,9 @@
33
import ci_lib
44

55
batches = [
6-
[
7-
# Must be installed separately, as PyNACL indirect requirement causes
8-
# newer version to be installed if done in a single pip run.
9-
# Separately install ansible based on version passed in from azure-pipelines.yml or .travis.yml
10-
'pip install "pycparser<2.19" "idna<2.7"',
11-
'pip install '
12-
'-r tests/requirements.txt '
13-
'-r tests/ansible/requirements.txt',
14-
# encoding is required for installing ansible 2.10 with pip2, otherwise we get a UnicodeDecode error
15-
'LC_CTYPE=en_US.UTF-8 LANG=en_US.UTF-8 pip install "ansible-base<2.10.14" "ansible=={}"'.format(ci_lib.ANSIBLE_VERSION)
16-
],
176
[
187
'aws ecr-public get-login-password | docker login --username AWS --password-stdin public.ecr.aws',
198
]
209
]
2110

22-
batches[-1].extend([
23-
'docker pull %s' % (ci_lib.image_for_distro(distro),)
24-
for distro in ci_lib.DISTROS
25-
])
26-
2711
ci_lib.run_batches(batches)

.ci/ansible_tests.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ def pause_if_interactive():
7070
with ci_lib.Fold('ansible'):
7171
playbook = os.environ.get('PLAYBOOK', 'all.yml')
7272
try:
73-
run('./run_ansible_playbook.py %s -i "%s" -vvv %s',
73+
run('./run_ansible_playbook.py %s -i "%s" %s',
7474
playbook, HOSTS_DIR, ' '.join(sys.argv[1:]))
7575
except:
7676
pause_if_interactive()

.ci/azure-pipelines-steps.yml

Lines changed: 9 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,20 +5,18 @@ parameters:
55
sign: false
66

77
steps:
8-
- script: "PYTHONVERSION=$(python.version) .ci/prep_azure.py"
9-
displayName: "Run prep_azure.py"
8+
- task: UsePythonVersion@0
9+
displayName: Install python
10+
inputs:
11+
versionSpec: '$(python.version)'
12+
condition: ne(variables['python.version'], '')
1013

11-
- script: |
12-
echo "##vso[task.prependpath]/tmp/venv/bin"
14+
- script: python -mpip install tox
15+
displayName: Install tooling
1316

14-
displayName: activate venv
15-
16-
- script: .ci/$(MODE)_install.py
17-
displayName: "Run $(MODE)_install.py"
17+
- script: python -mtox -e "$(tox.env)"
18+
displayName: "Run tests"
1819
env:
1920
AWS_ACCESS_KEY_ID: $(AWS_ACCESS_KEY_ID)
2021
AWS_SECRET_ACCESS_KEY: $(AWS_SECRET_ACCESS_KEY)
2122
AWS_DEFAULT_REGION: $(AWS_DEFAULT_REGION)
22-
23-
- script: .ci/$(MODE)_tests.py
24-
displayName: "Run $(MODE)_tests.py"

.ci/azure-pipelines.yml

Lines changed: 183 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -3,75 +3,192 @@
33
# Add steps that analyze code, save the dist with the build record, publish to a PyPI-compatible index, and more:
44
# https://docs.microsoft.com/azure/devops/pipelines/languages/python
55

6-
jobs:
6+
# User defined variables are also injected as environment variables
7+
# https://docs.microsoft.com/en-us/azure/devops/pipelines/process/variables#environment-variables
8+
#variables:
9+
#ANSIBLE_VERBOSITY: 3
710

8-
- job: Mac
11+
jobs:
12+
- job: Mac1015
913
# vanilla Ansible is really slow
1014
timeoutInMinutes: 120
1115
steps:
1216
- template: azure-pipelines-steps.yml
1317
pool:
18+
# https://github.com/actions/virtual-environments/blob/main/images/macos/macos-10.15-Readme.md
1419
vmImage: macOS-10.15
1520
strategy:
1621
matrix:
17-
Mito27_27:
22+
Mito_27:
1823
python.version: '2.7'
19-
MODE: mitogen
24+
tox.env: py27-mode_mitogen
25+
Mito_36:
26+
python.version: '3.6'
27+
tox.env: py36-mode_mitogen
28+
Mito_39:
29+
python.version: '3.9'
30+
tox.env: py39-mode_mitogen
31+
2032
# TODO: test python3, python3 tests are broken
21-
Ans210_27:
33+
Loc_27_210:
2234
python.version: '2.7'
23-
MODE: localhost_ansible
24-
VER: 2.10.0
35+
tox.env: py27-mode_localhost-ansible2.10
36+
Loc_27_3:
37+
python.version: '2.7'
38+
tox.env: py27-mode_localhost-ansible3
39+
Loc_27_4:
40+
python.version: '2.7'
41+
tox.env: py27-mode_localhost-ansible4
2542

2643
# NOTE: this hangs when ran in Ubuntu 18.04
27-
Vanilla_210_27:
44+
Van_27_210:
45+
python.version: '2.7'
46+
tox.env: py27-mode_localhost-ansible2.10
47+
STRATEGY: linear
48+
ANSIBLE_SKIP_TAGS: resource_intensive
49+
Van_27_3:
2850
python.version: '2.7'
29-
MODE: localhost_ansible
30-
VER: 2.10.0
51+
tox.env: py27-mode_localhost-ansible3
52+
STRATEGY: linear
53+
ANSIBLE_SKIP_TAGS: resource_intensive
54+
Van_27_4:
55+
python.version: '2.7'
56+
tox.env: py27-mode_localhost-ansible4
3157
STRATEGY: linear
3258
ANSIBLE_SKIP_TAGS: resource_intensive
3359

60+
- job: Mac11
61+
# vanilla Ansible is really slow
62+
timeoutInMinutes: 120
63+
steps:
64+
- template: azure-pipelines-steps.yml
65+
pool:
66+
# https://github.com/actions/virtual-environments/blob/main/images/macos/
67+
vmImage: macOS-11
68+
strategy:
69+
matrix:
70+
Mito_27:
71+
tox.env: py27-mode_mitogen
72+
Mito_37:
73+
python.version: '3.7'
74+
tox.env: py37-mode_mitogen
75+
Mito_39:
76+
python.version: '3.9'
77+
tox.env: py39-mode_mitogen
78+
79+
# TODO: test python3, python3 tests are broken
80+
Loc_27_210:
81+
tox.env: py27-mode_localhost-ansible2.10
82+
Loc_27_3:
83+
tox.env: py27-mode_localhost-ansible3
84+
Loc_27_4:
85+
tox.env: py27-mode_localhost-ansible4
86+
87+
# NOTE: this hangs when ran in Ubuntu 18.04
88+
Van_27_210:
89+
tox.env: py27-mode_localhost-ansible2.10
90+
STRATEGY: linear
91+
ANSIBLE_SKIP_TAGS: resource_intensive
92+
Van_27_3:
93+
tox.env: py27-mode_localhost-ansible3
94+
STRATEGY: linear
95+
ANSIBLE_SKIP_TAGS: resource_intensive
96+
Van_27_4:
97+
tox.env: py27-mode_localhost-ansible4
98+
STRATEGY: linear
99+
ANSIBLE_SKIP_TAGS: resource_intensive
34100

35101
- job: Linux
36102
pool:
103+
# https://github.com/actions/virtual-environments/blob/main/images/linux/Ubuntu1804-README.md
37104
vmImage: "Ubuntu 18.04"
38105
steps:
39106
- template: azure-pipelines-steps.yml
40107
strategy:
41108
matrix:
42-
#
43-
# Confirmed working
44-
#
45-
Mito27Debian_27:
109+
Mito_27_centos6:
46110
python.version: '2.7'
47-
MODE: mitogen
48-
DISTRO: debian9
49-
50-
#MitoPy27CentOS6_26:
51-
#python.version: '2.7'
52-
#MODE: mitogen
53-
#DISTRO: centos6
111+
tox.env: py27-mode_mitogen-distro_centos6
112+
Mito_27_centos7:
113+
python.version: '2.7'
114+
tox.env: py27-mode_mitogen-distro_centos7
115+
Mito_27_centos8:
116+
python.version: '2.7'
117+
tox.env: py27-mode_mitogen-distro_centos8
118+
Mito_27_debian9:
119+
python.version: '2.7'
120+
tox.env: py27-mode_mitogen-distro_debian9
121+
Mito_27_debian10:
122+
python.version: '2.7'
123+
tox.env: py27-mode_mitogen-distro_debian10
124+
Mito_27_debian11:
125+
python.version: '2.7'
126+
tox.env: py27-mode_mitogen-distro_debian11
127+
Mito_27_ubuntu1604:
128+
python.version: '2.7'
129+
tox.env: py27-mode_mitogen-distro_ubuntu1604
130+
Mito_27_ubuntu1804:
131+
python.version: '2.7'
132+
tox.env: py27-mode_mitogen-distro_ubuntu1804
133+
Mito_27_ubuntu2004:
134+
python.version: '2.7'
135+
tox.env: py27-mode_mitogen-distro_ubuntu2004
54136

55-
Mito36CentOS6_26:
137+
Mito_36_centos6:
56138
python.version: '3.6'
57-
MODE: mitogen
58-
DISTRO: centos6
59-
60-
Mito37Debian_27:
61-
python.version: '3.7'
62-
MODE: mitogen
63-
DISTRO: debian9
139+
tox.env: py36-mode_mitogen-distro_centos6
140+
Mito_36_centos7:
141+
python.version: '3.6'
142+
tox.env: py36-mode_mitogen-distro_centos7
143+
Mito_36_centos8:
144+
python.version: '3.6'
145+
tox.env: py36-mode_mitogen-distro_centos8
146+
Mito_36_debian9:
147+
python.version: '3.6'
148+
tox.env: py36-mode_mitogen-distro_debian9
149+
Mito_36_debian10:
150+
python.version: '3.6'
151+
tox.env: py36-mode_mitogen-distro_debian10
152+
Mito_36_debian11:
153+
python.version: '3.6'
154+
tox.env: py36-mode_mitogen-distro_debian11
155+
Mito_36_ubuntu1604:
156+
python.version: '3.6'
157+
tox.env: py36-mode_mitogen-distro_ubuntu1604
158+
Mito_36_ubuntu1804:
159+
python.version: '3.6'
160+
tox.env: py36-mode_mitogen-distro_ubuntu1804
161+
Mito_36_ubuntu2004:
162+
python.version: '3.6'
163+
tox.env: py36-mode_mitogen-distro_ubuntu2004
64164

65-
Mito39Debian_27:
165+
Mito_39_centos6:
66166
python.version: '3.9'
67-
MODE: mitogen
68-
DISTRO: debian9
69-
VER: 2.10.0
70-
71-
#Py26CentOS7:
72-
#python.version: '2.7'
73-
#MODE: mitogen
74-
#DISTRO: centos6
167+
tox.env: py39-mode_mitogen-distro_centos6
168+
Mito_39_centos7:
169+
python.version: '3.9'
170+
tox.env: py39-mode_mitogen-distro_centos7
171+
Mito_39_centos8:
172+
python.version: '3.9'
173+
tox.env: py39-mode_mitogen-distro_centos8
174+
Mito_39_debian9:
175+
python.version: '3.9'
176+
tox.env: py39-mode_mitogen-distro_debian9
177+
Mito_39_debian10:
178+
python.version: '3.9'
179+
tox.env: py39-mode_mitogen-distro_debian10
180+
Mito_39_debian11:
181+
python.version: '3.9'
182+
tox.env: py39-mode_mitogen-distro_debian11
183+
Mito_39_ubuntu1604:
184+
python.version: '3.9'
185+
tox.env: py39-mode_mitogen-distro_ubuntu1604
186+
Mito_39_ubuntu1804:
187+
python.version: '3.9'
188+
tox.env: py39-mode_mitogen-distro_ubuntu1804
189+
Mito_39_ubuntu2004:
190+
python.version: '3.9'
191+
tox.env: py39-mode_mitogen-distro_ubuntu2004
75192

76193
#DebOps_2460_27_27:
77194
#python.version: '2.7'
@@ -110,17 +227,35 @@ jobs:
110227
#DISTROS: debian
111228
#STRATEGY: linear
112229

113-
Ansible_210_27:
230+
Ans_27_210:
114231
python.version: '2.7'
115-
MODE: ansible
116-
VER: 2.10.0
232+
tox.env: py27-mode_ansible-ansible2.10
233+
Ans_27_3:
234+
python.version: '2.7'
235+
tox.env: py27-mode_ansible-ansible3
236+
Ans_27_4:
237+
python.version: '2.7'
238+
tox.env: py27-mode_ansible-ansible4
117239

118-
Ansible_210_35:
119-
python.version: '3.5'
120-
MODE: ansible
121-
VER: 2.10.0
240+
Ans_36_210:
241+
python.version: '3.6'
242+
tox.env: py36-mode_ansible-ansible2.10
243+
Ans_36_3:
244+
python.version: '3.6'
245+
tox.env: py36-mode_ansible-ansible3
246+
Ans_36_4:
247+
python.version: '3.6'
248+
tox.env: py36-mode_ansible-ansible4
122249

123-
Ansible_210_39:
250+
Ans_39_210:
251+
python.version: '3.9'
252+
tox.env: py39-mode_ansible-ansible2.10
253+
Ans_39_3:
254+
python.version: '3.9'
255+
tox.env: py39-mode_ansible-ansible3
256+
Ans_39_4:
257+
python.version: '3.9'
258+
tox.env: py39-mode_ansible-ansible4
259+
Ans_39_5:
124260
python.version: '3.9'
125-
MODE: ansible
126-
VER: 2.10.0
261+
tox.env: py39-mode_ansible-ansible5

0 commit comments

Comments
 (0)