Until now, the 'images' workflow was separated into two different jobs,
one for just building the images in e.g. pull requests and the other
one for building and pushing the images e.g. after a merge to the 'main'
branch, which resulted in code repetitions. Also, both jobs used
different approaches, one (build) using a 'matrix strategy' based on
the file name of the Dockerfile, the other one (build and push) having a
seperate build and push step for each Dockerfile.
With this change, both jobs have been unified into a single "build and
optionally push" job to remove the repetitions, which now also shares
the same approach - a matrix strategy based on the file names of the
Dockerfiles.
The package naming now follows a clear schema based on the file name of
the Dockerfile. 'Dockerfile' will result in a 'helmfile' package,
'Dockerfile.ubuntu' will result in a 'helmfile-ubuntu' package and so
on. In order to keep the 'helmfile-debian-stable-slim' image package
name, the 'Dockerfile.debian' had to be renamed to
'Dockerfile.debian-stable-slim' accordingly.
Furthermore, the evaluation of the condition whether a push is intended
(or not) has been moved directly to the 'push' flag of the
'docker/build-push-action'.
Signed-off-by: Patrick Hobusch <patrick.hobusch@gmail.com>