feature(microservice rpc docker):
This commit is contained in:
parent
6e2eea3337
commit
9601cb9f30
|
@ -46,8 +46,19 @@ services:
|
||||||
- REACT_APP_API_URL=http://localhost:8000/api
|
- REACT_APP_API_URL=http://localhost:8000/api
|
||||||
networks:
|
networks:
|
||||||
- dbnet
|
- dbnet
|
||||||
|
|
||||||
|
safeshare-virus:
|
||||||
|
build:
|
||||||
|
context: ./safeshare_vdb
|
||||||
|
dockerfile: Dockerfile
|
||||||
|
restart:
|
||||||
|
always
|
||||||
|
ports:
|
||||||
|
- "50051:50051"
|
||||||
|
networks:
|
||||||
|
- dbnet
|
||||||
|
|
||||||
volumes:
|
volumes:
|
||||||
redis_data:
|
redis_data:
|
||||||
|
|
||||||
networks:
|
networks:
|
||||||
dbnet:
|
dbnet:
|
||||||
|
|
|
@ -0,0 +1,14 @@
|
||||||
|
FROM python:3.11
|
||||||
|
LABEL authors="junwei"
|
||||||
|
|
||||||
|
# Copy the current directory contents into the container at /app
|
||||||
|
COPY . /app
|
||||||
|
|
||||||
|
# Set the working directory to /app
|
||||||
|
WORKDIR /app
|
||||||
|
|
||||||
|
# Install any needed packages for grpc and environ
|
||||||
|
RUN pip install grpcio grpcio-tools django-environ
|
||||||
|
|
||||||
|
# Start Server at server.py
|
||||||
|
CMD ["python", "server.py"]
|
Loading…
Reference in New Issue