Init
This commit is contained in:
@@ -0,0 +1,2 @@
|
|||||||
|
PASSWORD="MyVSCodePassword"
|
||||||
|
SUDO_PASSWORD="MyVSCodeStrongPassword"
|
||||||
@@ -0,0 +1,53 @@
|
|||||||
|
services:
|
||||||
|
vscode:
|
||||||
|
image: lscr.io/linuxserver/code-server:latest
|
||||||
|
container_name: vscode
|
||||||
|
environment:
|
||||||
|
- VIRTUAL_HOST=vsc.domain.ru
|
||||||
|
- VIRTUAL_PORT=8443
|
||||||
|
- LETSENCRYPT_HOST=vsc.domain.ru
|
||||||
|
- LETSENCRYPT_EMAIL=my@email.ru
|
||||||
|
- TZ=Europe/Moscow
|
||||||
|
- PASSWORD=${PASSWORD}
|
||||||
|
- SUDO_PASSWORD=${SUDO_PASSWORD}
|
||||||
|
- PUID=1100
|
||||||
|
- PGID=1100
|
||||||
|
expose:
|
||||||
|
- 8443
|
||||||
|
# ports:
|
||||||
|
# - "4080:8080"
|
||||||
|
# - "4443:8443"
|
||||||
|
restart: unless-stopped
|
||||||
|
volumes:
|
||||||
|
- /opt:/opt:rw
|
||||||
|
- /mnt:/mnt:rw
|
||||||
|
- vscode_config:/config
|
||||||
|
- vscode_workspace:/workspace
|
||||||
|
networks:
|
||||||
|
- "net"
|
||||||
|
deploy:
|
||||||
|
resources:
|
||||||
|
limits:
|
||||||
|
memory: 1G # жёсткий лимит RAM
|
||||||
|
cpus: '1.0' # максимум 1 ядро CPU
|
||||||
|
reservations:
|
||||||
|
memory: 512M # гарантированный минимум RAM
|
||||||
|
cpus: '0.5' # минимум 0.5 ядра CPU
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
vscode_config:
|
||||||
|
driver: local
|
||||||
|
driver_opts:
|
||||||
|
type: none
|
||||||
|
device: /mnt/vscode/config
|
||||||
|
o: bind
|
||||||
|
vscode_workspace:
|
||||||
|
driver: local
|
||||||
|
driver_opts:
|
||||||
|
type: none
|
||||||
|
device: /mnt/vscode/workspace
|
||||||
|
o: bind
|
||||||
|
|
||||||
|
networks:
|
||||||
|
net:
|
||||||
|
external: true
|
||||||
Reference in New Issue
Block a user