Skip to content

Commit

Permalink
.
Browse files Browse the repository at this point in the history
  • Loading branch information
14790897 committed Jul 9, 2023
1 parent 6c8cbe3 commit bcb38b4
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 9 deletions.
Empty file added .env_template
Empty file.
2 changes: 2 additions & 0 deletions backend/app.py
Original file line number Diff line number Diff line change
Expand Up @@ -541,6 +541,8 @@ def after_request(response):
traces_sample_rate=1.0,
)



app.run(debug=True, host="0.0.0.0", port=5000)

# good luck 6/16/2023
Expand Down
6 changes: 1 addition & 5 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,9 @@ services:
ports:
- "5000:5000"

db:
localhost:
image: 14790897/mysql-handwriting:latest
command: --default-authentication-plugin=mysql_native_password
restart: always
environment:
MYSQL_ROOT_PASSWORD: ${MYSQL_ROOT_PASSWORD}
MYSQL_DATABASE: ${MYSQL_DATABASE}

ports:
- 3306:3306
4 changes: 2 additions & 2 deletions mysql/dockerfile.mysql
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,9 @@ FROM mysql:5.7

# 设置环境变量
ENV MYSQL_ROOT_PASSWORD rootpass
ENV MYSQL_DATABASE mydb
ENV MYSQL_DATABASE your_database
ENV MYSQL_USER myuser
ENV MYSQL_PASSWORD mypass
ENV MYSQL_PASSWORD mypassword

# 复制 init.sql 文件到/docker-entrypoint-initdb.d 目录下
COPY init.sql /docker-entrypoint-initdb.d
4 changes: 2 additions & 2 deletions mysql/init.sql
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
CREATE DATABASE IF NOT EXISTS mydb;
USE mydb;
CREATE DATABASE IF NOT EXISTS your_database;
USE your_database

CREATE TABLE user_images (
id INT AUTO_INCREMENT PRIMARY KEY,
Expand Down

0 comments on commit bcb38b4

Please sign in to comment.