Skip to content

Commit

Permalink
Fix fabric8io#1409: Updated Readme for reworked 4.0 version
Browse files Browse the repository at this point in the history
  • Loading branch information
rohanKanojia committed Mar 25, 2019
1 parent 1509d90 commit 26aac72
Showing 1 changed file with 3 additions and 56 deletions.
59 changes: 3 additions & 56 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,62 +31,7 @@ To enable fabric8 maven plugin on your project just add this to the plugins sect
</plugin>
```

Now in order to use fabric8 maven plugin to build or deploy, make sure you have an OpenShift/Kubernetes cluster up and running. After making sure of that, you can simply run your app in the cluster :
```
mvn fabric8:deploy
```
After you issue this command would start building resources and then deploy them to the running cluster. Below is a snippet of the build log on running spring-boot project in samples/spring-boot directory on MiniKube :
```
[INFO] --- fabric8-maven-plugin:3.5-SNAPSHOT:build (default) @ fabric8-maven-sample-spring-boot ---
[INFO] F8: Building Docker image in Kubernetes mode
[INFO] F8: Running generator spring-boot
[INFO] F8: spring-boot: Using Docker image fabric8/java-jboss-openjdk8-jdk:1.2 as base / builder
[INFO] Copying files to /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/docker/fabric8/fabric8-maven-sample-spring-boot/snapshot-171218-140833-0299/build/maven
[INFO] Building tar: /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/docker/fabric8/fabric8-maven-sample-spring-boot/snapshot-171218-140833-0299/tmp/docker-build.tar
[INFO] F8: [fabric8/fabric8-maven-sample-spring-boot:snapshot-171218-140833-0299] "spring-boot": Created docker-build.tar in 150 milliseconds
[INFO] F8: [fabric8/fabric8-maven-sample-spring-boot:snapshot-171218-140833-0299] "spring-boot": Built image sha256:d83ec
[INFO] F8: [fabric8/fabric8-maven-sample-spring-boot:snapshot-171218-140833-0299] "spring-boot": Tag with latest
[INFO]
[INFO] --- fabric8-maven-plugin:3.5-SNAPSHOT:helm (default) @ fabric8-maven-sample-spring-boot ---
[WARNING] F8: Chart source directory /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/classes/META-INF/fabric8/k8s-template does not exist so cannot make chart fabric8-maven-sample-spring-boot. Probably you need run 'mvn fabric8:resource' before.
[INFO]
[INFO] --- maven-install-plugin:2.5.2:install (default-install) @ fabric8-maven-sample-spring-boot ---
[INFO] Installing /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT.jar to /home/rohan/.m2/repository/io/fabric8/fabric8-maven-sample-spring-boot/3.5-SNAPSHOT/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT.jar
[INFO] Installing /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/pom.xml to /home/rohan/.m2/repository/io/fabric8/fabric8-maven-sample-spring-boot/3.5-SNAPSHOT/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT.pom
[INFO] Installing /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/classes/META-INF/fabric8/openshift.yml to /home/rohan/.m2/repository/io/fabric8/fabric8-maven-sample-spring-boot/3.5-SNAPSHOT/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT-openshift.yml
[INFO] Installing /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/classes/META-INF/fabric8/openshift.json to /home/rohan/.m2/repository/io/fabric8/fabric8-maven-sample-spring-boot/3.5-SNAPSHOT/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT-openshift.json
[INFO] Installing /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/classes/META-INF/fabric8/kubernetes.yml to /home/rohan/.m2/repository/io/fabric8/fabric8-maven-sample-spring-boot/3.5-SNAPSHOT/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT-kubernetes.yml
[INFO] Installing /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/classes/META-INF/fabric8/kubernetes.json to /home/rohan/.m2/repository/io/fabric8/fabric8-maven-sample-spring-boot/3.5-SNAPSHOT/fabric8-maven-sample-spring-boot-3.5-SNAPSHOT-kubernetes.json
[INFO]
[INFO] <<< fabric8-maven-plugin:3.5-SNAPSHOT:deploy (default-cli) < install @ fabric8-maven-sample-spring-boot <<<
[INFO]
[INFO]
[INFO] --- fabric8-maven-plugin:3.5-SNAPSHOT:deploy (default-cli) @ fabric8-maven-sample-spring-boot ---
[INFO] F8: Using Kubernetes at https://192.168.99.100:8443/ in namespace default with manifest /home/rohan/work/repos/fabric8-maven-plugin/samples/spring-boot/target/classes/META-INF/fabric8/kubernetes.yml
[INFO] Using namespace: default
[INFO] Creating a Service from kubernetes.yml namespace default name fabric8-maven-sample-spring-boot
[INFO] Created Service: target/fabric8/applyJson/default/service-fabric8-maven-sample-spring-boot-1.json
[INFO] Using namespace: default
[INFO] Creating a Deployment from kubernetes.yml namespace default name fabric8-maven-sample-spring-boot
[INFO] Created Deployment: target/fabric8/applyJson/default/deployment-fabric8-maven-sample-spring-boot-1.json
[INFO] F8: HINT: Use the command `kubectl get pods -w` to watch your pods start up
[INFO] ------------------------------------------------------------------------
[INFO] BUILD SUCCESS
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 12.057 s
[INFO] Finished at: 2017-12-18T14:08:41+05:30
[INFO] Final Memory: 53M/488M
[INFO] ------------------------------------------------------------------------
```
After the build is finished, your application pod gets created:
```
~/work/repos/fabric8-maven-plugin/samples/spring-boot : $ kubectl get pods
NAME READY STATUS RESTARTS AGE
fabric8-maven-sample-spring-boot-6c865777d6-qxdmd 0/1 Running 0 5s
```

Want to get started fast? Check out the [busy Java developers guide to developing microservices on Kubernetes and Docker](https://blog.fabric8.io/a-busy-java-developers-guide-to-developing-microservices-on-kubernetes-and-docker-98b7b9816fdf).
Want to get started fast? Check out the [Blogpost for Getting Started with Fabric8 Maven Plugin](https://medium.com/@rohaan/using-fabric8-maven-plugin-to-handle-your-kubernetes-openshift-operations-b40f6d3ae63f).

The full documentation can be found in the [User Manual](http://maven.fabric8.io) [[PDF](https://fabric8io.github.io/fabric8-maven-plugin/fabric8-maven-plugin.pdf)]. It supports the following goals:

Expand Down Expand Up @@ -124,6 +69,7 @@ The full documentation can be found in the [User Manual](http://maven.fabric8.io

| FMP | OpenShift 3.11.0 | OpenShift 3.10.0 | OpenShift 3.9.0 | OpenShift 3.7.0 | OpenShift 3.6.0 |
|--------------|------------------|------------------|------------------|------------------|------------------|
| FMP 4.0.0 | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
| FMP 4.0.0-M1 | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
| FMP 4.0.0-M2 | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
| FMP 3.5.42 | :x: | :x: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: |
Expand All @@ -141,6 +87,7 @@ The full documentation can be found in the [User Manual](http://maven.fabric8.io

| FMP | Kubernetes 1.12.0 | Kubernetes 1.11.0 | Kubernetes 1.10.0 | Kubernetes 1.9.0 | Kubernetes 1.8.0 | Kubernetes 1.7.0 | Kubernetes 1.6.0 | Kubernetes 1.5.1 | Kubernetes 1.4.0 |
|--------------|-------------------|-------------------|-------------------|------------------|------------------|------------------|------------------|------------------|------------------|
| FMP 4.0.0 | :large_blue_circle: | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :x: | :x: |
| FMP 4.0.0-M2 | :large_blue_circle: | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :x: | :x: |
| FMP 4.0.0-M1 | :large_blue_circle: | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :x: | :x: |
| FMP 3.5.42 | :large_blue_circle: | :large_blue_circle: | :large_blue_circle: | :large_blue_circle: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: | :heavy_check_mark: |
Expand Down

0 comments on commit 26aac72

Please sign in to comment.