Closed soltysh closed 7 years ago
this is going to require a huge number of flags to be useful (even worse than new-build/new-app today).... can you give me a use case for why new-build/new-app are not the right answer?
Simplicity of usage, I want to create BC and only that, without any other accompanying resources. I don't want to create BC by hand because I don't remember the yaml structure and I'm lazy to do it everytime I want to create a BC. With reasonable flags I should be able to create a sketch of a BC with oc create buildconfig
and pick from there to do more when I need.
With reasonable flags I should be able to create a sketch of a BC with oc create buildconfig and pick from there to do more when I need.
i disagree that this is possible with anything less than a half dozen flags.
for a minimal buildconfig you need:
1) a source repo 2) a builder image a) is it an imagestream or a dockerimage reference? 3) a destination for the output a) is it an imagestream or a dockerimage reference? 4) a build strategy
i'll create the card, but i'm worried we're just creating another version of new-app where every person who goes to use it is going to come back and say "can you add a flag so i can specify X on my buildconfig? i don't want to edit it afterwards".
trello'd https://trello.com/c/vqI6QomG
From what you've pointed out is just 4 flags where source repo is the required param. By definition oc create
should be simple, that's the whole point, if you need more use oc new-app/new-build
:)
From what you've pointed out is just 4 flags where source repo is the required param.
they're all required parameters. just the source repo is not sufficient for us to do anything.
And it's 6 flags because for flag (2) and (3) we either need:
--from-image-stream/--from-docker-image --to-image-stream/--to-docker-image
or --from-image --as-imagestream/--as-dockerimage
or some other disambiguation as to whether the user is pointing us to a docker image, or an imagestream, for both the --to and --from fields. Otherwise you get into the searching/matching/guessing madness that new-app currently does.
Unless you're proposing that when creating a buildconfig you can only reference imagestreams (or only reference dockerimages).
Only docker images, if you care about IS you'd use oc new-app
.
Only docker images, if you care about IS you'd use oc new-app.
that seems silly. I don't want to introduce a command that creates buildconfigs that follow a structure we'd never recommend. imagestreams are the right tool for the job. Buildconfigs that don't use imagestreams are painful:
1) you can't imagechangetrigger them 2) you almost certainly need to add docker credential secrets because you're not going to be able to push the output anywhere
The most likely combination is:
from a docker image to an imagestream
Our
oc create
supports several resources, but no buildConfigs, as of yet. The only CLI for creating BC isoc new-app
oroc new-build
which aside from the BC creates a few additional resources.