* feat: support custom build and push commands
Signed-off-by: AhmedGrati <ahmedgrati1999@gmail.com>
* test: add functional tests of the support of custom build and push
Signed-off-by: AhmedGrati <ahmedgrati1999@gmail.com>
* docs: add docs of the support of custom build and push
Signed-off-by: AhmedGrati <ahmedgrati1999@gmail.com>
---------
Signed-off-by: AhmedGrati <ahmedgrati1999@gmail.com>
* Use go mod instead of glide
* Add `--with-kompose-annotation` flag to allow us to switch it off for tests
* Remove hostpid support (since the newest sdk does not support it)
* Create new test script and fixtures
* Remove replicationcontroller support
The PR https://github.com/kubernetes/kompose/pull/1147 introduced a
push-image parameter for the 'up' command that allows to disable
pushing the image to the registry. The PR changed the behavior of the
'convert' command that now no longer pushes the image.
This commit introduces the same parameter for the 'convert' command
and reintroduces the original behavior of pushing the image.
Updated `sirupsen`, `docker/cli`, `docker/libcompose` in `glide`,
Also changed `Sirupsen` with `sirupsen` in all kompose packages as well as in
`docker/distribution` packages
Previously we used to mention controller type as `--deployment`,
`--replication-controller` or `--daemonset` as argument.
But now,
it will be like,
ex.
```
kompose convert --controller=daemonset
```
This adds the --volumes paramater with a "generate" and "empty"
By default, "generate" will be used as a place-holder for "true".
Although not used in the code, we will eventually add "none"
This uses CLI paramater naming processes (no emptyVols as that is Go /
Kubernetes specific) and thus we use dashes.
In pkg/app/app.go, the function ValidateComposeFile() has an
unused parameter "cmd *cobra.Command".
This commit removes that parameter from the function and the
callers of the function.
This adds support for building and pushing docker containers
when you perform either `kompose convert` or `kompose up`.
Docker Compose files who have build parameters with their respective
image and build keys will automatically be both built and pushed.
- spelling mistake
- pass compose file dir instead of compose file to initBuildConfig call
- Use as default value for cli --build-branch option
- Pass current build branch to buildconfig related functions instead of opt.BuildBranch
- Fix printing buildconfig source branch in logs.