diff --git a/Dockerfile b/Dockerfile index 631d982..219b7f6 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ -FROM python:3-slim +FROM cloudforet/python-core:1 ENV PYTHONUNBUFFERED 1 -ENV SPACEONE_PORT 50051 +ENV CLOUDONE_PORT 50051 ENV SERVER_TYPE grpc ENV PKG_DIR /tmp/pkg ENV SRC_DIR /tmp/src @@ -9,19 +9,17 @@ ENV SRC_DIR /tmp/src RUN apt update && apt upgrade -y COPY pkg/*.txt ${PKG_DIR}/ - RUN pip install --upgrade pip && \ - pip install --upgrade -r ${PKG_DIR}/pip_requirements.txt - -ARG CACHEBUST=1 -RUN pip install --upgrade --pre spaceone-core spaceone-api + pip install --upgrade --use-deprecated=legacy-resolver -r ${PKG_DIR}/pip_requirements.txt && \ + pip install --upgrade spaceone-api COPY src ${SRC_DIR} + WORKDIR ${SRC_DIR} RUN python3 setup.py install && \ rm -rf /tmp/* -EXPOSE ${SPACEONE_PORT} +EXPOSE ${CLOUDONE_PORT} ENTRYPOINT ["spaceone"] -CMD ["grpc", "cloudforet.cost_analysis"] +CMD ["grpc", "spaceone.cost_analysis"] diff --git a/pkg/pip_requirements.txt b/pkg/pip_requirements.txt index 92a4891..34de6db 100644 --- a/pkg/pip_requirements.txt +++ b/pkg/pip_requirements.txt @@ -1,5 +1,2 @@ -spaceone-core -spaceone-api schematics -boto3 pytz \ No newline at end of file diff --git a/src/setup.py b/src/setup.py index 468b0a6..570827b 100644 --- a/src/setup.py +++ b/src/setup.py @@ -31,10 +31,8 @@ license='Apache License 2.0', packages=find_packages(), install_requires=[ - 'spaceone-core', 'spaceone-api', 'schematics', - 'boto3', 'pytz' ], zip_safe=False,