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

Keycloak uses DeploymentConfig rather than Deployment #28

Open
dimitraz opened this issue Jan 26, 2018 · 15 comments
Open

Keycloak uses DeploymentConfig rather than Deployment #28

dimitraz opened this issue Jan 26, 2018 · 15 comments

Comments

@dimitraz
Copy link

It looks like a recent changed has caused Keycloak to use a deployment config rather than a deployment which means we can't deploy it to kubernetes. This also has a knock-on effect on the CLI as we expect a deployment
Should we be supporting both Kubernetes and Openshift using a deployment rather?

@matzew @maleck13 @pb82

@maleck13
Copy link
Contributor

Spoke with @dimitraz about this and asked her to open the issue

@pb82
Copy link
Contributor

pb82 commented Jan 26, 2018

It looks like the keycloak-apb always used a Openshift DeploymentConfig vs a Kubernetes Deployment. Initial commit:

openshift_v1_deployment_config:

Support for the kubernetes style deployment seems to be still in Tech Preview: https://docs.openshift.org/latest/dev_guide/deployments/kubernetes_deployments.html

I'd be in favor of supporting both, Openshift and Kubernetes but it looks like at this point we can't use Deployment or is Tech Preview ok?

@maleck13
Copy link
Contributor

maleck13 commented Jan 26, 2018

Your right about keycloak actually. I think in actual fact what has changed in fh-sync-server perhaps? But aside from that:

I Hadn't noticed it was only tech preview for openshift. But I still think we should support both. Perhaps the broker could pass in the platform target, if it doesn't already and we can choose which template to use based on this.
Do you know if it tells you which runtime target as a param to the apb?
We will have to do some work in the CLI to deal with it being either a DeploymentConfig or a Deployment. But we have no chance of getting community support from the wider k8s community if we only support OSCP

@maleck13
Copy link
Contributor

ping @david-martin

@pb82
Copy link
Contributor

pb82 commented Jan 26, 2018

@maleck13 The ASB does support Kubernetes and i've asked the guys if there's a way for a playbook to know if it's running in Openshift or Kubernetes. Looks like there is: https://github.com/ansibleplaybookbundle/postgresql-apb/blob/master/playbooks/provision.yaml#L5

The broker changes the value of this variable to either "openshift" or "kubernetes". So in Ansible we could possibly query '{{ cluster }}' and depending on the value use openshift_v1_deployment_config or run a Kubernetes specific template.

@david-martin
Copy link
Contributor

Reaching out to see when it could be out of tech preview openshift/openshift-docs#5254 (comment).

Having the APB support both dc's and deployments is a bit of overhead. Not just in the APB, but the mobile cli too.
My thinking is go with deployments for now so it works in kubernetes, and seems to work ok in openshift too.
When we're closer to locking down a version of openshift that's our baseline for our APBs, we can revisit.

@maleck13
Copy link
Contributor

@pb82 Does this make sense to you? Which would you prefer as an apb developer, that we just use deployments or that we maintain 2 sets of objects and switch based on the target. My choice would be to just use Deployments and get some kind of answer to when it is expected out of tech preview.

@matzew
Copy link
Member

matzew commented Jan 26, 2018

My thinking is go with deployments for now so it works in kubernetes, and seems to work ok in openshift too.

I like that thinking. to be able address the full k8s user space

@matzew
Copy link
Member

matzew commented Jan 26, 2018

@dimitraz loop me in for a potential PR - happy to review/test ;-)

@maleck13
Copy link
Contributor

@matzew I think perhaps issues created in the service teams backlogs would be a better approach here as it need to be reflected in all services. However @dimitraz if you wanted to look into it don't let me stop you :)

@pb82
Copy link
Contributor

pb82 commented Jan 26, 2018

@maleck13 Yes i think we should just use Deployments if that's ok. Maintaining two different configurations would make apb development very difficult.

@maleck13
Copy link
Contributor

Ok guys so it sounds like we are in agreement on using deployments for our services. Will you guys update the service backlogs with an issue to do this?
@pb82 @matzew @david-martin

@matzew
Copy link
Member

matzew commented Jan 29, 2018 via email

@dimitraz
Copy link
Author

@maleck13
Copy link
Contributor

@matzew yes thats what I meant ? Maybe some confusion :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants