19
19
DA_SHADOW_VALUE_SET : ON
20
20
DA_SHADOW_VALUE_DEFAULT : OFF
21
21
CI_UTILS_FOLDER : " ./aws-iot-device-sdk-python-v2/utils"
22
+ CI_SAMPLES_CFG_FOLDER : " ./aws-iot-device-sdk-python-v2/.github/workflows"
22
23
CI_SAMPLES_FOLDER : " ./aws-iot-device-sdk-python-v2/samples"
23
24
CI_IOT_CONTAINERS_ROLE : ${{ secrets.AWS_CI_IOT_CONTAINERS }}
24
25
CI_PUBSUB_ROLE : ${{ secrets.AWS_CI_PUBSUB_ROLE }}
27
28
CI_JOBS_ROLE : ${{ secrets.AWS_CI_JOBS_ROLE }}
28
29
CI_FLEET_PROVISIONING_ROLE : ${{ secrets.AWS_CI_FLEET_PROVISIONING_ROLE }}
29
30
CI_DEVICE_ADVISOR : ${{ secrets.AWS_CI_DEVICE_ADVISOR_ROLE }}
31
+ CI_MQTT5_ROLE : ${{ secrets.AWS_CI_MQTT5_ROLE }}
30
32
31
33
jobs :
32
34
all-python-versions :
@@ -105,13 +107,18 @@ jobs:
105
107
aws-region : ${{ env.AWS_DEFAULT_REGION }}
106
108
- name : run PubSub sample
107
109
run : |
108
- python ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
109
- - name : run MQTT5 PubSub sample
110
- run : |
111
- python ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/mqtt5_pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
110
+ python ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_pubsub_cfg.json
112
111
- name : run Windows Certificate Connect sample
113
112
run : |
114
- python ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/windows_cert_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key' --sample_run_certutil true
113
+ python ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_windows_cert_connect_cfg.json
114
+ - name : configure AWS credentials (MQTT5 samples)
115
+ uses : aws-actions/configure-aws-credentials@v1
116
+ with :
117
+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
118
+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
119
+ - name : run MQTT5 PubSub sample
120
+ run : |
121
+ python ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_pubsub_cfg.json
115
122
- name : configure AWS credentials (Device Advisor)
116
123
uses : aws-actions/configure-aws-credentials@v1
117
124
with :
@@ -142,10 +149,15 @@ jobs:
142
149
aws-region : ${{ env.AWS_DEFAULT_REGION }}
143
150
- name : run PubSub sample
144
151
run : |
145
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
152
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_pubsub_cfg.json
153
+ - name : configure AWS credentials (MQTT5 samples)
154
+ uses : aws-actions/configure-aws-credentials@v1
155
+ with :
156
+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
157
+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
146
158
- name : run MQTT5 PubSub sample
147
159
run : |
148
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/mqtt5_pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
160
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_pubsub_cfg.json
149
161
- name : configure AWS credentials (Device Advisor)
150
162
uses : aws-actions/configure-aws-credentials@v1
151
163
with :
@@ -176,10 +188,15 @@ jobs:
176
188
aws-region : ${{ env.AWS_DEFAULT_REGION }}
177
189
- name : run PubSub sample
178
190
run : |
179
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
191
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_pubsub_cfg.json
192
+ - name : configure AWS credentials (MQTT5 samples)
193
+ uses : aws-actions/configure-aws-credentials@v1
194
+ with :
195
+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
196
+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
180
197
- name : run MQTT5 PubSub sample
181
198
run : |
182
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/mqtt5_pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
199
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_pubsub_cfg.json
183
200
- name : configure AWS credentials (Device Advisor)
184
201
uses : aws-actions/configure-aws-credentials@v1
185
202
with :
@@ -214,58 +231,63 @@ jobs:
214
231
aws-region : ${{ env.AWS_DEFAULT_REGION }}
215
232
- name : run Basic Connect sample
216
233
run : |
217
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/basic_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
234
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_basic_connect_cfg.json
218
235
- name : run Websocket Connect sample
219
236
run : |
220
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/websocket_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_arguments '--signing_region us-east-1'
237
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_websocket_connect_cfg.json
221
238
- name : run PubSub sample
222
239
run : |
223
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
240
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_pubsub_cfg.json
241
+ - name : run PKCS11 Connect sample
242
+ run : |
243
+ mkdir -p /tmp/tokens
244
+ export SOFTHSM2_CONF=/tmp/softhsm2.conf
245
+ echo "directories.tokendir = /tmp/tokens" > /tmp/softhsm2.conf
246
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_pkcs11_connect_cfg.json
247
+ - name : configure AWS credentials (MQTT5 samples)
248
+ uses : aws-actions/configure-aws-credentials@v1
249
+ with :
250
+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
251
+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
224
252
- name : run MQTT5 PubSub sample
225
253
run : |
226
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/mqtt5_pubsub.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/key'
254
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_pubsub_cfg.json
227
255
- name : run MQTT5 PKCS11 Connect sample
228
256
run : |
229
257
mkdir -p /tmp/mqtt5/tokens
230
258
export SOFTHSM2_CONF=/tmp/softhsm2.conf
231
259
echo "directories.tokendir = /tmp/mqtt5/tokens" > /tmp/softhsm2.conf
232
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/mqtt5_pkcs11_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/keyp8' --sample_run_softhsm 'true' --sample_arguments '--pkcs11_lib /usr/lib/softhsm/libsofthsm2.so --pin 0000 --token_label my-token --key_label my-key'
233
- - name : run PKCS11 Connect sample
260
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_pkcs11_connect_cfg.json
261
+ - name : run MQTT5 CustomAuthorizerConnect sample
234
262
run : |
235
- mkdir -p /tmp/tokens
236
- export SOFTHSM2_CONF=/tmp/softhsm2.conf
237
- echo "directories.tokendir = /tmp/tokens" > /tmp/softhsm2.conf
238
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/pkcs11_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/PubSub/cert' --sample_secret_private_key 'ci/PubSub/keyp8' --sample_run_softhsm 'true' --sample_arguments '--pkcs11_lib /usr/lib/softhsm/libsofthsm2.so --pin 0000 --token_label my-token --key_label my-key'
263
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_custom_authorizer_cfg.json
264
+ - name : run MQTT5 CustomAuthorizerConnect sample (websockets)
265
+ run : |
266
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_mqtt5_custom_authorizer_websockets_cfg.json
239
267
- name : configure AWS credentials (Custom Authorizer)
240
268
uses : aws-actions/configure-aws-credentials@v1
241
269
with :
242
270
role-to-assume : ${{ env.CI_CUSTOM_AUTHORIZER_ROLE }}
243
271
aws-region : ${{ env.AWS_DEFAULT_REGION }}
244
272
- name : run CustomAuthorizerConnect sample
245
273
run : |
246
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/custom_authorizer_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_custom_authorizer_name 'ci/CustomAuthorizer/name' --sample_secret_custom_authorizer_password 'ci/CustomAuthorizer/password'
247
- - name : run MQTT5 CustomAuthorizerConnect sample
248
- run : |
249
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/mqtt5_custom_authorizer_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_custom_authorizer_name 'ci/CustomAuthorizer/name' --sample_secret_custom_authorizer_password 'ci/CustomAuthorizer/password'
250
- - name : run MQTT5 CustomAuthorizerConnect sample (websockets)
251
- run : |
252
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file "${{ env.CI_SAMPLES_FOLDER }}/mqtt5_custom_authorizer_connect.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_custom_authorizer_name 'ci/CustomAuthorizer/name' --sample_secret_custom_authorizer_password 'ci/CustomAuthorizer/password' --sample_arguments '--use_websockets true'
274
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_custom_authorizer_connect_cfg.json
253
275
- name : configure AWS credentials (Shadow)
254
276
uses : aws-actions/configure-aws-credentials@v1
255
277
with :
256
278
role-to-assume : ${{ env.CI_SHADOW_ROLE }}
257
279
aws-region : ${{ env.AWS_DEFAULT_REGION }}
258
280
- name : run Shadow sample
259
281
run : |
260
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/shadow.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/Shadow/cert' --sample_secret_private_key 'ci/Shadow/key' --sample_arguments '--thing_name CI_Shadow_Thing'
282
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_shadow_cfg.json
261
283
- name : configure AWS credentials (Jobs)
262
284
uses : aws-actions/configure-aws-credentials@v1
263
285
with :
264
286
role-to-assume : ${{ env.CI_JOBS_ROLE }}
265
287
aws-region : ${{ env.AWS_DEFAULT_REGION }}
266
288
- name : run Jobs sample
267
289
run : |
268
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/jobs.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/Jobs/cert' --sample_secret_private_key 'ci/Jobs/key' --sample_arguments '--thing_name CI_Jobs_Thing'
290
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_jobs_cfg.json
269
291
- name : configure AWS credentials (Fleet provisioning)
270
292
uses : aws-actions/configure-aws-credentials@v1
271
293
with :
@@ -275,7 +297,7 @@ jobs:
275
297
run : |
276
298
echo "Generating UUID for IoT thing"
277
299
Sample_UUID=$(python3 -c "import uuid; print (uuid.uuid4())")
278
- python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --language Python --sample_file " ${{ env.CI_SAMPLES_FOLDER }}/fleetprovisioning.py" --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/FleetProvisioning/cert' --sample_secret_private_key 'ci/FleetProvisioning/key' --sample_arguments "--template_name CI_FleetProvisioning_Template --template_parameters {\"SerialNumber\":\"${ Sample_UUID}\"}"
300
+ python3 ${{ env.CI_UTILS_FOLDER }}/run_sample_ci.py --file ${{ env.CI_SAMPLES_CFG_FOLDER }}/ci_run_fleet_provisioning_cfg.json --input_uuid ${Sample_UUID}
279
301
python3 ${{ env.CI_UTILS_FOLDER }}/delete_iot_thing_ci.py --thing_name "Fleet_Thing_${Sample_UUID}" --region "us-east-1"
280
302
281
303
# check that docs can still build
0 commit comments