redone the docker for testing

test
Jukoga 2024-08-12 23:37:55 +02:00
parent 230e85d3d0
commit c37470a53d
4 changed files with 18 additions and 10 deletions

View File

@ -29,7 +29,7 @@ load_dotenv()
SECRET_KEY = os.getenv('SECRET_KEY')
# SECURITY WARNING: don't run with debug turned on in production!
DEBUG = False
DEBUG = True
ALLOWED_HOSTS = ['localhost', '127.0.0.1', 'beyond-heroes.com', 'www.beyond-heroes.com']

View File

@ -10,6 +10,3 @@ ENV MARIADB_PASSWORD=DB_PASSWORD
# Expose the MariaDB port
EXPOSE 3306
# Start the MariaDB service
CMD ["mysqld"]

17
TestInstructions.md Normal file
View File

@ -0,0 +1,17 @@
First of change the Env variables in the .env and the docker-compose.yml file to your own values.
Then create the docker container and run it with the following command:
```bash
docker-compose up --build
```
This starts the Database \
Then run the following command to create the database tables:
```bash
python manage.py migrate
python manage.py migrate --run-syncdb
```
At last, run the following command to start the server:
```bash
python manage.py runserver 3030
```

View File

@ -13,9 +13,3 @@ services:
MARIADB_PASSWORD: 'DB_PASSWORD'
ports:
- "3306:3306"
volumes:
- mariadb_data:/var/lib/mysql
volumes:
mariadb_data: