Add glances binary to '/usr/local/bin' + Update ENV PATH to include '/venv/bin' in Dockerfiles - Reported from devel branch #2419

This commit is contained in:
nicolargo 2023-05-20 16:09:27 +02:00
parent 87b8300cc6
commit 40fd7fe7c7
4 changed files with 14 additions and 0 deletions

View File

@ -15,3 +15,6 @@
# Include Config file
!/docker-compose/glances.conf
# Include Binary file
!/docker-bin.sh

3
docker-bin.sh Normal file
View File

@ -0,0 +1,3 @@
#!/bin/sh
/venv/bin/python3 -m glances $@

View File

@ -86,6 +86,10 @@ FROM base as release
COPY ./docker-compose/glances.conf /etc/glances.conf
COPY /glances /app/glances
# Copy binary and update PATH
COPY docker-bin.sh /usr/local/bin/glances
ENV PATH="/venv/bin:$PATH"
# EXPOSE PORT (XMLRPC / WebUI)
EXPOSE 61209 61208

View File

@ -80,6 +80,10 @@ FROM base as release
COPY ./docker-compose/glances.conf /etc/glances.conf
COPY /glances /app/glances
# Copy binary and update PATH
COPY docker-bin.sh /usr/local/bin/glances
ENV PATH="/venv/bin:$PATH"
# EXPOSE PORT (XMLRPC / WebUI)
EXPOSE 61209 61208