From 1ad5c151e71ba1161571c47e88eb63b58760c68f Mon Sep 17 00:00:00 2001 From: abidknashtech Date: Thu, 30 Nov 2023 20:51:55 +0530 Subject: [PATCH] temp fix CORS url --- .../com/nashtech/car/cart/config/WebConfig.java | 2 +- deployment/gcpresources/terraform/key.json | 13 ------------- .../java/com.nashtech.order/config/WebConfig.java | 2 +- projects-changes-deploy.txt | 4 +++- 4 files changed, 5 insertions(+), 16 deletions(-) diff --git a/cart-service/src/main/java/com/nashtech/car/cart/config/WebConfig.java b/cart-service/src/main/java/com/nashtech/car/cart/config/WebConfig.java index a220d45f..11c02de2 100644 --- a/cart-service/src/main/java/com/nashtech/car/cart/config/WebConfig.java +++ b/cart-service/src/main/java/com/nashtech/car/cart/config/WebConfig.java @@ -12,7 +12,7 @@ public class WebConfig implements WebMvcConfigurer { @Override public void addCorsMappings(CorsRegistry registry) { registry.addMapping("/**") - .allowedOrigins("http://localhost:4200/") // Allow requests from Angular app + .allowedOrigins("http://34.23.248.115:4200/") // Allow requests from Angular app .allowedMethods("GET", "POST", "PUT", "DELETE") .maxAge(3600); } diff --git a/deployment/gcpresources/terraform/key.json b/deployment/gcpresources/terraform/key.json index 1d0414d3..e69de29b 100644 --- a/deployment/gcpresources/terraform/key.json +++ b/deployment/gcpresources/terraform/key.json @@ -1,13 +0,0 @@ -{ - "type": "service_account", - "project_id": "datamesh-2", - "private_key_id": "585b6eed36a592043e8f444bebdcf14d914e78f4", - "private_key": "-----BEGIN PRIVATE KEY-----\nMIIEvAIBADANBgkqhkiG9w0BAQEFAASCBKYwggSiAgEAAoIBAQCp1K2e9DkBRSaD\nfZKYba1ZHfVNQ3drUlf1E+aeoc4r8tb4ip8ZcZRnhK0Rip4rpPcW1a1Gq2uZyddi\nzjF59ylJTCFAmuLz2AN3aLSLmBc5npZdewp6LdOcSl2SN8z5OHe2DUmDn0BIVbVD\nGHfQy12p3V+bRWHP8+TVpo/YsqL3YLMcvbG+Nn5o2juUlb3MssDF3YPC/GIirBWz\n0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8/WpxCh7uu3HeZRSV1Jtar7fuGFcU+eUOh+boFTXk\nvcnrfv+F0WF1+90gOGTEuFUAHiMxCyAPaU6RuurHF1jd0nlkzDXZOmJfx4UFFEEO\nsPtjnLapNS1bjVaclqc1LliLbStV0VaIdSmRIP8CgYBHZWE8Eh8C3F2P7s5F3SzR\nHszPsr3UfNAFIg0EKfW+TG6NFGZLKLU5CT7Od2a9G2KrHGaAsjCZ9jaZXKP0HsvO\nyCJ4DXB4NlPxfZQYAHA4WhVaXcTfQvRT64myCLxvqtRhtcBhPh3o/4OpSrY0Ehge\nMXn0dawXjLrAJsBsUgersQ==\n-----END PRIVATE KEY-----\n", - "client_email": "java-car-demo@datamesh-2.iam.gserviceaccount.com", - "client_id": "116961686900137160069", - "auth_uri": "https://accounts.google.com/o/oauth2/auth", - "token_uri": "https://oauth2.googleapis.com/token", - "auth_provider_x509_cert_url": "https://www.googleapis.com/oauth2/v1/certs", - "client_x509_cert_url": "https://www.googleapis.com/robot/v1/metadata/x509/java-car-demo%40datamesh-2.iam.gserviceaccount.com", - "universe_domain": "googleapis.com" -} diff --git a/order-service/src/main/java/com.nashtech.order/config/WebConfig.java b/order-service/src/main/java/com.nashtech.order/config/WebConfig.java index f9cf3b42..5a2c6ada 100644 --- a/order-service/src/main/java/com.nashtech.order/config/WebConfig.java +++ b/order-service/src/main/java/com.nashtech.order/config/WebConfig.java @@ -12,7 +12,7 @@ public class WebConfig implements WebMvcConfigurer { @Override public void addCorsMappings(CorsRegistry registry) { registry.addMapping("/**") - .allowedOrigins("http://localhost:4200/") // Allow requests from Angular app + .allowedOrigins("http://35.196.63.112:4200/") // Allow requests from Angular app .allowedMethods("GET", "POST", "PUT", "DELETE") .maxAge(3600); } diff --git a/projects-changes-deploy.txt b/projects-changes-deploy.txt index 76710988..2312b174 100644 --- a/projects-changes-deploy.txt +++ b/projects-changes-deploy.txt @@ -1 +1,3 @@ -admin-service \ No newline at end of file +admin-service +cart-service +order-service \ No newline at end of file