forked from che-incubator/chectl
-
Notifications
You must be signed in to change notification settings - Fork 0
/
devfile.yaml
110 lines (95 loc) · 2.57 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
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
apiVersion: 1.0.0
metadata:
name: chectl-dev
projects:
- name: chectl
source:
type: git
location: 'https://github.com/che-incubator/chectl.git'
components:
- alias: dev
type: dockerimage
image: 'quay.io/eclipse/che-theia-dev:next'
mountSources: true
memoryLimit: 1G
- id: redhat/vscode-yaml/latest
type: chePlugin
memoryLimit: 128M
- id: che-incubator/typescript/latest
type: chePlugin
memoryLimit: 1G
commands:
- name: Build
actions:
- type: exec
component: dev
command: >
yarn
workdir: /projects/chectl
- name: Test
actions:
- type: exec
component: dev
command: >
yarn test
workdir: /projects/chectl
- name: Run
actions:
- type: exec
component: dev
command: >
./run --help
workdir: /projects/chectl/bin
- name: Generate Devfile
actions:
- type: exec
component: dev
command: >
./run devfile:generate \
--name=chectl-test \
--language=typescript \
--dockerimage=eclipse/che-theia-dev:next \
--git-repo=https://github.com/che-incubator/chectl.git \
--command="yarn" > /projects/sample.devfile;
cat /projects/sample.devfile
workdir: /projects/chectl/bin
- name: Create Workspace
actions:
- type: exec
component: dev
command: >
cat /projects/sample.devfile | curl -F 'clbin=<-' https://clbin.com > /projects/clbin;
uri=$(cat /projects/clbin); ./run workspace:start -f=$uri
workdir: /projects/chectl/bin
- name: Package Binaries
actions:
- type: exec
component: dev
command: >
yarn pack-binaries
workdir: /projects/chectl
- name: Format Sources
actions:
- type: exec
component: dev
command: >
yarn format
workdir: /projects/chectl
- name: Attach remote debugger
actions:
- referenceContent: |
{
"version": "0.2.0",
"configurations": [
{
"type": "node",
"request": "attach",
"name": "Attach to Remote",
"address": "localhost",
"port": 9229,
"localRoot": "${workspaceFolder}",
"remoteRoot": "${workspaceFolder}"
}
]
}
type: vscode-launch