Auto build and upload to AWS new docker image after commit in repo 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?
how can I automate this process? I have an script to push dockerimage to AWS through ecr.

You are on the right track. Yes, this should be an automated process from Git push or when someone merge a Pull Request.
An important aspect of this is that this &quot;automated process&quot; should be on a dedicated system - such that it is repeatable in a consistent way. Typically this is called a &quot;Continuous Integration Server&quot; or just &quot;Build Server&quot;.
Some popular choices for this kind of process:

Jenkins - old but popular
Tekton - Kubernetes native - but still in development
GitHub Actions - probably most interesting if your Git repo is on GitHub
Bitbucket Pipelines - probably most interesting if your Git repo is Bitbucket
AWS CodeBuild - limited but may be interesting if you use AWS
GitLab CI - probably most interesting if your Git repo is on GitLab

What you need to do is to configure your Git repository system (e.g. GitHub, Bitbucket, Gitlab or AWS CodeCommit) to initiate Pipelines on the Build system (a product of those listed above)