forked from eclipse-che/che
-
Notifications
You must be signed in to change notification settings - Fork 0
/
devfile.yaml
61 lines (61 loc) · 1.91 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
apiVersion: 1.0.0
metadata:
name: workspace-loader
projects:
- name: che
source:
type: git
location: 'https://github.com/eclipse/che.git'
components:
- alias: theia-editor
type: cheEditor
id: eclipse/che-theia/next
- alias: exec-plugin
type: chePlugin
id: eclipse/che-machine-exec-plugin/0.0.1
- alias: typescript-plugin
type: chePlugin
id: che-incubator/typescript/1.30.2
- alias: ws-loader-dev
type: dockerimage
image: 'eclipse/che-dashboard-dev:nightly'
endpoints:
- name: dev-server
port: 3000
attributes:
path: /
protocol: http
public: "true"
mountSources: true
memoryLimit: 1Gi
commands:
- name: '[workspace loader] install dependencies'
actions:
- type: exec
component: ws-loader-dev
command: yarn
workdir: /projects/che/workspace-loader
- name: '[workspace loader] run build'
actions:
- type: exec
component: ws-loader-dev
command: yarn run build
workdir: /projects/che/workspace-loader
- name: '[workspace loader] run tests'
actions:
- type: exec
component: ws-loader-dev
command: yarn run test
workdir: /projects/che/workspace-loader
- name: '[workspace loader] start dev server'
actions:
- type: exec
component: ws-loader-dev
command: 'yarn start --disable-host-check --public=$(echo ${server.dev-server} | sed -e s/https:\\/\\/// -e s/http:\\/\\/// -e s/\\///) --host="0.0.0.0" --env.target=${CHE_API_EXTERNAL%????}'
workdir: /projects/che/workspace-loader
- name: '[workspace loader] kill dev server'
actions:
- type: exec
component: ws-loader-dev
command: 'dev_server_pid=$(pgrep -f disable-host-check) && echo "Webpack dev server processes are killed" && kill $(echo $dev_server_pid | tr "\\n" " ")'
workdir: /projects/che/workspace-loader