MCPcopy Index your code
hub / github.com/eclipse-jkube/jkube

github.com/eclipse-jkube/jkube @v1.19.0

Chat with this repo
repository ↗ · DeepWiki ↗ · release v1.19.0 ↗ · + Follow
7,764 symbols 35,586 edges 1,064 files 553 documented · 7%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Eclipse JKube

Cloud-Native Java Applications without a hassle

E2E Tests Maintainability Rating Coverage Gitter Twitter

Open in Gitpod

Eclipse JKube

Contents

Introduction

Eclipse JKube is a collection of plugins and libraries that are used for building container images using Docker, JIB or S2I build strategies. Eclipse JKube generates and deploys Kubernetes/OpenShift manifests at compile time too.

It brings your Java applications on to Kubernetes and OpenShift by leveraging the tasks required to make your application cloud-native.

Eclipse JKube also provides a set of tools such as watch, debug, log, etc. to improve your developer experience. This project contains various building blocks for the Kubernetes Java developer toolbox.

Kubernetes Maven Plugin

  • Maven Central
  • Documentation
  • Add to project: xml <plugin> <groupId>org.eclipse.jkube</groupId> <artifactId>kubernetes-maven-plugin</artifactId> <version>${jkube.version}</version> </plugin>
  • Run the JKube commands, for instance: shell mvn package k8s:build k8s:push k8s:resource k8s:apply
  • :tv: Watch 2-minute demo on YouTube:

KubernetesMavenPluginDemo

Kubernetes Gradle Plugin

  • Maven Central
  • Documentation
  • Add to project: groovy plugins { id "org.eclipse.jkube.kubernetes" version "${jKubeVersion}" }
  • Run the JKube commands, for instance: shell gradle build k8sBuild k8sPush k8sResource k8sApply
  • :tv: Watch 2-minute demo on YouTube:

KubernetesGradlePluginDemo

OpenShift Gradle Plugin

  • Maven Central
  • Documentation
  • Add to project: groovy plugins { id "org.eclipse.jkube.openshift" version "${jKubeVersion}" }
  • Run the JKube commands, for instance: shell gradle build ocBuild ocResource ocApply
  • :tv: Watch 2-minute demo on YouTube:

OpenShiftGradlePluginDemo

OpenShift Maven Plugin

  • Maven Central
  • Documentation
  • Add to project: xml <plugin> <groupId>org.eclipse.jkube</groupId> <artifactId>openshift-maven-plugin</artifactId> <version>${jkube.version}</version> </plugin>
  • Run the JKube commands, for instance: shell mvn package oc:build oc:resource oc:apply
  • :tv: Watch 2-minute demo on YouTube:

OpenShiftMavenPluginDemo

Getting started

You can take a look at our quickstarts in quickstarts directory that contain sample maven and gradle projects using the latest version of jkube plugin.

Hello World using Eclipse JKube

  • Clone repository and move to quickstart helloworld sample, build project and run JKube goals:

```shell script

1. Clone repository

$ git clone git@github.com:eclipse/jkube.git

2. Move to Hello World Quickstart folder

$ cd jkube/quickstarts/maven/hello-world

3. Configure your local environment to re-use the Docker daemon inside the Minikube instance.

~ jkube/quickstarts/maven/hello-world : $ eval $(minikube -p minikube docker-env)

4. Build Project and run JKube goals

$ mvn clean install \ k8s:build # Build Docker Image \ k8s:resource # Generate Kubernetes Manifests \ k8s:apply # Apply generated Kubernetes Manifests onto Kubernetes


- Check created pod logs:

```shell script
# Using Kubectl
$ kubectl get pods
NAME                          READY   STATUS    RESTARTS   AGE
helloworld-664bf5fdff-2bmrt   1/1     Running   0          9s
$ kubectl get svc
helloworld   NodePort    10.110.92.145   <none>        8080:32353/TCP   58m
kubernetes   ClusterIP   10.96.0.1       <none>        443/TCP          7h
$ curl `minikube ip`:32353/hello
Hello World

Troubleshooting

If you experience problems using minikube that pod's status shows 'ImagePullBackOff' and not 'Running' you must share the minikube's docker daemon environment with your shell with:

```shell script $ eval $(minikube -p minikube docker-env)


You can remove this from your shell again with:

```shell script
$ eval $(minikube docker-env -u)

If you don't want to type the command for every new terminal you open, you can add the command to your .bash_profile on mac or .zshrc.

Rebranding Notice :loudspeaker:

This project is not an effort from scratch. It was earlier called Fabric8 Maven Plugin. It is just refactored and rebranded version of the project targeted towards Java developers who are working on top of Kubernetes. For more information about history, please see REBRANDING.md

Extension points exported contracts — how you extend this code

Core symbols most depended-on inside this repo

Shape

Method 6,481
Class 1,163
Enum 69
Interface 51

Languages

Java100%

Modules by API surface

gradle-plugin/kubernetes/src/main/java/org/eclipse/jkube/gradle/plugin/KubernetesExtension.java153 symbols
gradle-plugin/openshift/src/test/java/org/eclipse/jkube/gradle/plugin/TestOpenShiftExtension.java73 symbols
gradle-plugin/kubernetes/src/test/java/org/eclipse/jkube/gradle/plugin/TestKubernetesExtension.java67 symbols
jkube-kit/jkube-kit-spring-boot/src/test/java/org/eclipse/jkube/springboot/enricher/AbstractSpringBootHealthCheckEnricherTestSupport.java66 symbols
jkube-kit/config/service/src/main/java/org/eclipse/jkube/kit/config/service/ApplyService.java63 symbols
jkube-kit/common/src/test/java/org/eclipse/jkube/kit/common/util/SpringBootConfigurationTest.java59 symbols
jkube-kit/common/src/main/java/org/eclipse/jkube/kit/common/util/KubernetesHelper.java52 symbols
jkube-kit/jkube-kit-vertx/src/test/java/org/eclipse/jkube/vertx/enricher/VertxHealthCheckEnricherTest.java51 symbols
jkube-kit/config/service/src/test/java/org/eclipse/jkube/kit/config/service/openshift/OpenshiftBuildServiceIntegrationTest.java45 symbols
jkube-kit/enricher/api/src/test/java/org/eclipse/jkube/kit/enricher/api/BaseEnricherTest.java44 symbols
jkube-kit/generator/api/src/test/java/org/eclipse/jkube/generator/api/support/BaseGeneratorTest.java41 symbols
jkube-kit/enricher/generic/src/main/java/org/eclipse/jkube/enricher/generic/DefaultServiceEnricher.java41 symbols

Datastores touched

(mysql)Database · 1 repos
sample_dbDatabase · 1 repos
productionDatabase · 1 repos

For agents

$ claude mcp add jkube \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact

Ask about this repo answers extend the page