Skip to content

Commit 271ce99

Browse files
committed
feat(docker): updated sdk installation in docker file
1 parent 5609fd2 commit 271ce99

File tree

1 file changed

+11
-7
lines changed

1 file changed

+11
-7
lines changed

docker/Dockerfile

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,25 @@
1-
#Import python runtime with desired python version
1+
#Import Python base image
22
FROM python:3-slim
33

44
#Install Git
55
RUN apt-get update && \
6-
apt-get install -y git
6+
apt-get install -y --no-install-recommends git && \
7+
apt-get clean && \
8+
rm -rf /var/lib/apt/lists/*
79

810
#Clone SDK repo to app directory
911
RUN git clone https://github.com/watson-developer-cloud/python-sdk.git
1012

11-
#Set working directory to python-sdk
13+
#Install the SDK
14+
RUN pip install --upgrade ibm-watson
15+
16+
# #Set working directory to python-sdk
1217
WORKDIR /python-sdk
1318

14-
#Pip install dependencies for SDK
15-
RUN pip install --editable .
19+
#Install test dependencies and run tests to verify installation.
1620
RUN pip install -r requirements-dev.txt
1721

18-
#Run tests to validate installation
19-
CMD [ "py.test" , "test" ]
22+
#Run tests to verify installation
23+
CMD ["py.test","test"]
2024

2125

0 commit comments

Comments
 (0)