Mailtrain-org /mailtrain

Self hosted newsletter app

★ 5,752⑂ 706👁 111⑃ 426● 969▤ 2
JavaScriptGPL-3.0Created 2016-04-04
下载:Mailtrain v2 2021-06-09Mailtrain-2.20210609.0 ↓2.20210609.02021-06-09
+0
日增长
5,752
stars
706
forks
111
watchers
426
prs
969
issues
2
releases

README

Mailtrain v2

Mailtrain is a self hosted newsletter application built on Node.js (v14+) and MySQL (v8+) or MariaDB (v10+).

This is version 2 of Mailtrain. It mostly implements all features of v1 and add some more. It is a complete rewrite, so you will have to install it from scratch.

If you are upgrading from Mailtrain v1, backup the DB and use it for Mailtrain v2. Mailtrain v2 should be able to upgrade the DB to the new schema.

!

 Features

 Subscriber lists management
 List segmentation
 Custom fields
 Email templates (including MJML-based templates)
 Custom reports
 Automation (triggered and RSS campaigns)
 Multiple users with granular user permissions and flexible sharing
 Hierarchical namespaces for enterprise-level situations
 Builtin Zone-MTA (https://github.com/zone-eu/zone-mta) for close-to-zero setup of mail delivery

 Recommended minimal hardware Requirements
 2 vCPU
 4096 MB RAM


 Quick Start

 Preparation
Mailtrain creates three URL endpoints, which are referred to as "trusted", "sandbox" and "public". This allows Mailtrain
to guarantee security and avoid XSS attacks in the multi-user settings. The function of these three endpoints is as follows:
- trusted - This is the main endpoint for the UI that a logged-in user uses to manage lists, send campaigns, etc.
- sandbox - This is an endpoint not directly visible to a user. It is used to host WYSIWYG template editors.
- public - This is an endpoint for subscribers. It is used to host subscription management forms, files and archive.

The recommended deployment of Mailtrain would use 3 DNS entries that all points to the same IP address. For example as follows:
- lists.example.com - public endpoint (A record lists under example.com domain)
- mailtrain.example.com - trusted endpoint (CNAME record mailtrain under example.com domain that points to lists)
- sbox-mailtrain.example.com - sandbox endpoint (CNAME record sbox-mailtrain under example.com domain that points to lists)


 Installation on fresh CentOS 7 or Ubuntu 18.04 LTS (public website secured by SSL)

This will setup a publicly accessible Mailtrain instance. All endpoints (trusted, sandbox, public) will provide both HTTP (on port 80)
and HTTPS (on port 443). The HTTP ports just issue HTTP redirect to their HTTPS counterparts.

The script below will also acquire a valid certificate from Let's Encrypt.
If you are hosting Mailtrain on AWS or some other cloud provider, make sure that before running the installation
script you allow inbound connection to ports 80 (HTTP) and 443 (HTTPS).

Note, that this will automatically accept the Let's Encrypt's Terms of Service.
Thus, by running this script below, you agree with the Let's Encrypt's Terms of Service (https://letsencrypt.org/documents/LE-SA-v1.2-November-15-2017.pdf).



1. Login as root. (I had some problems running npm as root on CentOS 7 on AWS. This seems to be fixed by the seemingly extraneous su within sudo.)
    
    sudo su -
    

2. Install GIT

   For Centos 7 type:
  

Top issues

Latest release

Mailtrain v2 2021-06-09 v2.20210609.0 2021-06-09

Snapshot: 2026-11-16T09:23:14Z · Data license Apache-2.0 · JSON