-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathDockerfile
executable file
·54 lines (44 loc) · 2.09 KB
/
Dockerfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
#-------------------------------------------------------
# Dockerfile for building Weewx system
# With the interceptor driver and the neowx skin
#
#---> git clone the repo
#-->> build via 'docker build -t weewx .'
#->>> modify the docker-compose.yml to your needs
#>>>> run via 'docker-compose up
#
# last modified:
# 2019-05-20 - First Commit
# 2019-06-08 - Manage logs
# 2019-11-03 - Change install with source and update to 3.9.2
# 2019-11-08 - Add docker compose with nginx and custom macvlan
# 2020-11-06 - Update to 4.2.0
#
#-------------------------------------------------------
FROM debian:stretch-slim
MAINTAINER Bruno BORDAS "[email protected]"
#############################
# Install Required Packages #
#############################
RUN apt-get update && apt-get full-upgrade -y \
&& apt-get install python python-pil python-imaging python-configobj python-cheetah mysql-client python-mysqldb ftp python-dev python-pip curl wget rsyslog procps gnupg -y && pip install pyephem
#################
# Install WeewX #
#################
RUN cd /tmp && wget http://weewx.com/downloads/weewx-4.2.0.tar.gz && tar xvfz weewx-4.2.0.tar.gz && cd weewx-4.2.0 && ./setup.py build && ./setup.py install --no-prompt
###################################
# Download and Install Extentions #
###################################
RUN cd /tmp && wget -O weewx-interceptor.zip https://github.com/matthewwall/weewx-interceptor/archive/master.zip && wget -O weewx-neowx.zip https://projects.neoground.com/neowx/download/latest
RUN cd /tmp && /usr/sbin/rsyslogd && /home/weewx/bin/wee_extension --install weewx-interceptor.zip && /home/weewx/bin/wee_extension --install weewx-neowx.zip && /home/weewx/bin/wee_config --reconfigure --driver=user.interceptor --no-prompt
###################################
# Download and Install Extentions #
###################################
ADD ${PWD}/src/skin.conf /home/weewx/skins/neowx/skin.conf
ADD ${PWD}/src/daily.json.tmpl /home/weewx/skins/neowx/daily.json.tmpl
#################
# Execute Weewx #
#################
ADD ${PWD}/src/start.sh /
RUN chmod +x /start.sh
CMD ["/start.sh"]