Skip to content

Commit

Permalink
Update Dockerfile
Browse files Browse the repository at this point in the history
Back to original
  • Loading branch information
dkrizic authored Oct 8, 2023
1 parent 00e35b7 commit 00ed46d
Showing 1 changed file with 7 additions and 7 deletions.
14 changes: 7 additions & 7 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
# Docker container for Observium Community Edition

FROM ubuntu:22.04
FROM ubuntu:20.04

LABEL maintainer "[email protected]"
LABEL version="1.0"
Expand All @@ -21,9 +21,10 @@ ENV OBSERVIUM_DB_PASS=$OBSERVIUM_DB_PASS
ENV OBSERVIUM_DB_NAME=$OBSERVIUM_DB_NAME

# install prerequisites and cleanup
RUN apt-get update && apt-get install -y libapache2-mod-php8.1 php8.1-cli php8.1-mysql php8.1-gd php8.1-bcmath php8.1-mbstring \
php8.1-opcache php8.1-curl php-apcu php-pear snmp fping mysql-server mysql-client rrdtool subversion \
whois mtr-tiny ipmitool graphviz imagemagick apache2 python3-mysqldb python3-pymysql python-is-python3 wget curl supervisor cron unzip
RUN apt-get update && apt-get install -y libapache2-mod-php7.4 php7.4-cli php7.4-mysql php7.4-mysqli php7.4-gd php7.4-json \
php-pear snmp fping mysql-client python3-mysqldb rrdtool subversion whois mtr-tiny \
ipmitool graphviz imagemagick apache2 python3-pymysql python-is-python3 \
cron locales supervisor wget curl
RUN rm -f /etc/apache2/sites-available/* && \
rm -f /etc/cron.d/* && \
rm -f /etc/cron.hourly/* && \
Expand All @@ -37,7 +38,7 @@ RUN rm -f /etc/apache2/sites-available/* && \
mkdir /var/log/apache2

# set locale
#RUN locale-gen en_US.UTF-8
RUN locale-gen en_US.UTF-8

# install observium package
RUN mkdir -p /opt/observium /opt/observium/logs /opt/observium/rrd && \
Expand Down Expand Up @@ -72,7 +73,7 @@ RUN phpenmod mcrypt
COPY observium-apache24 /etc/apache2/sites-available/000-default.conf
RUN a2dismod mpm_event && \
a2enmod mpm_prefork && \
a2enmod php8.1 && \
a2enmod php7.4 && \
a2enmod rewrite && \
chmod 644 /etc/apache2/sites-available/000-default.conf && \
sed -i -e "s/\${APACHE_LOG_DIR}\//\/opt\/observium\/logs\/apache2-/g" /etc/apache2/apache2.conf
Expand All @@ -95,4 +96,3 @@ EXPOSE 80/tcp

# set volumes
VOLUME ["/opt/observium/logs","/opt/observium/rrd"]

0 comments on commit 00ed46d

Please sign in to comment.