I'm new at DevOps, and I looking for solution to my problem.
I have a private code repository where I have a some Flask apps in one of many folders. Example of structure:
- Project -- Django Apps --- django1_dir --- django2_dir --- django3_dir -- Flask Apps --- flaskApp_dir1 (dockerfile inside) --- flaskApp_dir2 (dockerfile inside) --- flaskApp_dir3 (dockerfile inside)
And I have a configured cluster on kubernetes on AWS instance. And a private docker repo. When I want to load new version of my flaskApp to cluster I need:
- Someone modify flaskApp on repo
- I need pull repo
- Locally build a new image based on new dockerfile
- Push app to repo
- Manually push docker image with new APPVersion to AWS trough ecr
- Then kubernetes change image to new version
My question is:
how can I automate this process? I have an script to push dockerimage to AWS through ecr. It is possible to create some kind of trigger that would work in such a way:
- Someone do a commit
- Script building a new docker image and push it to AWS automaticly
I read something about it, but as I said I'm totaly new in DevOps so any hint will be awesome. Now I have configured kubernetes, that aws instances and repo for docker images. I read about git hooks, flux and some other solutions but it's quite unclear for me so I looking for best practice for that problem. I wouldn't particularly want to install huge new tools either.
So maybe any hits or keywords I could get hooked on?