# Use the official Debian image as a base FROM debian:bullseye # Set environment variables # ENV DEBIAN_FRONTEND=noninteractive # Update the package list and install Apache2 and MariaDB RUN apt-get update && \ apt-get install -y apache2 apache2-dev && \ apt-get clean && \ a2dismod mpm_event && \ a2enmod mpm_prefork && \ # apt-get install -y libapache2-rewrite && \ a2enmod rewrite && \ apt-get install -y libapache2-mod-perl2 libperl-dev libapache2-reload-perl libapache2-request-perl libapache2-mod-apreq2 build-essential imagemagick libapreq2-3 libapache-dbi-perl libauthen-sasl-perl libauthen-passphrase-perl libcalendar-simple-perl libcrypt-blowfish-perl libcgi-pm-perl libcgi-session-perl libcgi-simple-perl libconfig-general-perl libdatetime-perl libdate-calc-perl libdate-manip-perl libdbi-perl libdbd-mysql-perl libemail-sender-perl libencode-perl libjson-perl libhtml-formattext-withlinks-andtables-perl libhtml-parser-perl libhtml-template-perl libhtml-template-compiled-perl libmime-tools-perl libsession-token-perl libtext-multimarkdown-perl libtext-unidecode-perl libtext-wikicreole-perl liburi-escape-xs-perl perlmagick sox libsox-fmt-all && \ a2enmod perl && \ service apache2 restart && \ cpan App::cpanminus && \ rm -rf /var/lib/apt/lists/* # RUN ["cpanm", "--force", "Image::Magick", "Image::Magick::Square" ] # RUN ["cpanm", "--force", "Apache2::Reload", "Apache2::Request", "Apache2::Upload", "Apache::DBI", "Authen::Passphrase", "Authen::Passphrase::BlowfishCrypt", "Calendar::Simple", "CGI", "CGI::Carp", "CGI::Cookie", "CGI::Session", "CGI::Simple", "Config::General", "Data::Dumper", "Date::Calc", "Date::Manip", "DateTime", "DBD::mysql", "DBI", "Digest::MD5", "Encode::Locale", "HTML::Entities", "HTML::FormatText", "HTML::Parse", "HTML::Template::Compiled", "HTML::Template::Compiled::Plugin::XMLEscape", "Image::Magick", "Image::Magick::Square", "JSON", "ModPerl::Util", "Session::Token", "Text::Diff::FormatedHtml", "Text::Markdown", "Text::WikiCreole", "URI::Escape" ] # Copy your website files to the Apache document root (optional) COPY . /var/www/html/. COPY ./install/apache2-sites/calcms.conf /etc/apache2/sites-enabled/ COPY ./website/agenda/config/config.cgi.off /var/www/html/website/config/config.cgi COPY ./website/agenda/config/config.cgi.off /var/www/html/website/agenda/config/config.cgi # Expose ports for Apache and MariaDB EXPOSE 80 # Start both Apache and MariaDB CMD service apache2 restart && \ tail -f /var/log/apache2/access.log