2424 CI_JOBS_ROLE : ${{ secrets.AWS_CI_JOBS_ROLE }}
2525 CI_FLEET_PROVISIONING_ROLE : ${{ secrets.AWS_CI_FLEET_PROVISIONING_ROLE }}
2626 CI_DEVICE_ADVISOR : ${{ secrets.AWS_CI_DEVICE_ADVISOR_ROLE }}
27+ CI_MQTT5_ROLE : ${{ secrets.AWS_CI_MQTT5_ROLE }}
2728
2829jobs :
2930 linux-compat :
5152 ./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ matrix.image }} build -p ${{ env.PACKAGE_NAME }}
5253 # NOTE: we cannot run samples or DeviceAdvisor here due to container restrictions
5354
54-
55+
5556 raspberry :
5657 runs-on : ubuntu-20.04 # latest
5758 strategy :
7475 run : |
7576 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
7677 ./linux-container-ci.sh ${{ env.BUILDER_VERSION }} aws-crt-${{ matrix.image }} build -p ${{ env.PACKAGE_NAME }}
77-
78+
7879
7980 windows :
8081 runs-on : windows-latest
@@ -100,6 +101,17 @@ jobs:
100101 run : |
101102 python -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder.pyz')"
102103 python builder.pyz build -p ${{ env.PACKAGE_NAME }} --spec=downstream
104+ - name : configure AWS credentials (MQTT5)
105+ uses : aws-actions/configure-aws-credentials@v1
106+ with :
107+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
108+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
109+ - name : MQTT5 tests
110+ shell : bash
111+ run : |
112+ source utils/mqtt5_test_setup.sh s3://iot-sdk-ci-bucket-us-east1/IotUsProdMqtt5EnvironmentVariables.txt us-east-1
113+ mvn test -Dtest=Mqtt5BuilderTest -DfailIfNoTests=false
114+ source utils/mqtt5_test_setup.sh s3://iot-sdk-ci-bucket-us-east1/IotUsProdMqtt5EnvironmentVariables.txt cleanup
103115 - name : Running samples in CI setup
104116 run : |
105117 python -m pip install boto3
@@ -115,6 +127,14 @@ jobs:
115127 - name : run Windows Certificate Connect sample
116128 run : |
117129 python ./utils/run_sample_ci.py --language Java --sample_file 'samples/WindowsCertConnect' --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 --sample_main_class 'windowscertconnect.WindowsCertConnect'
130+ - name : configure AWS credentials (MQTT5)
131+ uses : aws-actions/configure-aws-credentials@v1
132+ with :
133+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
134+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
135+ - name : run MQTT5 PubSub sample
136+ run : |
137+ python ./utils/run_sample_ci.py --language Java --sample_file 'samples/Mqtt5/PubSub' --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/mqtt5/us/mqtt5_thing/cert' --sample_secret_private_key 'ci/mqtt5/us/mqtt5_thing/key' --sample_main_class 'mqtt5.pubsub.PubSub'
118138 - name : configure AWS credentials (Device Advisor)
119139 uses : aws-actions/configure-aws-credentials@v1
120140 with :
@@ -149,6 +169,16 @@ jobs:
149169 python3 -c "from urllib.request import urlretrieve; urlretrieve('${{ env.BUILDER_HOST }}/${{ env.BUILDER_SOURCE }}/${{ env.BUILDER_VERSION }}/builder.pyz?run=${{ env.RUN }}', 'builder')"
150170 chmod a+x builder
151171 ./builder build -p ${{ env.PACKAGE_NAME }} --spec=downstream
172+ - name : configure AWS credentials (MQTT5)
173+ uses : aws-actions/configure-aws-credentials@v1
174+ with :
175+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
176+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
177+ - name : MQTT5 tests
178+ run : |
179+ source utils/mqtt5_test_setup.sh s3://iot-sdk-ci-bucket-us-east1/IotUsProdMqtt5EnvironmentVariables.txt us-east-1
180+ mvn test -Dtest=Mqtt5BuilderTest -DfailIfNoTests=false
181+ source utils/mqtt5_test_setup.sh s3://iot-sdk-ci-bucket-us-east1/IotUsProdMqtt5EnvironmentVariables.txt cleanup
152182 - name : Running samples in CI setup
153183 run : |
154184 python3 -m pip install boto3
@@ -161,6 +191,14 @@ jobs:
161191 - name : run PubSub sample
162192 run : |
163193 python3 ./utils/run_sample_ci.py --language Java --sample_file 'samples/BasicPubSub' --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_main_class 'pubsub.PubSub'
194+ - name : configure AWS credentials (MQTT5)
195+ uses : aws-actions/configure-aws-credentials@v1
196+ with :
197+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
198+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
199+ - name : run MQTT5 PubSub sample
200+ run : |
201+ python3 ./utils/run_sample_ci.py --language Java --sample_file 'samples/Mqtt5/PubSub' --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/mqtt5/us/mqtt5_thing/cert' --sample_secret_private_key 'ci/mqtt5/us/mqtt5_thing/key' --sample_main_class 'mqtt5.pubsub.PubSub'
164202 - name : configure AWS credentials (Device Advisor)
165203 uses : aws-actions/configure-aws-credentials@v1
166204 with :
@@ -195,6 +233,16 @@ jobs:
195233 java -version
196234 mvn -B test -Daws.crt.debugnative=true
197235 mvn install -Dmaven.test.skip
236+ - name : configure AWS credentials (MQTT5)
237+ uses : aws-actions/configure-aws-credentials@v1
238+ with :
239+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
240+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
241+ - name : MQTT5 tests
242+ run : |
243+ source utils/mqtt5_test_setup.sh s3://iot-sdk-ci-bucket-us-east1/IotUsProdMqtt5EnvironmentVariables.txt us-east-1
244+ mvn test -Dtest=Mqtt5BuilderTest -DfailIfNoTests=false
245+ source utils/mqtt5_test_setup.sh s3://iot-sdk-ci-bucket-us-east1/IotUsProdMqtt5EnvironmentVariables.txt cleanup
198246 - name : Running samples in CI setup
199247 run : |
200248 python3 -m pip install boto3
@@ -206,6 +254,14 @@ jobs:
206254 - name : run PubSub sample
207255 run : |
208256 python3 ./utils/run_sample_ci.py --language Java --sample_file 'samples/BasicPubSub' --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_main_class 'pubsub.PubSub'
257+ - name : configure AWS credentials (MQTT5)
258+ uses : aws-actions/configure-aws-credentials@v1
259+ with :
260+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
261+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
262+ - name : run MQTT5 PubSub sample
263+ run : |
264+ python3 ./utils/run_sample_ci.py --language Java --sample_file 'samples/Mqtt5/PubSub' --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/mqtt5/us/mqtt5_thing/cert' --sample_secret_private_key 'ci/mqtt5/us/mqtt5_thing/key' --sample_main_class 'mqtt5.pubsub.PubSub'
209265 - name : configure AWS credentials (Device Advisor)
210266 uses : aws-actions/configure-aws-credentials@v1
211267 with :
@@ -331,3 +387,11 @@ jobs:
331387 Sample_UUID=$(python3 -c "import uuid; print (uuid.uuid4())")
332388 python3 ./utils/run_sample_ci.py --language Java --sample_file 'samples/Identity' --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}}'" --sample_main_class 'identity.FleetProvisioningSample'
333389 python3 utils/delete_iot_thing_ci.py --thing_name "Fleet_Thing_${Sample_UUID}" --region "us-east-1"
390+ - name : configure AWS credentials (MQTT5)
391+ uses : aws-actions/configure-aws-credentials@v1
392+ with :
393+ role-to-assume : ${{ env.CI_MQTT5_ROLE }}
394+ aws-region : ${{ env.AWS_DEFAULT_REGION }}
395+ - name : run MQTT5 PubSub sample
396+ run : |
397+ python3 ./utils/run_sample_ci.py --language Java --sample_file 'samples/Mqtt5/PubSub' --sample_region ${{ env.AWS_DEFAULT_REGION }} --sample_secret_endpoint 'ci/endpoint' --sample_secret_certificate 'ci/mqtt5/us/mqtt5_thing/cert' --sample_secret_private_key 'ci/mqtt5/us/mqtt5_thing/key' --sample_main_class 'mqtt5.pubsub.PubSub'
0 commit comments