diff --git a/.github/workflows/healthcheck-app-existingVpc-Ubuntu-Thurs.yml b/.github/workflows/healthcheck-app-existingVpc-Ubuntu-Thurs.yml index 6bef751..a2cd6ae 100644 --- a/.github/workflows/healthcheck-app-existingVpc-Ubuntu-Thurs.yml +++ b/.github/workflows/healthcheck-app-existingVpc-Ubuntu-Thurs.yml @@ -40,4 +40,4 @@ jobs: - name: MATLAB Web App Server Reference Architecture Health Check Test Ubuntu Existing VPC Ubuntu us-east-1 region run: | cd healthcheck - python test_mwasrefarch_healthcheck_newvpc.py ${{ secrets.OIDCKeyPairNameVirginia }} ${{ secrets.lmpassword }} ${{ secrets.ipaddress }} "us-east-1" "Ubuntu" + python test_mwasrefarch_healthcheck_newvpc.py ${{ secrets.OIDCKeyPairNameVirginia }} ${{ secrets.lmpassword }} "us-east-1" "Ubuntu" diff --git a/.github/workflows/healthcheck-app-existingVpc-Win-Tue.yml b/.github/workflows/healthcheck-app-existingVpc-Win-Tue.yml index eb878c5..242b314 100644 --- a/.github/workflows/healthcheck-app-existingVpc-Win-Tue.yml +++ b/.github/workflows/healthcheck-app-existingVpc-Win-Tue.yml @@ -40,4 +40,4 @@ jobs: - name: MATLAB Web App Server Reference Architecture Health Check Test Windows Existing VPC Windows eu-west-1 region run: | cd healthcheck - python test_webappserver_refarch_existingvpc.py ${{ secrets.OIDCKeyPairNameIreland }} ${{ secrets.lmpassword }} ${{ secrets.ipaddress }} "eu-west-1" "Windows" + python test_webappserver_refarch_existingvpc.py ${{ secrets.OIDCKeyPairNameIreland }} ${{ secrets.lmpassword }} "eu-west-1" "Windows" diff --git a/.github/workflows/healthcheck-app-newVpc-Ubuntu-Mon.yml b/.github/workflows/healthcheck-app-newVpc-Ubuntu-Mon.yml index a29c096..a4e8237 100644 --- a/.github/workflows/healthcheck-app-newVpc-Ubuntu-Mon.yml +++ b/.github/workflows/healthcheck-app-newVpc-Ubuntu-Mon.yml @@ -42,4 +42,4 @@ jobs: - name: MATLAB Web App Server Reference Architecture Health Check Test Ubuntu New VPC Ubuntu us-east-1 region run: | cd healthcheck - python test_mwasrefarch_healthcheck_newvpc.py ${{ secrets.OIDCKeyPairNameVirginia }} ${{ secrets.lmpassword }} ${{ secrets.ipaddress }} "us-east-1" "Ubuntu" + python test_mwasrefarch_healthcheck_newvpc.py ${{ secrets.OIDCKeyPairNameVirginia }} ${{ secrets.lmpassword }} "us-east-1" "Ubuntu" diff --git a/.github/workflows/healthcheck-app-newVpc-Win-Wed.yml b/.github/workflows/healthcheck-app-newVpc-Win-Wed.yml index c83a679..ca6bb72 100644 --- a/.github/workflows/healthcheck-app-newVpc-Win-Wed.yml +++ b/.github/workflows/healthcheck-app-newVpc-Win-Wed.yml @@ -40,4 +40,4 @@ jobs: - name: MATLAB Web App Server Reference Architecture Health Check Test Windows New VPC Windows ap-northeast region run: | cd healthcheck - python test_mwasrefarch_healthcheck_newvpc.py ${{ secrets.OIDCKeyPairNameTokyo }} ${{ secrets.lmpassword }} ${{ secrets.ipaddress }} "ap-northeast-1" "Windows" + python test_mwasrefarch_healthcheck_newvpc.py ${{ secrets.OIDCKeyPairNameTokyo }} ${{ secrets.lmpassword }} "ap-northeast-1" "Windows" diff --git a/healthcheck/test_mwasrefarch_healthcheck_newvpc.py b/healthcheck/test_mwasrefarch_healthcheck_newvpc.py index 32a75d0..8164f8c 100644 --- a/healthcheck/test_mwasrefarch_healthcheck_newvpc.py +++ b/healthcheck/test_mwasrefarch_healthcheck_newvpc.py @@ -10,9 +10,10 @@ from datetime import date import json -def main(keypairname, password, ipAddress, location_arg, platform_arg): +def main(keypairname, password, location_arg, platform_arg): # Reference architectures in production. ref_arch_name = 'matlab-web-app-server-on-aws' + ipAddress = requests.get("https://api.ipify.org").text + "/32" parameters = [{'ParameterKey': 'KeyPairName', 'ParameterValue': keypairname}, {'ParameterKey': 'AdminIPAddress', 'ParameterValue': ipAddress}, {'ParameterKey': 'Password', 'ParameterValue': password}, @@ -62,4 +63,4 @@ def main(keypairname, password, ipAddress, location_arg, platform_arg): print("\n\n") if __name__ == '__main__': - main(sys.argv[1], sys.argv[2], sys.argv[3], sys.argv[4], sys.argv[5]) + main(sys.argv[1], sys.argv[2], sys.argv[3], sys.argv[4]) diff --git a/healthcheck/test_webappserver_refarch_existingvpc.py b/healthcheck/test_webappserver_refarch_existingvpc.py index 67cccde..cc31012 100644 --- a/healthcheck/test_webappserver_refarch_existingvpc.py +++ b/healthcheck/test_webappserver_refarch_existingvpc.py @@ -14,10 +14,11 @@ from datetime import date import sys -def main(keypairname, password, ipAddress, location_arg, platform_arg): +def main(keypairname, password, location_arg, platform_arg): # Reference architectures in production. # Deploy a stack for creating VPC with 2 subnets existing_template_url = "https://matlab-web-app-server-templates.s3.amazonaws.com/r2022a_refarch/VPCStack.yml" + ipAddress = requests.get("https://api.ipify.org").text + "/32" vpc_parameters = [{"ParameterKey": "AllowPublicIP", "ParameterValue": "Yes"}] existingstack = deploy.deploy_stack(existing_template_url, vpc_parameters, location_arg, "existingvpc") @@ -88,4 +89,4 @@ def main(keypairname, password, ipAddress, location_arg, platform_arg): if __name__ == '__main__': - main(sys.argv[1], sys.argv[2], sys.argv[3], sys.argv[4], sys.argv[5]) + main(sys.argv[1], sys.argv[2], sys.argv[3], sys.argv[4])