Obsidian Generator: Backend

Parent POM for JBoss projects. Provides default project build configuration.

License

License

GroupId

GroupId

io.fabric8
ArtifactId

ArtifactId

generator-backend
Last Version

Last Version

1.0.101
Release Date

Release Date

Type

Type

war
Description

Description

Obsidian Generator: Backend
Parent POM for JBoss projects. Provides default project build configuration.
Project Organization

Project Organization

Red Hat
Source Code Management

Source Code Management

http://github.com/fabric8io/generator-backend

Download generator-backend

How to add to project

<!-- https://jarcasting.com/artifacts/io.fabric8/generator-backend/ -->
<dependency>
    <groupId>io.fabric8</groupId>
    <artifactId>generator-backend</artifactId>
    <version>1.0.101</version>
    <type>war</type>
</dependency>
// https://jarcasting.com/artifacts/io.fabric8/generator-backend/
implementation 'io.fabric8:generator-backend:1.0.101'
// https://jarcasting.com/artifacts/io.fabric8/generator-backend/
implementation ("io.fabric8:generator-backend:1.0.101")
'io.fabric8:generator-backend:war:1.0.101'
<dependency org="io.fabric8" name="generator-backend" rev="1.0.101">
  <artifact name="generator-backend" type="war" />
</dependency>
@Grapes(
@Grab(group='io.fabric8', module='generator-backend', version='1.0.101')
)
libraryDependencies += "io.fabric8" % "generator-backend" % "1.0.101"
[io.fabric8/generator-backend "1.0.101"]

Dependencies

compile (7)

Group / Artifact Type Version
io.fabric8 : kubernetes-api jar
org.wildfly.swarm : cdi jar
org.wildfly.swarm : jaxrs-cdi jar
org.wildfly.swarm : jaxrs-jsonp jar
org.wildfly.swarm : jaxrs-multipart jar
org.jboss.forge : forge-service-core jar 1.0.0.CR3
org.jboss.arquillian.extension : arquillian-rest-client-impl-jersey jar 1.0.0.Alpha3

provided (2)

Group / Artifact Type Version
javax : javaee-api jar 7.0
io.fabric8.forge : fabric8-generator jar 1.0.76

test (2)

Group / Artifact Type Version
org.wildfly.swarm : arquillian jar
org.jboss.arquillian.junit : arquillian-junit-container jar

Project Modules

There are no modules declared in this project.

Fabric8 Generator Backend

This is the back end service for the fabric8-generator.

The backend runs within a WildFly Swarm container and is called from the fabric8-ui front end to create new apps or import projects from github.

Environment variables

To run this project you need to point the back end at KeyCloak and an OpenShift cluster.

You can point the back end at the production KeyCloak and OpenShift cluster via:

export OPENSHIFT_API_URL=https://api.starter-us-east-2.openshift.com:443
export KEYCLOAK_SAAS_URL=https://sso.openshift.io/

Then call ./run.sh or ./debug.sh as below.

Using Minishift

If you are running fabric8 locally on MiniShift then your local variables will be something like:

export OPENSHIFT_API_URL=https://`minishift ip`:8443
export KEYCLOAK_SAAS_URL="http://`oc get route keycloak --template={{.spec.host}} -n fabric8`/"
export WIT_URL="http://`oc get route wit --template={{.spec.host}} -n fabric8`/"
export AUTH_URL="http://`oc get route auth --template={{.spec.host}} -n fabric8`/"

Using Minikube

export OPENSHIFT_API_URL=https://`minikube ip`:8443
export KEYCLOAK_SAAS_URL="http://`kubectl get ingress -n fabric8 --template='{{ (index .spec.rules 0).host}}' f8tenant`/"
export WIT_URL="http://`kubectl get ingress -n fabric8 --template='{{ (index .spec.rules 0).host}}' wit`/"
export AUTH_URL="http://`kubectl get ingress -n fabric8 --template='{{ (index .spec.rules 0).host}}' auth`/"

Build this project:

$ ./build.sh

Debugging this project

$ ./debug.sh

Running this project

$ ./run.sh

Using fabric8-ui with a local build of fabric8-generator

To run fabric8-ui against a locally running/debugging Fabric8 Generator in the fabric8-ui project type:

cd fabric8-ui
source environments/openshift-prod-cluster.sh
export FABRIC8_FORGE_API_URL=http://localhost:8080
npm start

then open http://localhost:3000/ to use the local build of fabric8-ui which should now use your local Fabric8 Generator.

Using a local build of the fabric8-generator addon

When working on the fabric8-generator codebase you need to work with SNAPSHOT version of fabric8-generator add-ion.

In your swarm backend generator-backend use the generator-shapshot profile.

  • build fabric8-generator snapshot:
mvn install
  • build sawrm backend genrator-backend with the profile:
mvn install -Pgenerator-snapshot
  • run
./run.sh

or ./debug.sh will automatically reload the new version of your addon! This greatly speeds up development time!

Using a local fabric8-generator with MiniShift

Once you are running a local fabric8-generator you should be able to query it like this:

curl http://localhost:8080/forge/version
{"backendVersion":"1.0.0-SNAPSHOT","forgeVersion":"3.6.1.Final"}

How if you are running fabric8 locally on MiniShift you just need to point the console at your locally running process.

So first find out your local IP address via something like

ifconfig |grep inet | grep 192

Its probably something like 192.168.X.Y

First test you've got the right IP via:

curl http://192.168.X.Y:8080/forge/version

If that works then try edit the fabric8 ConfigMap to point at your local forge:

oc project fabric8
oc edit cm fabric8

Then

  • disable (delete or comment out)the annotation expose.service-key.config.fabric8.io/forge in metadata.annotations
  • edit the forge.api.url in the data: section to be http://192.168.X.Y:8080

You can test your edit worked by doing something like:

$ oc export cm | grep "forge.api.url:"
    forge.api.url: http://192.168.X.Y:8080

After you save change to the ConfigMap it should cause a redeploy of the fabric8 console. Then if you refresh your console you should be able to use the forge wizard against your locally running Forge process.

io.fabric8

fabric8

open source development platform for kubernetes

Versions

Version
1.0.101
1.0.99
1.0.98
1.0.96
1.0.95
1.0.84
1.0.83
1.0.82
1.0.81
1.0.80
1.0.79
1.0.78
1.0.77
1.0.76
1.0.75
1.0.74
1.0.73
1.0.72
1.0.71
1.0.70
1.0.69
1.0.68
1.0.67
1.0.66
1.0.65
1.0.64
1.0.63
1.0.62
1.0.61
1.0.60
1.0.59
1.0.58
1.0.57
1.0.56
1.0.55
1.0.54
1.0.53
1.0.52
1.0.51
1.0.50
1.0.49
1.0.48
1.0.47
1.0.46
1.0.45
1.0.41
1.0.40
1.0.38
1.0.37
1.0.36
1.0.35
1.0.34
1.0.33
1.0.32
1.0.31
1.0.30
1.0.29
1.0.28
1.0.27
1.0.26
1.0.25
1.0.24
1.0.23
1.0.22
1.0.21
1.0.20
1.0.19
1.0.18
1.0.17
1.0.15
1.0.14
1.0.13
1.0.12
1.0.11
1.0.10
1.0.9
1.0.8
1.0.7
1.0.6
1.0.5
1.0.4
1.0.3
1.0.2