Commit dfaccc81 authored by Kostas Chartsias's avatar Kostas Chartsias
Browse files

README enhancements for containerized backend

parent c417181c
Loading
Loading
Loading
Loading
+29 −4
Original line number Diff line number Diff line
@@ -38,7 +38,7 @@ Dummy_backend/

## ⚙️ Installation

### Option 1
### Option 1 - Local(venv)

Follow these steps to set up and run the API locally.

@@ -54,11 +54,16 @@ Create a `.env` file in the project root (if not already present) and set your A
API_HOST=
API_PORT=
```
### Option 2 - Containerized
Build the Docker Image


Run this inside the project root (same folder as Dockerfile):
```
docker build -t dummy-backend .
```
## 🚀 Usage

### Option 1
### Option 1 - Local(venv)
```
python app.py
```
@@ -70,8 +75,28 @@ Once the server is running, open your browser and visit:
  to explore and test the endpoints interactively. 
  * The url may very in case of the corresponding environment variables

---
### Option 2 - Containerized
Run the container:

The Dockerfile sets these defaults:
```
ENV API_HOST=0.0.0.0
ENV API_PORT=8081
```
To start the backend with these defaults:
```
docker run -p 8081:8081 dummy-backend
```
You can override the defaults at runtime.
Example change port:
```
docker run \
  -e API_PORT=9000 \
  -p 9000:9000 \
  dummy-backend
```

---
## 🤝 Contributing

To contribute: