新增说明及示例文件;更新README.md
This commit is contained in:
50
description/compose.yaml
Normal file
50
description/compose.yaml
Normal file
@@ -0,0 +1,50 @@
|
||||
version: "3.9"
|
||||
|
||||
services:
|
||||
${SERVICE_NAME}:
|
||||
image: ${IMAGE_NAME}:${IMAGE_TAG}
|
||||
container_name: ${CONTAINER_NAME}
|
||||
restart: on-failure:3
|
||||
privileged: true
|
||||
user: ${USER_NAME}:${USER_GROUP}
|
||||
working_dir: ${WORKING_DIR}
|
||||
volumes:
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
- ${VOLUME_NAME}:${CONTAINER_PATH}
|
||||
- ${HOST_PATH}:${CONTAINER_PATH}
|
||||
configs:
|
||||
- ${CONFIG_NAME}
|
||||
secrets:
|
||||
- ${SECRET_NAME}
|
||||
environment:
|
||||
- ${KEY}=${VALUE}
|
||||
command: ${COMMAND}
|
||||
depends_on:
|
||||
- ${SERVICE_NAME}
|
||||
network_mode: host
|
||||
ports:
|
||||
- ${HOST_PORT}:${CONTAINER_PORT}
|
||||
networks:
|
||||
- ${NETWORK_NAME}
|
||||
|
||||
volumes:
|
||||
${VOLUME_NAME}:
|
||||
external: true
|
||||
name: ${VOLUME_NAME}
|
||||
|
||||
configs:
|
||||
${CONFIG_NAME}:
|
||||
external: true
|
||||
name: ${CONFIG_NAME}
|
||||
file: ${CONFIG_FILE_NAME}
|
||||
|
||||
secrets:
|
||||
${SECRET_NAME}:
|
||||
external: true
|
||||
name: ${SECRET_NAME}
|
||||
file: ${SECRET_FILE_NAME}
|
||||
|
||||
networks:
|
||||
${NETWORK_NAME}:
|
||||
external: true
|
||||
name: ${NETWORK_NAME}
|
||||
Reference in New Issue
Block a user