Skip to content

Commit

Permalink
Oh, my docker
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander-Porter committed Jul 6, 2024
1 parent 27ca911 commit 889d0b8
Show file tree
Hide file tree
Showing 2 changed files with 26 additions and 1 deletion.
5 changes: 4 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,10 @@ services:
retries: 5

web:
build: .
build:
context: .
dockerfile: Dockerfile
#image: ghcr.io/alexander-porter/qsyncbackend:main
ports:
- "8099:8080"
environment:
Expand Down
22 changes: 22 additions & 0 deletions readme.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,3 +8,25 @@ QSyncBackend is a simple backend written in Python for syncing files between two
4. Run the backend using `gunicorn -w 4 -b 127.0.0.1:8080 app:app`

## Run from Docker
1. Modify the `.env` file to set your MySQL database credentials:

```bash
DB_USER=your_username
DB_PASSWORD=your_password
DB_NAME=your_database_name
DB_HOST=your_database_host
SECRET_KEY=your_secret_key_here
NEED_CAPTCHA=True
```

2. Run
```bash
docker run -d -p 8099:8080 --env-file .env ghcr.io/alexander-porter/qsyncbackend:main
```

## Run from Docker Compose
1. Clone the repository
2. Run
```bash
docker-compose up -d
```

0 comments on commit 889d0b8

Please sign in to comment.