Skip to content

Commit

Permalink
[Chore] Use SQLite for development env (#1462)
Browse files Browse the repository at this point in the history
  • Loading branch information
alexjustesen authored Jun 6, 2024
1 parent 74ef970 commit 3f84d68
Show file tree
Hide file tree
Showing 2 changed files with 35 additions and 36 deletions.
15 changes: 7 additions & 8 deletions .env.example
Original file line number Diff line number Diff line change
Expand Up @@ -19,17 +19,18 @@ LOG_STACK=single
LOG_DEPRECATIONS_CHANNEL=null
LOG_LEVEL=debug

DB_CONNECTION=mysql
DB_HOST=127.0.0.1
DB_PORT=3306
DB_DATABASE=speedtest_tracker
DB_USERNAME=
DB_PASSWORD=
DB_CONNECTION=sqlite
# DB_HOST=127.0.0.1
# DB_PORT=3306
# DB_DATABASE=speedtest_tracker
# DB_USERNAME=
# DB_PASSWORD=

BROADCAST_CONNECTION=log
CACHE_STORE=database
FILESYSTEM_DISK=local
QUEUE_CONNECTION=database

SESSION_DRIVER=database
SESSION_LIFETIME=120
SESSION_ENCRYPT=false
Expand All @@ -44,5 +45,3 @@ MAIL_PASSWORD=null
MAIL_ENCRYPTION=null
MAIL_FROM_ADDRESS="[email protected]"
MAIL_FROM_NAME="Speedtest Tracker"

TELEGRAM_BOT_TOKEN=null
56 changes: 28 additions & 28 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,33 +21,33 @@ services:
networks:
- sail
depends_on:
- mysql
# - mysql
- mailpit
# - pgsql
mysql:
image: 'mysql/mysql-server:8.0'
ports:
- '${FORWARD_DB_PORT:-3306}:3306'
environment:
MYSQL_ROOT_PASSWORD: '${DB_PASSWORD}'
MYSQL_ROOT_HOST: '%'
MYSQL_DATABASE: '${DB_DATABASE}'
MYSQL_USER: '${DB_USERNAME}'
MYSQL_PASSWORD: '${DB_PASSWORD}'
MYSQL_ALLOW_EMPTY_PASSWORD: 1
volumes:
- 'sail-mysql:/var/lib/mysql'
- './docker/mysql/create-testing-database.sh:/docker-entrypoint-initdb.d/10-create-testing-database.sh'
networks:
- sail
healthcheck:
test:
- CMD
- mysqladmin
- ping
- '-p${DB_PASSWORD}'
retries: 3
timeout: 5s
# mysql:
# image: 'mysql/mysql-server:8.0'
# ports:
# - '${FORWARD_DB_PORT:-3306}:3306'
# environment:
# MYSQL_ROOT_PASSWORD: '${DB_PASSWORD}'
# MYSQL_ROOT_HOST: '%'
# MYSQL_DATABASE: '${DB_DATABASE}'
# MYSQL_USER: '${DB_USERNAME}'
# MYSQL_PASSWORD: '${DB_PASSWORD}'
# MYSQL_ALLOW_EMPTY_PASSWORD: 1
# volumes:
# - 'sail-mysql:/var/lib/mysql'
# - './docker/mysql/create-testing-database.sh:/docker-entrypoint-initdb.d/10-create-testing-database.sh'
# networks:
# - sail
# healthcheck:
# test:
# - CMD
# - mysqladmin
# - ping
# - '-p${DB_PASSWORD}'
# retries: 3
# timeout: 5s
mailpit:
image: 'axllent/mailpit:latest'
ports:
Expand Down Expand Up @@ -83,8 +83,8 @@ services:
networks:
sail:
driver: bridge
volumes:
sail-mysql:
driver: local
# volumes:
# sail-mysql:
# driver: local
# sail-pgsql:
# driver: local

0 comments on commit 3f84d68

Please sign in to comment.