-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathdocker-compose.yaml
More file actions
45 lines (40 loc) · 1.19 KB
/
docker-compose.yaml
File metadata and controls
45 lines (40 loc) · 1.19 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
volumes:
git-repo:
ssh-key:
services:
dev:
build:
context: .
dockerfile: Dockerfile
volumes:
- /var/run/docker.sock:/var/run/docker.sock
- ssh-key:/root/.ssh
- git-repo:/root/app-repo
# keep the container running basically -t
tty: true
# run in interactive mode basically -i
stdin_open: true
# incase docker commands that require privileged mode
# privileged: true
command: >
/bin/bash -c "
if [ ! -f ~/.ssh/id_ed25519 ]; then
ssh-keygen -t ed25519 -f ~/.ssh/id_ed25519 -N '' &&
cat ~/.ssh/id_ed25519.pub &&
echo 'Add key to https://github.com/settings/ssh/new';
else
echo 'Not overwriting, SSH key already exist';
fi
tail -f /dev/null
"
environment:
- DOCKER_HOST=unix:///var/run/docker.sock
ports:
# DONT FORWARD THE VITE PORT, LET VSCODE DEAL WITH IT
- "5173:5173"
# for dir in $(find . -type f -name "package.json" -not -path "*/node_modules/*"); do
# (cd $(dirname "$dir") && npm install)
# done
# for dir in $(find . -type f -name "requirements.txt"); do
# (cd $(dirname "$dir") && pip install -r requirements.txt)
# done