Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Using CLI to instantiate APB services #19002

Open
siamaksade opened this issue Mar 16, 2018 · 10 comments
Open

Using CLI to instantiate APB services #19002

siamaksade opened this issue Mar 16, 2018 · 10 comments
Assignees
Labels
component/cli kind/question lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. sig/ansible-service-broker

Comments

@siamaksade
Copy link

OpenShift CLI doesn't seem to recognized services that are added to the the service catalog via the service broker. For example here is the output when looking for mysql:

# oc new-app -S mysql
Templates (oc new-app --template=<template>)
-----
mysql-persistent
  Project: openshift
  MySQL database service, with persistent storage. For more information about using this template, including OpenShift considerations, see https://github.com/sclorg/mysql-container/blob/master/5.7/root/usr/share/container-scripts/mysql/README.md.

NOTE: Scaling to more than one replica is not supported. You must have persistent volumes available in your cluster to use this template.
cakephp-mysql-persistent
  Project: openshift
  An example CakePHP application with a MySQL database. For more information about using this template, including OpenShift considerations, see https://github.com/openshift/cakephp-ex/blob/master/README.md.
dancer-mysql-persistent
  Project: openshift
  An example Dancer application with a MySQL database. For more information about using this template, including OpenShift considerations, see https://github.com/openshift/dancer-ex/blob/master/README.md.

Image streams (oc new-app --image-stream=<image-stream> [--code=<source>])
-----
mysql
  Project: openshift
  Tags:    5.6, 5.7, latest

Docker images (oc new-app --docker-image=<docker-image> [--code=<source>])
-----
mysql
  Registry: Docker Hub
  Tags:     latest

While there is also a MySQL APB in the service catalog:

screen shot 2018-03-16 at 13 00 39

How can one use oc new-app to instantiate APB services?

@jwforres
Copy link
Member

@openshift/sig-developer-experience

@jwforres
Copy link
Member

short answer is no, i'll let @bparees give a more detailed answer

@bparees
Copy link
Contributor

bparees commented Mar 20, 2018

Well the longer answer is "we could but i don't think we're going to". Making new-app search the service catalog offerings would overlap w/ whatever service catalog cli functionality is being created. (And then new-app would also have to implement the service catalog client apis to provision the things you found...again, this is better served by a first class cli for interacting with the service catalog).

That said your question seems to be two parts:

  1. How can i use the cli to instantiate service catalog offerings. My understanding is we have a cli or one is coming, assigning to @pmorie to share more.
  2. How can I use the oc new-app command to do this: You can't and we have no plans to make it possible.

@bparees bparees assigned pmorie and unassigned bparees Mar 20, 2018
@siamaksade
Copy link
Author

How many CLIs are we going to have in order to interact with OpenShift? I can count 4 (oc, ocdev, svcat and apb) so far and I need to somehow know which CLI can do what I need to do. That is very complex for even an advanced user.

As a user, I want to deploy an item that is listed in OpenShift service catalog. To me, all items there are the same but you say I should know how each one is created (template, APB, etc) and based on that know which CLI (oc, svcat, etc) should be used to deploy that item?

@sspeiche @jorgemoralespou

@thesteve0
Copy link
Contributor

thesteve0 commented Mar 22, 2018

This would be unacceptable from a Middleware perspective. By unacceptable I mean, there has been no justification given why this decision is better than a single command line as well as no discussion with other BUs about the impact and tradeoffs . Can we please revisit this decision as it is anti-developer. There should be 1 cli and 1 web console for a developer to interact with OpenShift.

@bparees
Copy link
Contributor

bparees commented Mar 22, 2018

I would not expect it to be a new cli binary, I would expect subcommands off the oc binary. (e.g. "oc service-catalog provision")

but i defer to @pmorie who owns the service catalog to actually tell us what is coming or exists.

@sspeiche
Copy link
Contributor

The plan was/is to have subcommands, whether those subcommands are plugins powered by svcat...it could work.

I do agree the flows including new-app should be service-catalog/class aware

@jorgemoralespou
Copy link

@bparees, then moving new-app into the plugins (and maybe create a set of developer plugins and include ocdev), but that would open the question on how to distribute, update plugins so that the experience of using plugins is sick.

@openshift-bot
Copy link
Contributor

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@openshift-ci-robot openshift-ci-robot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jun 20, 2018
@jorgemoralespou
Copy link

/lifecycle frozen

@openshift-ci-robot openshift-ci-robot added lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Jun 21, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component/cli kind/question lifecycle/frozen Indicates that an issue or PR should not be auto-closed due to staleness. sig/ansible-service-broker
Projects
None yet
Development

No branches or pull requests

10 participants