add phplist

This commit is contained in:
kev 2022-02-15 17:21:47 +08:00
parent 72a70a274c
commit 6e1f07022e
4 changed files with 95 additions and 0 deletions

View File

@ -398,6 +398,7 @@ A collection of delicious docker recipes.
- [x] gabekangas/owncast
- [x] owncloud
- [x] dpage/pgadmin4
- [x] phplist/phplist
- [x] phpmyadmin
- [x] pihole/pihole
- [x] mcr.microsoft.com/playwright

24
phplist/README.md Normal file
View File

@ -0,0 +1,24 @@
phplist
=======
[phpList][1] is software for sending email newsletters, marketing campaigns and
announcements: you can send to millions of subscribers or just to a few
hundred. phpList is used via a web browser and installed on your server. For
more information see the [features page][2].
```bash
$ mkdir -p data/{mailhog,phplist/{images,plugins}}
$ vi data/phplist/config.php
$ chmod 777 data/{mailhog,phplist/{images,plugins}}
$ tree -F data/
├── mailhog/
└── phplist/
├── config.php
├── images/
└── plugins/
$ docker-compose up -d
$ curl http://127.0.0.1:8000/lists/admin/
```
[1]: https://www.phplist.org/
[2]: https://www.phplist.org/features/

View File

@ -0,0 +1,20 @@
<?php
/* https://github.com/phpList/phplist3/blob/master/public_html/lists/config/config.php */
$database_host = getenv('DB_HOST');
$database_name = getenv('DB_NAME');
$database_user = getenv('DB_USERNAME');
$database_password = getenv('DB_PASSWORD');
define('PHPMAILERHOST', getenv('SMTP_HOST') ?: 'localhost');
define('PHPMAILERPORT', intval(getenv('SMTP_PORT') ?: '25'));
define('PHPMAILER_SECURE', strtolower(getenv('SMTP_SECURE') ?: 'false') === 'true');
define('TEST', 0);
define('HASH_ALGO', 'sha256');
define('UPLOADIMAGES_DIR','images');
define('MANUALLY_PROCESS_BOUNCES',1);
define('MANUALLY_PROCESS_QUEUE',0);
define('PHPMAILER_SECURE',0);
define('CHECK_REFERRER',false);

View File

@ -0,0 +1,50 @@
version: "3.8"
services:
phplist:
image: phplist/phplist
ports:
- "8000:80"
volumes:
- ./data/phplist/config.php:/var/www/phpList3/config.php
- ./data/phplist/images:/var/www/phpList3/public_html/images
- ./data/phplist/plugins:/var/www/phpList3/public_html/lists/admin/plugins
environment:
DB_HOST: mysql
DB_NAME: phplist
DB_USERNAME: phplist
DB_PASSWORD: phplist
ADMIN_NAME: admin
ADMIN_PASSWORD: admin
ADMIN_EMAIL: admin@gmail.com
SMTP_HOST: mailhog
SMTP_PORT: 1025
SMTP_SECURE: false
depends_on:
- mysql
- mailhog
restart: unless-stopped
mailhog:
image: mailhog/mailhog
ports:
- "1025:1025"
- "8025:8025"
volumes:
- ./data/mailhog:/data
environment:
MH_STORAGE: maildir
MH_MAILDIR_PATH: /data
restart: unless-stopped
mysql:
image: mariadb:10
volumes:
- ./data/mysql:/var/lib/mysql
environment:
MYSQL_ROOT_PASSWORD: root
MYSQL_DATABASE: phplist
MYSQL_USER: phplist
MYSQL_PASSWORD: phplist
restart: unless-stopped