-
Notifications
You must be signed in to change notification settings - Fork 32
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
加油💪🏻 #48
Comments
apk update && apk upgrade && apk add xz |
docker-compose.yml version: '3.8'
services:
proxypool_db:
hostname: proxypool_db
image: mysql:5.7
container_name: proxypool_db
privileged: true
restart: on-failure:3
environment:
TZ: Asia/Shanghai
MYSQL_ROOT_PASSWORD: root
volumes:
- ./dockerconfig/mysql/sql/mysql.sql:/app/sql/mysql.sql
# 把要执行的shell文件放到/docker-entrypoint-initdb.d/目录下,容器会自动执行这个shell
- ./dockerconfig/mysql/init/docker-entrypoint.sh:/docker-entrypoint-initdb.d/docker-entrypoint.sh
- ./dockerconfig/mysql/conf/my.cnf:/etc/mysql/mysql.conf.d/mysqld.cnf
- ./dockerconfig/mysql/logs:/var/log/mysql
- ./dockerconfig/mysql/data:/var/lib/mysql
command:
--character-set-server=utf8mb4
--collation-server=utf8mb4_general_ci
--explicit_defaults_for_timestamp=true
--lower_case_table_names=1
--max_allowed_packet=1024M
--default-authentication-plugin=mysql_native_password
--sql-mode="STRICT_TRANS_TABLES,NO_AUTO_CREATE_USER,NO_ENGINE_SUBSTITUTION,NO_ZERO_DATE,NO_ZERO_IN_DATE,ERROR_FOR_DIVISION_BY_ZERO"
--max_connections=3600
user: root
proxypool:
hostname: proxypool
image: proxypool:latest
container_name: proxypool
build:
context: .
dockerfile: Dockerfile
restart: on-failure:3
ports:
- "3000:3000"
volumes:
- ./dockerconfig/proxypool/logs:/app/logs
- ./dockerconfig/proxypool/conf/config.yaml:/app/conf/config.yaml
command: /app/IpProxyPool proxy-pool
links:
- proxypool_db
depends_on:
- proxypool_db 需要vscode 找的 127.0.0.1 替换成 proxypool_db |
格式能不能支持这个 |
能否使用sqlite3代替mysql,太吃内存了 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
mv docker-compose.yaml docker-compose.yml
docker-compose up -d
docker-compose down
The text was updated successfully, but these errors were encountered: