-
Notifications
You must be signed in to change notification settings - Fork 344
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
1722537
commit 5d5d8a4
Showing
1 changed file
with
3 additions
and
6 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,4 +1,4 @@ | ||
FROM alpine:3.20.2 | ||
FROM python:3.12-alpine | ||
|
||
LABEL net.juniper.description="Junos PyEZ library for Python in a lightweight container." \ | ||
net.juniper.maintainer="[email protected]" | ||
|
@@ -12,15 +12,12 @@ ADD requirements.txt . | |
ADD lib lib | ||
ADD entrypoint.sh /usr/local/bin/. | ||
|
||
## Install dependencies | ||
## Install dependancies and PyEZ | ||
RUN apk add --no-cache build-base python3-dev \ | ||
libxslt-dev libxml2-dev libffi-dev openssl-dev curl \ | ||
ca-certificates py3-pip bash | ||
|
||
## Update as per PEP 668. Use Virtual Env | ||
RUN python3 -m venv /scripts/.venv \ | ||
&& source /scripts/.venv/bin/activate \ | ||
&& pip install --upgrade pip \ | ||
RUN pip install --upgrade pip \ | ||
&& pip install pipdeptree \ | ||
&& python3 -m pip install -r requirements.txt \ | ||
&& pip install . | ||
|