Skip to content

Commit d080156

Browse files
Add files via upload
Added initial files.
1 parent d895f07 commit d080156

File tree

4 files changed

+92
-0
lines changed

4 files changed

+92
-0
lines changed

Dockerfile

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
FROM ubuntu:latest
2+
MAINTAINER Montala Ltd
3+
ENV DEBIAN_FRONTEND="noninteractive"
4+
RUN apt-get update && apt-get install -y \
5+
nano \
6+
imagemagick \
7+
apache2 \
8+
subversion \
9+
ghostscript \
10+
antiword \
11+
poppler-utils \
12+
libimage-exiftool-perl \
13+
cron \
14+
postfix \
15+
wget \
16+
php \
17+
php-apcu \
18+
php-curl \
19+
php-dev \
20+
php-gd \
21+
php-intl \
22+
php-mysqlnd \
23+
php-mbstring \
24+
php-zip \
25+
libapache2-mod-php \
26+
ffmpeg \
27+
libopencv-dev \
28+
python3-opencv \
29+
python3 \
30+
python3-pip \
31+
&& rm -rf /var/lib/apt/lists/*
32+
RUN sed -i -e "s/upload_max_filesize\s*=\s*2M/upload_max_filesize = 100M/g" /etc/php/8.3/apache2/php.ini
33+
RUN sed -i -e "s/post_max_size\s*=\s*8M/post_max_size = 100M/g" /etc/php/8.3/apache2/php.ini
34+
RUN sed -i -e "s/max_execution_time\s*=\s*30/max_execution_time = 300/g" /etc/php/8.3/apache2/php.ini
35+
RUN sed -i -e "s/memory_limit\s*=\s*128M/memory_limit = 1G/g" /etc/php/8.3/apache2/php.ini
36+
37+
RUN printf '<Directory /var/www/>\n\
38+
\tOptions FollowSymLinks\n\
39+
</Directory>\n'\
40+
>> /etc/apache2/sites-enabled/000-default.conf
41+
42+
ADD cronjob /etc/cron.daily/resourcespace
43+
44+
WORKDIR /var/www/html
45+
RUN rm index.html
46+
RUN svn co -q https://svn.resourcespace.com/svn/rs/releases/10.5 .
47+
RUN mkdir filestore
48+
RUN chmod 777 filestore
49+
RUN chmod -R 777 include/
50+
CMD apachectl -D FOREGROUND

cronjob

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
#!/bin/sh
2+
su -s /bin/sh -c 'cd /var/www/html/pages/tools && nice -n 19 ionice -c2 -n7 php cron_copy_hitcount.php' www-data

db.env

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
MYSQL_PASSWORD=change-me
2+
MYSQL_ROOT_PASSWORD=change-me
3+
MYSQL_DATABASE=resourcespace
4+
MYSQL_USER=resourcespace_rw

docker-compose.yaml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
services:
2+
resourcespace:
3+
build: .
4+
container_name: resourcespace
5+
restart: unless-stopped
6+
depends_on:
7+
- mariadb
8+
volumes:
9+
- include:/var/www/html/include
10+
- filestore:/var/www/html/filestore
11+
- ./testdir:/srv/storage/testdir
12+
networks:
13+
- frontend
14+
- backend
15+
ports:
16+
- "80:80"
17+
18+
mariadb:
19+
image: mariadb
20+
container_name: mariadb
21+
restart: unless-stopped
22+
env_file:
23+
- db.env
24+
volumes:
25+
- mariadb:/var/lib/mysql
26+
networks:
27+
- backend
28+
29+
networks:
30+
frontend:
31+
backend:
32+
33+
volumes:
34+
mariadb:
35+
include:
36+
filestore:

0 commit comments

Comments
 (0)