olig48
3 years ago
commit
3f25917465
6 changed files with 130 additions and 0 deletions
@ -0,0 +1,16 @@
@@ -0,0 +1,16 @@
|
||||
version: '3' |
||||
services: |
||||
db: |
||||
image: mysql |
||||
container_name: mysql # 容器名 |
||||
command: mysqld --character-set-server=utf8mb4 --collation-server=utf8mb4_unicode_ci #设置utf8字符集 |
||||
restart: always |
||||
volumes: |
||||
- ./database:/var/lib/mysql |
||||
environment: |
||||
- MYSQL_ROOT_PASSWORD=XXXX |
||||
- MYSQL_DATABASE=XXXXX |
||||
- MYSQL_USER=XXXXX |
||||
- MYSQL_PASSWORD=XXXXX |
||||
ports: |
||||
- 3306:3306 |
@ -0,0 +1,47 @@
@@ -0,0 +1,47 @@
|
||||
nextcloud: |
||||
image: nextcloud |
||||
container_name: nextcloud_web |
||||
links: |
||||
- nextcloud-db:nextcloud-db |
||||
environment: |
||||
- UID=1000 |
||||
- GID=1000 |
||||
- UPLOAD_MAX_SIZE=5G |
||||
- APC_SHM_SIZE=128M |
||||
- OPCACHE_MEM_SIZE=128 |
||||
- CRON_PERIOD=15m |
||||
- TZ=Aisa/Shanghai |
||||
- ADMIN_USER=liucnt |
||||
- ADMIN_PASSWORD=6724130ltm |
||||
- DOMAIN=localhost |
||||
- DB_TYPE=mysql |
||||
- DB_NAME=nextcloud |
||||
- DB_USER=nextcloud |
||||
- DB_PASSWORD=6724130ltm |
||||
- DB_HOST=nextcloud-db |
||||
volumes: |
||||
# 文件会放在宿主机的 `/docker/nextcloud` 目录,如果不存在会自动创建 |
||||
- /docker/nextcloud/data:/data |
||||
- /docker/nextcloud/config:/config |
||||
- /docker/nextcloud/apps:/apps2 |
||||
- /docker/nextcloud/themes:/nextcloud/themes |
||||
- /ssd:/storage |
||||
expose: |
||||
- 80 |
||||
ports: |
||||
# 宿主机端口:镜像端口 |
||||
- 8080:80/tcp |
||||
restart: always |
||||
|
||||
nextcloud-db: |
||||
image: mysql/mysql-server |
||||
container_name: nextcloud_db |
||||
volumes: |
||||
# 数据库文件会放在宿主机的 `/docker/nextcloud/db` 目录,如果不存在会自动创建 |
||||
- /docker/nextcloud/db:/var/lib/mysql |
||||
environment: |
||||
- MYSQL_ROOT_PASSWORD=6724130ltm |
||||
- MYSQL_DATABASE=nextcloud |
||||
- MYSQL_USER=nextcloud |
||||
- MYSQL_PASSWORD=6724130ltm |
||||
restart: always |
@ -0,0 +1,21 @@
@@ -0,0 +1,21 @@
|
||||
FROM python:3.7-alpine |
||||
|
||||
COPY ./xxx /xxx |
||||
|
||||
WORKDIR /xxx |
||||
|
||||
RUN sed -i 's/dl-cdn.alpinelinux.org/mirrors.cloud.tencent.com/g' /etc/apk/repositories \ |
||||
&& apk add tzdata \ |
||||
&& cp /usr/share/zoneinfo/Asia/Shanghai /etc/localtime \ |
||||
&& echo 'Asia/Shanghai' >/etc/timezone \ |
||||
&& pip config set global.index-url https://mirrors.cloud.tencent.com/pypi/simple \ |
||||
&& apk add --no-cache --virtual .build-deps gcc libc-dev libxslt-dev \ |
||||
&& apk add --no-cache libxslt \ |
||||
&& python -m pip install --upgrade pip \ |
||||
&& pip install -r requirements.txt \ |
||||
&& apk del .build-deps tzdata |
||||
|
||||
VOLUME ["/xxx"] |
||||
|
||||
CMD ["python","-u","main.py","timing"] |
||||
|
@ -0,0 +1,35 @@
@@ -0,0 +1,35 @@
|
||||
version: '3.1' |
||||
services: |
||||
samba: |
||||
image: dperson/samba:latest |
||||
container_name: samba |
||||
restart: always |
||||
network_mode: 'host' |
||||
volumes: |
||||
- /media:/mount |
||||
environment: |
||||
TZ: 'Asia/Shanghai' |
||||
USER: 'liu;123123' |
||||
SHARE: 'share;/mount/;yes;no;no;all;none' |
||||
logging: |
||||
driver: "json-file" |
||||
options: |
||||
max-size: "1m" |
||||
|
||||
minidlna: |
||||
image: vladgh/minidlna |
||||
container_name: minidlna |
||||
restart: always |
||||
network_mode: 'host' |
||||
environment: |
||||
- MINIDLNA_MEDIA_DIR=/media |
||||
- MINIDLNA_FRIENDLY_NAME=MiniDLNA |
||||
- MINIDLNA_INOTIFY=yes |
||||
- MINIDLNA_NOTIFY_INTERVAL=3 |
||||
volumes: |
||||
- /root/cache/minidlna:/var/lib/minidlna |
||||
- /media:/media |
||||
logging: |
||||
driver: "json-file" |
||||
options: |
||||
max-size: "1m" |
Loading…
Reference in new issue