1
0
Fork 0
mirror of synced 2024-11-16 22:25:33 -05:00
ovpn-admin/docker-compose.yaml
2023-10-10 15:20:40 +00:00

41 lines
1.1 KiB
YAML

version: '3'
services:
openvpn:
build:
context: .
image: ovpn-admin:local
command: /etc/openvpn/setup/configure.sh
environment:
OVPN_SERVER_NET: ${OVPN_SERVER_NET}
OVPN_SERVER_MASK: ${OVPN_SERVER_MASK}
OVPN_LISTEN_BASE_URL: ${OVPN_LISTEN_BASE_URL}
OVPN_AUTH: ${OVPN_AUTH}
cap_add:
- NET_ADMIN
ports:
- 7777:1194 # for openvpn
- 8080:8080 # for ovpn-admin because of network_mode
volumes:
- /tmp/easyrsa_master:/etc/openvpn/easyrsa
- /tmp/ccd_master:/etc/openvpn/ccd
ovpn-admin:
build:
context: .
image: ovpn-admin:local
command: /app/ovpn-admin
environment:
OVPN_NETWORK: ${OVPN_NETWORK}
OVPN_CCD: ${OVPN_CCD}
OVPN_CCD_PATH: ${OVPN_CCD_PATH}
EASYRSA_PATH: ${EASYRSA_PATH}
OVPN_SERVER: ${OVPN_SERVER}
OVPN_INDEX_PATH: ${OVPN_INDEX_PATH}
OVPN_LISTEN_BASE_URL: ${OVPN_LISTEN_BASE_URL}
OVPN_AUTH: ${OVPN_AUTH}
OVPN_AUTH_DB_PATH: ${OVPN_AUTH_DB_PATH}
LOG_LEVEL: ${LOG_LEVEL}
network_mode: service:openvpn
volumes:
- /tmp/easyrsa_master:/mnt/easyrsa
- /tmp/ccd_master:/mnt/ccd