This repository has been archived by the owner on Aug 16, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 114
/
devfile.yaml
76 lines (76 loc) · 1.98 KB
/
devfile.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
---
apiVersion: 1.0.0
metadata:
generateName: java-web-spring-
projects:
-
name: java-web-spring
source:
type: git
location: "https://github.com/che-samples/java-spring-petclinic"
commitId: 4953f87917b449a404a7f1f4e2457836b9eafbbc
components:
-
type: chePlugin
id: redhat/java/latest
preferences:
java.server.launchMode: Standard
-
type: dockerimage
alias: tools
image: quay.io/eclipse/che-java11-maven:ce0526f
env:
- name: MAVEN_CONFIG
value: ""
- 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/user"
- name: MAVEN_OPTS
value: $(JAVA_OPTS)
memoryLimit: 1000Mi
endpoints:
- name: '8080-tcp'
port: 8080
- name: 'debug'
port: 5005
attributes:
public: 'false'
mountSources: true
volumes:
- name: m2
containerPath: /home/user/.m2
commands:
-
name: maven build
actions:
-
type: exec
component: tools
command: "mvn clean install"
workdir: ${CHE_PROJECTS_ROOT}/java-web-spring
- name: run webapp
actions:
-
type: exec
component: tools
command: |
java -jar -Xdebug -Xrunjdwp:transport=dt_socket,server=y,suspend=n,address=5005 \
target/*.jar
workdir: ${CHE_PROJECTS_ROOT}/java-web-spring
- name: Debug remote java application
actions:
- type: vscode-launch
referenceContent: |
{
"version": "0.2.0",
"configurations": [
{
"type": "java",
"name": "Debug (Attach) - Remote",
"request": "attach",
"hostName": "localhost",
"port": 5005
}]
}