aboutsummaryrefslogtreecommitdiffstats
path: root/nms
diff options
context:
space:
mode:
Diffstat (limited to 'nms')
-rw-r--r--nms/Dockerfile.in58
1 files changed, 47 insertions, 11 deletions
diff --git a/nms/Dockerfile.in b/nms/Dockerfile.in
index c3d861a..40cecee 100644
--- a/nms/Dockerfile.in
+++ b/nms/Dockerfile.in
@@ -42,25 +42,61 @@ RUN echo . /etc/bash_completion >> /root/.bashrc
ENV TERM=rxvt-unicode
ADD .vimrc /root/.vimrc
RUN rm /etc/apt/apt.conf.d/docker-clean
-RUN systemctl mask dev-hugepages.mount sys-fs-fuse-connections.mount
-RUN git clone https://github.com/tech-server/tgmanage.git root/tgmanage
-RUN systemctl disable systemd-logind.service
-
+RUN systemctl mask dev-hugepages.mount sys-fs-fuse-connections.mount systemd-logind.service
+RUN git clone https://github.com/tech-server/tgmanage.git /srv/tgmanage
+#RUN systemctl disable systemd-logind.service
CMD ["/sbin/init"]
@template nms-front
FROM nms-base
-RUN apt-get -y install libcapture-tiny-perl libcgi-pm-perl libcommon-sense-perl libdata-dumper-simple-perl libdbi-perl libdigest-perl libgd-perl libgeo-ip-perl libhtml-parser-perl libhtml-template-perl libimage-magick-perl libimage-magick-q16-perl libjson-perl libjson-xs-perl libnetaddr-ip-perl libnet-cidr-perl libnet-ip-perl libnet-openssh-perl libnet-oping-perl libnet-rawip-perl libnet-telnet-cisco-perl libnet-telnet-perl libsnmp-perl libsocket6-perl libsocket-perl libswitch-perl libtimedate-perl perl perl-base perl-modules
+RUN apt-get -y install \
+ libcapture-tiny-perl \
+ libcgi-pm-perl \
+ libcommon-sense-perl \
+ libdata-dumper-simple-perl \
+ libdbd-pg-perl \
+ libdbi-perl \
+ libdigest-perl \
+ libgd-perl \
+ libgeo-ip-perl \
+ libhtml-parser-perl \
+ libhtml-template-perl \
+ libimage-magick-perl \
+ libimage-magick-q16-perl \
+ libjson-perl \
+ libjson-xs-perl \
+ libnetaddr-ip-perl \
+ libnet-cidr-perl \
+ libnet-ip-perl \
+ libnet-openssh-perl \
+ libnet-oping-perl \
+ libnet-rawip-perl \
+ libnet-telnet-cisco-perl \
+ libnet-telnet-perl \
+ libsnmp-perl \
+ libsocket6-perl \
+ libsocket-perl \
+ libswitch-perl \
+ libtimedate-perl \
+ perl \
+ perl-base \
+ perl-modules \
+ varnish \
+ apache2 \
+
+RUN cd /srv/tgmanage/ && tools/get_mibs.sh
-RUN cd /root/tgmanage/ && tools/get_mibs.sh
-RUN apt-get -y install apache2
RUN sed -i 's/Listen 80/Listen 8080/g' /etc/apache2/ports.conf
RUN a2dissite 000-default
-RUN cd /root/tgmanage/ && git pull
-RUN ln -s /root/tgmanage/web/etc/apache2/nms.tg16.gathering.org.conf /etc/apache2/sites-enabled/
-RUN ln -s /root/tgmanage/web/etc/varnish/nms.vcl
+RUN ln -s /srv/tgmanage/web/etc/apache2/nms.tg16.gathering.org.conf /etc/apache2/sites-enabled/
+
RUN systemctl enable apache2
-RUN apt-get -y install varnish
+
+RUN rm /etc/varnish/default.vcl
+RUN ln -s /srv/tgmanage/web/etc/varnish/nms.vcl /etc/varnish/default.vcl
+RUN sed -i 's/6081/80/' /lib/systemd/system/varnish.service
+RUN echo 'demo:$apr1$IKrQYF6x$0zmRciLR7Clc2tEEosyHV.' > /srv/tgmanage/web/.htpasswd
+RUN a2enmod cgi
RUN systemctl enable varnish