Dear gurus!
Web Version control is something new and I am trying to learn so don't be hard on me if I sound silly
Unfortiunately, I created a website without considering bitbucket and codedeploy first.
I have the source files in my ec2 instance /var/www/html/ where I installed git and cloned into a bitbucket repository.
I created an appspec.yml in my Bitbucket repository (master branch) similar to the instructions below:
https://aws.amazon.com//blogs/apn/announcing-atlassian-bitbucket-support-for-aws-codedeploy/
I have also created S3 bucket and seems successfully integrated into my Bitbucket. It is still empty even after the integration.
This is the confusing part for me:
Why do I need the S3 bucket for? I already have the source files in my ec2 instance so anything I approve via bitbucket should directly update the files in the web server.
If the S3 bucket serves as another gateway between changes in bitbucket and the web server then how can I transfer the files from the web server into the S3 bucket? I tried to create appspec.yml in /var/www/html and push into S3 bucket but I get the error: Failed to upload "." to <s3 bucket>: Unable to locate credentials.
Using pipeline is another story which I plan to create another thread. It keep failing my builds with error PDOException driver not found (I installed composer on both my ec2 instance and local computer).