jenkinsci / kubernetes-cd-plugin

A Jenkins plugin to deploy to Kubernetes cluster
MIT License
139 stars 70 forks source link

Is it possible to use this plugin (when it exists inside the kubernetes cluster itself?) #144

Open thatguyjono94 opened 3 years ago

thatguyjono94 commented 3 years ago

Having a docker image that runs this plugin, can I use this plugin to deploy K8 resources inside the same cluster?

So basically no need to look for a remote cluster, because the docker instance itself is already in that cluster. Is this possible?

guilhermemauro commented 3 years ago

yes. You just need to grantee the right permissions to this container and configure Kubernetes Cloud inside your jenkins configuration. look this https://medium.com/faun/ci-cd-pipeline-using-jenkins-to-deploy-on-kubernetes-cf2fd5e185b8

thatguyjono94 commented 3 years ago

@guilhermemauro do I need to specify the kubernetes URL in the cloud configuration? Will the plugin still need this configuration even if it's in the cluster itself?

guilhermemauro commented 3 years ago

Well, in my case yes. Because I`m using a DOKS. Maybe you can configure with a local IP like Docker Cloud.But I havent tried it yet.