Skip to content
This repository was archived by the owner on Jan 14, 2025. It is now read-only.

Commit a926c43

Browse files
alexcasalbonimikedeck
authored andcommitted
Improved invokeUrl injection (w/o placeholder)
1 parent 7e7a846 commit a926c43

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

WebApplication/4_RESTfulAPIs/backend-api.yaml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -378,7 +378,7 @@ Resources:
378378
bucket = properties['Bucket']
379379
config_object = s3.Object(bucket, 'js/config.js').get()
380380
config_data = config_object["Body"].read()
381-
config_data = config_data.replace("Base URL of your API including the stage", properties["InvokeUrl"])
381+
config_data = config_data.replace("invokeUrl: ''", "invokeUrl: '%s'" % properties["InvokeUrl"])
382382
config = s3.Object(bucket,'js/config.js')
383383
config.put(Body=config_data)
384384
return cfnresponse.SUCCESS, None
@@ -421,4 +421,4 @@ Outputs:
421421
- !Ref AWS::Region
422422
- ".amazonaws.com/prod"
423423
Export:
424-
Name: WildRydesApiUrl
424+
Name: WildRydesApiUrl

0 commit comments

Comments
 (0)