Nice work! I suggest creating your own image that contains aws-cli, get rid of variables on top and put it into GitLab as secrets to make the pipeline more simple and readable.
Thank you for your comments and suggestions. You are absolutely right!
We thought that showing the various variables and the use of awscli in the code might help to better understand the process.