20
20
DA_SHADOW_VALUE_DEFAULT : OFF
21
21
CI_UTILS_FOLDER : " ./aws-iot-device-sdk-python-v2/utils"
22
22
CI_SAMPLES_FOLDER : " ./aws-iot-device-sdk-python-v2/samples"
23
- CI_IOT_CONTAINERS : ${{ secrets.AWS_CI_IOT_CONTAINERS }}
23
+ CI_IOT_CONTAINERS_ROLE : ${{ secrets.AWS_CI_IOT_CONTAINERS }}
24
24
CI_PUBSUB_ROLE : ${{ secrets.AWS_CI_PUBSUB_ROLE }}
25
25
CI_CUSTOM_AUTHORIZER_ROLE : ${{ secrets.AWS_CI_CUSTOM_AUTHORIZER_ROLE }}
26
26
CI_SHADOW_ROLE : ${{ secrets.AWS_CI_SHADOW_ROLE }}
@@ -34,18 +34,17 @@ jobs:
34
34
permissions :
35
35
id-token : write # This is required for requesting the JWT
36
36
steps :
37
- - name : configure AWS credentials (containers)
38
- uses : aws-actions/configure-aws-credentials@v1
39
- with :
40
- role-to-assume : ${{ env.CI_IOT_CONTAINERS }}
41
- aws-region : ${{ env.AWS_DEFAULT_REGION }}
42
37
- name : Build ${{ env.PACKAGE_NAME }}
38
+ env :
39
+ AWS_ACCESS_KEY_ID : ${{ secrets.AWS_DA_ROLE_KEY }}
40
+ AWS_SECRET_ACCESS_KEY : ${{ secrets.AWS_DA_ROLE_PRIVATE_KEY }}
43
41
# There's hackery in builder.json so that when we run on manylinux
44
42
# we build and test using every version of python that we support.
45
43
run : |
46
44
aws s3 cp s3://aws-crt-test-stuff/ci/${{ env.BUILDER_VERSION }}/linux-container-ci.sh ./linux-container-ci.sh && chmod a+x ./linux-container-ci.sh
47
45
./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-manylinux2014-x64 build -p ${{ env.PACKAGE_NAME }}
48
46
47
+
49
48
al2 :
50
49
runs-on : ubuntu-latest
51
50
permissions :
54
53
- name : configure AWS credentials (containers)
55
54
uses : aws-actions/configure-aws-credentials@v1
56
55
with :
57
- role-to-assume : ${{ env.CI_IOT_CONTAINERS }}
56
+ role-to-assume : ${{ env.CI_IOT_CONTAINERS_ROLE }}
58
57
aws-region : ${{ env.AWS_DEFAULT_REGION }}
59
58
# We can't use the `uses: docker://image` version yet, GitHub lacks authentication for actions -> packages
60
59
- name : Build ${{ env.PACKAGE_NAME }}
76
75
- name : configure AWS credentials (containers)
77
76
uses : aws-actions/configure-aws-credentials@v1
78
77
with :
79
- role-to-assume : ${{ env.CI_IOT_CONTAINERS }}
78
+ role-to-assume : ${{ env.CI_IOT_CONTAINERS_ROLE }}
80
79
aws-region : ${{ env.AWS_DEFAULT_REGION }}
81
80
# set arm arch
82
81
- name : Install qemu/docker
@@ -107,6 +106,9 @@ jobs:
107
106
- name : run PubSub sample
108
107
run : |
109
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
112
- name : run Windows Certificate Connect sample
111
113
run : |
112
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
@@ -141,6 +143,9 @@ jobs:
141
143
- name : run PubSub sample
142
144
run : |
143
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'
146
+ - name : run MQTT5 PubSub sample
147
+ 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'
144
149
- name : configure AWS credentials (Device Advisor)
145
150
uses : aws-actions/configure-aws-credentials@v1
146
151
with :
@@ -172,6 +177,9 @@ jobs:
172
177
- name : run PubSub sample
173
178
run : |
174
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'
180
+ - name : run MQTT5 PubSub sample
181
+ 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'
175
183
- name : configure AWS credentials (Device Advisor)
176
184
uses : aws-actions/configure-aws-credentials@v1
177
185
with :
@@ -213,6 +221,15 @@ jobs:
213
221
- name : run PubSub sample
214
222
run : |
215
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'
224
+ - name : run MQTT5 PubSub sample
225
+ 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'
227
+ - name : run MQTT5 PKCS11 Connect sample
228
+ run : |
229
+ mkdir -p /tmp/mqtt5/tokens
230
+ export SOFTHSM2_CONF=/tmp/softhsm2.conf
231
+ 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'
216
233
- name : run PKCS11 Connect sample
217
234
run : |
218
235
mkdir -p /tmp/tokens
@@ -227,6 +244,9 @@ jobs:
227
244
- name : run CustomAuthorizerConnect sample
228
245
run : |
229
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'
230
250
- name : configure AWS credentials (Shadow)
231
251
uses : aws-actions/configure-aws-credentials@v1
232
252
with :
0 commit comments