-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathdevfile.yaml
More file actions
61 lines (59 loc) · 1.74 KB
/
Copy pathdevfile.yaml
File metadata and controls
61 lines (59 loc) · 1.74 KB
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
schemaVersion: 2.2.0
metadata:
name: starter-app-python-new
attributes:
pod-overrides:
spec:
volumes:
- name: continue-config-volume
configMap:
name: continue-config
defaultMode: 0644
components:
- name: python
attributes:
container-overrides:
volumeMounts:
- name: continue-config-volume
mountPath: /tmp/continue-config
subPath: config.json
container:
image: registry.redhat.io/devspaces/udi-rhel9@sha256:cca6cbf5adcb5ce83392795573fe258d468568bddc3ad3618297e9e6234cfb79
volumeMounts:
- name: venv
path: /home/user/.venv
memoryLimit: 2G
mountSources: true
- name: venv
volume:
size: 1G
commands:
- id: setup-continue
exec:
label: "Setup Continue Extension"
component: python
commandLine: |
# Create Continue directory if it doesn't exist
mkdir -p /home/user/.continue
# Copy config from ConfigMap mount
cp /tmp/continue-config /home/user/.continue/config.json
# Verify the setup
echo "Continue configuration copied successfully!"
echo "Config location: /home/user/.continue/config.json"
ls -la /home/user/.continue/config.json
group:
kind: build
- id: run
exec:
label: "Run the application"
component: python
workingDir: ${PROJECTS_ROOT}/starter-app-python
commandLine: >-
python -m venv /home/user/.venv/ &&
source /home/user/.venv/bin/activate &&
pip install -r requirements.txt &&
export PYTHONDONTWRITEBYTECODE=1 &&
export PATH=$PATH:/home/user/.local/bin &&
gunicorn -b 0.0.0.0:8080 app --reload
group:
kind: run