Merge pull request #19 from Sn0wed1/dev-indep

Adds Dockerfile
This commit is contained in:
PLUJA 2020-09-04 07:32:40 +02:00 committed by GitHub
commit 6f0c62aa78
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 35 additions and 0 deletions

15
Dockerfile Normal file
View File

@ -0,0 +1,15 @@
FROM python:3
WORKDIR /usr/src/app
COPY requirements.txt ./
RUN pip install --no-cache-dir -r requirements.txt
COPY . .
RUN flask db init
RUN flask db migrate
RUN flask db upgrade
CMD flask run --host 0.0.0.0
EXPOSE 5000

View File

@ -110,6 +110,26 @@ You can test this new version.
9. Go to "http://localhost:5000/" and enjoy.
### Using Docker:
A quick deployment
1. Install Docker:
- `https://docs.docker.com/engine/install/`
2. Clone this repository:
- `git clone https://github.com/pluja/Yotter.git`
3. Navigate to the project folder:
- `cd Yotter`
4. Build the docker image:
- `docker build -t yotter .`
5. Run the container:
- `docker run -p 5000:5000 yotter`
6. Go to "http://localhost:5000/" and enjoy.
### 🔗 Hosting on a server:
`SOON`