I'm working on an interesting task and so far can't solve it.
Configuration:
- AWS code pipeline for backend which stores a value in SSM (@aws-cdk/aws-ssm)
- AWS code pipeline for frontend which builds a pipeline which builds project for React App
- React App git repository with buildspec.yml which consumed by pipeline from #2 and deployed to S3
Question: Any good way to read a value stored in #1 and inject it to React App?
I can easily read it in #2, but this project is for pipeline creation only. So, I think it requires some special step in pipeline for frontend to update React App during a build or deploy step.
Any brilliant ideas? :) I do not have any so far.
Thank you!
buildspec.yml code:
version: 0.2
phases:
install:
runtime-versions:
nodejs: 12
commands:
- yarn install
build:
commands:
- yarn build
artifacts:
base-directory: ./build
files:
- '**/*'
cache:
paths:
- './node_modules/**/*'