-
Notifications
You must be signed in to change notification settings - Fork 560
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Switch Docker image to Python 3 and reduce the number of layers and s…
…ize (#980)
- Loading branch information
1 parent
c11ae8b
commit e0cc9af
Showing
1 changed file
with
7 additions
and
12 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,10 @@ | ||
FROM debian:stretch | ||
|
||
## Install min deps | ||
RUN apt-get update | ||
FROM python:3.6-slim-stretch | ||
|
||
COPY ./ /var/cache/napalm/ | ||
|
||
## Install NAPALM & underlying libraries dependencies | ||
RUN apt-get install -y python-cffi python-dev libxslt1-dev libssl-dev libffi-dev \ | ||
&& apt-get install -y python-pip \ | ||
&& pip install -U cffi \ | ||
&& pip install -U cryptography \ | ||
&& pip install /var/cache/napalm/ | ||
|
||
RUN rm -rf /var/lib/apt/lists/* | ||
RUN apt-get update \ | ||
&& apt-get install -y python-dev python-cffi libxslt1-dev libssl-dev libffi-dev \ | ||
&& apt-get autoremove \ | ||
&& rm -rf /var/lib/apt/lists/* \ | ||
&& pip --no-cache-dir install -U cffi cryptography /var/cache/napalm/ \ | ||
&& rm -rf /var/cache/napalm/ |