Docker configuration
This commit is contained in:
parent
de195834df
commit
bdf6dd4e77
12
Dockerfile
Normal file
12
Dockerfile
Normal file
@ -0,0 +1,12 @@
|
||||
FROM python:3.9.2-slim as build
|
||||
COPY . /app
|
||||
WORKDIR /app
|
||||
RUN python setup.py install
|
||||
|
||||
FROM python:3.9.2-alpine3.13
|
||||
COPY --from=build /usr/local/lib/python3.9/site-packages /usr/local/lib/python3.9/site-packages
|
||||
|
||||
RUN pip3 install gunicorn
|
||||
|
||||
ENTRYPOINT ["gunicorn"]
|
||||
CMD ["overseer:app", "--bind", "0.0.0.0:5000", "--threads=4"]
|
@ -1,4 +1,4 @@
|
||||
include src/overseer/static/*
|
||||
include src/overseer/templates/*
|
||||
include src/overseer/api/*
|
||||
include src/overseer/api/v1/*
|
||||
recursive-include src/overseer/api *.py
|
||||
recursive-include src/overseer/static *
|
||||
recursive-include src/overseer/resources *
|
||||
recursive-include src/overseer/templates *
|
||||
|
16
README.md
16
README.md
@ -3,6 +3,15 @@
|
||||
## Description
|
||||
Overseer is a port scanning web interface. All current and historical results are stored in a database.
|
||||
|
||||
## Running
|
||||
```
|
||||
# Be sure image is built
|
||||
docker-compose build
|
||||
|
||||
# Run compose in background. Service accessible via localhost:5000
|
||||
docker-compose up -d
|
||||
```
|
||||
|
||||
## Developing
|
||||
|
||||
### Server
|
||||
@ -30,13 +39,6 @@ You must run these commands from the `./src/overseer_client/` directory:
|
||||
yarn build
|
||||
```
|
||||
|
||||
## Running
|
||||
|
||||
Ideally from a virtual env:
|
||||
```
|
||||
overseer run
|
||||
```
|
||||
|
||||
# Notes
|
||||
In a production environment, it would be ideal to setup something like nginx to properly forward
|
||||
the `/api/*` routes to the Flask server, and all other endpoints to the static client resources.
|
||||
|
8
docker-compose.yml
Normal file
8
docker-compose.yml
Normal file
@ -0,0 +1,8 @@
|
||||
---
|
||||
services:
|
||||
overseer:
|
||||
ports:
|
||||
- '5000:5000'
|
||||
build: .
|
||||
volumes:
|
||||
- .:/app
|
Loading…
Reference in New Issue
Block a user