I am a newbie in using AWS Amplify and I just published my own frontend WebApp with it developed with React. I just zipped my build folder and dropped the resulting zip file in the AWS Console. It is working fine.
However, the job is done manually and I want to automate that. I have CI&CD servers other than the ones in AWS which are working fine for my other services. So what I need is a script to automate what I just did as a I want to reuse my existing CI&CD servers. Having such a script will be really useful as I can reproduce the steps locally or in a docker container.
I know that there is a solution for that: the amplify CLI. However, commands such as amplify init
, amplify configure
and amplify pull
require a lot rights and a lot of user interaction even the AWS profile (with the secret key and access key) has already been configured.
It would be great to do something like this:
amplify deploy build.zip <APP-ARN>
or (in case of a folder)
amplify deploy /build <APP-ARN>
Essentially, I just want to automate what I did manually: uploading the (zipped) build folder to deploy my AWS Amplify app. Thus, this means no user interaction.
How to do this?