Compare commits

..

6 Commits

2 changed files with 19 additions and 4 deletions

View File

@ -11,10 +11,15 @@ RUN \
apt update && \
apt install -y cron && \
apt install -y exim4 && \
apt install -y vim.tiny && \
apt install -y python3 && \
apt install -y python3-pip && \
pip3 install requests && \
pip3 install Cheetah3 && \
update-alternatives --install /usr/bin/python python /usr/bin/python3 10 && \
update-alternatives --install /usr/bin/pip pip /usr/bin/pip3 10 && \
pip install requests && \
pip install Cheetah3 && \
pip install pandas && \
pip install influxdb && \
sed -i \
-e "s/dc_eximconfig_configtype='local'/dc_eximconfig_configtype='satellite'/" \
-e "s/dc_smarthost=''/dc_smarthost='${SMARTHOST}'/" \
@ -24,9 +29,15 @@ RUN \
mkdir -p ${APP_DIR} && \
useradd -d ${APP_DIR} -u 1000 user
COPY crontab /etc/
COPY crontab ${APP_DIR}/
COPY *.py ${APP_DIR}/
COPY *.tmpl ${APP_DIR}/
RUN \
rm -f /etc/crontab && \
ln -s ${APP_DIR}/crontab /etc/crontab
VOLUME ${APP_DIR}
# USER 1000:1000
WORKDIR ${APP_DIR}

4
example.py Executable file
View File

@ -0,0 +1,4 @@
#!/usr/bin/python
print("Hello world!\")