schemaVersion: 2.1.0
metadata:
name: java-fuse-tm4u
namespace: admin-codeready
projects:
- name: java-fuse
zip:
location: 'http:
components:
- attributes:
app.kubernetes.io/name: maven
che-theia.eclipse.org/vscode-extensions:
- 'http:
- 'http:
- 'http:
- 'http:
- 'http:
- 'http:
che-theia.eclipse.org/vscode-preferences:
java.server.launchMode: Standard
container:
args:
- sh
- '-c'
- '${PLUGIN_REMOTE_ENDPOINT_EXECUTABLE}'
endpoints:
- exposure: public
name: '8080'
protocol: http
targetPort: 8080
- attributes:
public: 'false'
exposure: internal
name: debug
protocol: http
targetPort: 5005
env:
- name: JAVA_OPTS
value: '-XX:MaxRAMPercentage=50.0 -XX:+UseParallelGC -XX:MinHeapFreeRatio=10 -XX:MaxHeapFreeRatio=20 -XX:GCTimeRatio=4 -XX:AdaptiveSizePolicyWeight=90 -Dsun.zip.disableMemoryMapping=true -Xms20m -Djava.security.egd=file:/dev/./urandom -Duser.home=/home/jboss'
- name: MAVEN_OPTS
value: $(JAVA_OPTS)
- name: PLUGIN_REMOTE_ENDPOINT_EXECUTABLE
value: /remote-endpoint/plugin-remote-endpoint
- name: THEIA_PLUGINS
value: 'local-dir:
- name: CHE_DASHBOARD_URL
value: 'https:
- name: CHE_PLUGIN_REGISTRY_URL
value: 'https:
- name: CHE_PLUGIN_REGISTRY_INTERNAL_URL
value: 'http:
image: 'registry.redhat.io/codeready-workspaces/plugin-java8-rhel8@sha256:2a62b1a38012287fab26dd625b846420e8ae1604ec6f64d3518e9783ced72e85'
memoryLimit: 768Mi
mountSources: true
sourceMapping: /projects
volumeMounts:
- name: m2
path: /home/jboss/.m2
- name: remote-endpoint
path: /remote-endpoint
- name: plugins
path: /plugins
name: maven
- name: m2
volume: {}
commands:
- exec:
commandLine: mvn clean package
component: maven
label: 1. Build
workingDir: '${PROJECTS_ROOT}/java-fuse'
id: build
- exec:
commandLine: 'mvn spring-boot:run'
component: maven
label: 2. Run
workingDir: '${PROJECTS_ROOT}/java-fuse'
id: run
- exec:
commandLine: 'mvn spring-boot:run -Dspring-boot.run.jvmArguments="-Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005"'
component: maven
label: 3. Run in debug mode
workingDir: '${PROJECTS_ROOT}/java-fuse'
id: run-in-debug-mode
- exec:
commandLine: |
echo
echo "Before you can deploy this application to an openshift cluster,"
echo "you must run 'oc login ...' in the maven terminal."
echo
component: maven
label: 4. Log into deployment cluster
workingDir: '${PROJECTS_ROOT}/java-fuse'
id: log-into-deployment-cluster
- exec:
commandLine: 'mvn fabric8:deploy -Popenshift -DskipTests'
component: maven
label: 5. Deploy to OpenShift
workingDir: '${PROJECTS_ROOT}/java-fuse'
id: deploy-to-openshift