Compare commits

...

9 Commits

Author SHA1 Message Date
giomba 82697b4219 updated port for gestionaledb 2020-12-11 21:43:40 +01:00
giomba ae6c0ba2e5 database gestionale dockerizzato 2020-12-11 21:34:32 +01:00
giomba 87f0c6e7fd gitea container: restart always, unless stopped 2020-12-08 22:52:51 +01:00
giomba 6b0b33672f mini webserver, always useful
for example, use it to serve /pubblici archive
2020-12-08 21:08:12 +01:00
giomba f0577d015f cron fix for tgbot docker image 2020-12-06 17:45:29 +01:00
giomba 98c9d46cca fixed minor errors 2020-12-05 23:28:08 +01:00
giomba 2f644a0b51 golem telegram bot dockerized 2020-12-05 22:47:55 +01:00
giomba 9ed12c4ad2 rimozione limite, necessaria con nuove versioni di mysql
L'opzione disabilita il limite CPU del container, ed è necessario perché
c'è un bug nelle ultime immagini docker di MySQL.
Sperabilmente, questa cosa va tolta alla prima occasione utile.
2020-12-03 20:38:59 +01:00
giomba 136d7a47a9 added docker-compose for nextcloud 2020-12-03 09:14:50 +01:00
11 changed files with 137 additions and 0 deletions

View File

@ -0,0 +1,13 @@
version: "3.3"
services:
gestionaledb:
image: mariadb:10.5.8
restart: unless-stopped
environment:
MYSQL_ROOT_PASSWORD: hpArhr9OtQT9ObPmHeuYQQEoGbQukKIcUlhLaYjYJBA
ports:
- "7004:3306"
volumes:
- "/srv/gestionaledb:/var/lib/mysql"
# - "/tmp/golem_gestionale_dump.sql:/docker-entrypoint-initdb.d/dump.sql"

View File

@ -2,6 +2,7 @@ version: "3.3"
services:
gitea:
image: gitea/gitea:latest
restart: unless-stopped
depends_on:
- db
volumes:
@ -11,6 +12,9 @@ services:
- "3022:22"
db:
image: mysql:8
restart: unless-stopped
cap_add:
- SYS_NICE
volumes:
- /srv/gitea/database:/var/lib/mysql
environment:

View File

@ -0,0 +1,22 @@
version: "2"
services:
nextcloud:
image: nextcloud:17.0.10
ports:
- 8000:80
depends_on:
- db
volumes:
- /srv/nextcloud/app:/var/www/html
restart: unless-stopped
db:
image: mariadb
restart: unless-stopped
volumes:
- /srv/nextcloud/db:/var/lib/mysql
environment:
- MYSQL_ROOT_PASSWORD=R78Tnmynd5MtdI5Nz03qw
- MYSQL_PASSWORD=R78Tnmynd5MtdI5Nz03qw
- MYSQL_DATABASE=nextcloud
- MYSQL_USER=nextcloud

View File

@ -0,0 +1,10 @@
version: "3.3"
services:
pubblici:
image: hub.docker.golem.linux.it/thttpd:latest
restart: unless-stopped
ports:
- "7003:80"
volumes:
- /srv/pubblici:/html

13
tgbot/000-default.conf Normal file
View File

@ -0,0 +1,13 @@
<VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www/html
<Directory /var/www/html>
Options -Indexes
</Directory>
ErrorLog /dev/stodut
CustomLog /dev/stdout combined
TransferLog /dev/stdout
</VirtualHost>

18
tgbot/Dockerfile Normal file
View File

@ -0,0 +1,18 @@
FROM php:7.4-apache
RUN apt-get update
RUN apt-get install -y git
RUN apt-get install -y libmemcached-dev zlib1g-dev && pecl install memcached-3.1.5 && docker-php-ext-enable memcached
RUN docker-php-ext-install calendar && docker-php-ext-configure calendar
RUN docker-php-ext-install mysqli
RUN cp /usr/local/etc/php/php.ini-development /usr/local/etc/php/php.ini
RUN apt-get install -y cron
RUN git clone --depth 1 --branch docker https://git.golem.linux.it/golem/golem-telegram-bot.git /var/www/html
COPY entrypoint.sh /
EXPOSE 80
CMD ["/entrypoint.sh"]

16
tgbot/README.md Normal file
View File

@ -0,0 +1,16 @@
# tgbot, a docker image for golem-telegram-bot
## Build
```
docker build --tag hub.docker.golem.linux.it/golem-telegram-bot:latest .
```
## Permissions
```
drwxrwxr-x root www-data /data
```
## Bot development
* mount golem-telegram-bot repository as volume under /var/www/html
* ```mv $PHP_INI_DIR/php.ini-development $PHP_INI_DIR/php.ini```
(this enables error loggin on docker stdout/stderr logs)

View File

@ -0,0 +1,16 @@
version: "3.3"
services:
tgbot:
image: hub.docker.golem.linux.it/golem-telegram-bot:latest
restart: unless-stopped
ports:
- "7002:80"
volumes:
- /home/giomba/workspace/golem/golem-telegram-bot:/var/www/html
- /srv/tgbot/data:/data
depends_on:
- memcached
memcached:
image: memcached:1.6.9

15
tgbot/docker-compose.yml Normal file
View File

@ -0,0 +1,15 @@
version: "3.3"
services:
tgbot:
image: hub.docker.golem.linux.it/golem-telegram-bot:latest
restart: unless-stopped
ports:
- "7002:80"
volumes:
- /srv/tgbot/data:/data
depends_on:
- memcached
memcached:
image: memcached:1.6.9

4
tgbot/entrypoint.sh Executable file
View File

@ -0,0 +1,4 @@
#!/bin/bash
service cron start
crontab -u www-data /var/www/html/tgbot.cron
apachectl -D FOREGROUND

6
thttpd/Dockerfile Normal file
View File

@ -0,0 +1,6 @@
FROM alpine:latest
RUN apk add thttpd
ENTRYPOINT ["thttpd", "-D", "-d", "/html"]