added listmonk
This commit is contained in:
40
listmonk/listmonk.install
Normal file
40
listmonk/listmonk.install
Normal file
@@ -0,0 +1,40 @@
|
||||
post_install() {
|
||||
cat <<- EOF
|
||||
WARNING: Installed with default password!
|
||||
|
||||
To setup:
|
||||
|
||||
Setup PostgreSQL with credentials and a database:
|
||||
|
||||
\$ sudo -u postgres psql
|
||||
postgres=# CREATE USER listmonk WITH PASSWORD '<your_password>';
|
||||
postgres=# CREATE DATABASE listmonk;
|
||||
postgres=# GRANT ALL PRIVILEGES ON DATABASE listmonk TO listmonk;
|
||||
postgres=# \\q
|
||||
|
||||
Then edit /etc/listmonk/config.toml with your new database credentials.
|
||||
Also be sure to change the admin password from the defalut.
|
||||
|
||||
Run manually once to setup the database tables:
|
||||
|
||||
\$ sudo -u listmonk listmonk --config /etc/listmonk/config.toml --install
|
||||
|
||||
Lastly you can enable the system service:
|
||||
|
||||
\$ sudo systemctl enable --now listmonk
|
||||
EOF
|
||||
}
|
||||
|
||||
post_upgrade() {
|
||||
cat <<- EOF
|
||||
To update the Listmonk database format, first backup your data, then run:
|
||||
|
||||
\$ sudo -u listmonk listmonk --config /etc/listmonk/config.toml --upgrade
|
||||
|
||||
Then restart the service:
|
||||
|
||||
\$ sudo systemctl restart listmonk
|
||||
EOF
|
||||
}
|
||||
|
||||
# vim: : ts=4 sw=4 noet
|
Reference in New Issue
Block a user