Skip to content

Instantly share code, notes, and snippets.

@blues-man
Created April 12, 2023 13:09
Show Gist options
  • Save blues-man/edc2e792c9266358c4db23f7ebef1779 to your computer and use it in GitHub Desktop.
Save blues-man/edc2e792c9266358c4db23f7ebef1779 to your computer and use it in GitHub Desktop.
schemaVersion: 2.1.0
metadata:
generateName: ${{values.artifact_id}}
icon: https://design.jboss.org/quarkus/logo/final/SVG/quarkus_icon_rgb_default.svg
tags: [ 'Java', 'Quarkus']
projectType: Quarkus
language: Java
attributes:
controller.devfile.io/storage-type: ephemeral
components:
- name: tools
container:
image: registry.redhat.io/devspaces/udi-rhel8:3.4
memoryLimit: 512Mi ## default app nowhere needs this but leaving room for expansion.
mountSources: true
volumeMounts:
- name: m2
path: /home/user/.m2
endpoints:
- name: http-quarkus
targetPort: 8080
- exposure: none
name: debug
targetPort: 5858
env:
- name: DEBUG_PORT
value: '5858'
- name: m2
volume:
size: 3Gi
commands:
- id: init-compile
exec:
component: tools
commandLine: 'mvn -Dmaven.repo.local=/home/user/.m2/repository compile'
workingDir: ${PROJECT_SOURCE}
- id: dev-run
exec:
component: tools
commandLine: 'mvn -Dmaven.repo.local=/home/user/.m2/repository quarkus:dev -Dquarkus.http.host=0.0.0.0 -Djava.util.logging.manager=org.jboss.logmanager.LogManager'
hotReloadCapable: true
group:
kind: run
isDefault: true
workingDir: ${PROJECT_SOURCE}
- id: dev-debug
exec:
component: tools
commandLine: 'mvn -Dmaven.repo.local=/home/user/.m2/repository quarkus:dev -Dquarkus.http.host=0.0.0.0 -Djava.util.logging.manager=org.jboss.logmanager.LogManager -Ddebug=${DEBUG_PORT}'
hotReloadCapable: true
group:
kind: debug
isDefault: true
workingDir: ${PROJECT_SOURCE}
- id: fix-java-version
exec:
component: tools
commandLine: 'rm -rf ${HOME}/.java/current/* && ln -s /usr/lib/jvm/java-17-openjdk/* ${HOME}/.java/current'
events:
postStart:
- fix-java-version
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment