-
Notifications
You must be signed in to change notification settings - Fork 0
/
diploi-template.yaml
96 lines (84 loc) · 1.92 KB
/
diploi-template.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
diploiTemplateVersion: V1.0
name: diploi-tiny
description: Minimal app
defaultName: Tiny App
stages:
- name: Development
identifier: development
- name: Staging
identifier: staging
- name: Production
identifier: production
contexts:
- name: app
identifier: app
parameterGroups:
environmentVariables:
- identifier: SERVER_TITLE
defaultValue: My Tiny Server
type: string
contexts: label=app
repositories:
- name: app
identifier: app
hosts:
- name: App
identifier: app
urlFormat: 'www-[label].[default-domain]'
ssh:
- usernameFormat: '[label]'
contexts: label=app
stages:
- development
- usernameFormat: '[label]-[index]'
contexts: label=app
stages:
- production
logs:
- identifier: app-log
name: App Log
labelSelector: app=app
command: tail -n 2000 -F /var/log/app.log
- identifier: pod-log
name: Pod Log
labelSelector: app=app
command: tail -n 2000 -F /var/log/syslog
- identifier: api-log
name: API Log
labelSelector: app=app
command: tail -n 2000 -F /var/log/api.log
- identifier: api-error-log
name: API Error Log
labelSelector: app=app
command: tail -n 2000 -F /var/log/api.log | grep Fatal
actions:
- identifier: server-restart
name: Restart servers
labelSelector: app=app
command: npm run restart
- identifier: packages-reinstall
name: Reinstall packages
labelSelector: app=app
command: npm run clean
- identifier: log-test-write
name: Log test write
labelSelector: app=app
command: echo $(date) >> /var/log/test.log
images:
- identifier: app
repository: app
dockerfile: Dockerfile
image: ghcr.io/nemesysltd/diploi-tiny-template
stages:
- development
- production
- staging
manualBuildStages:
- development
storage:
- identifier: app
stages:
- development
sizeMb: 8000
status:
url: http://app/api/status