Setup everything via ansible
I did the rest of the install manually, here's the things that would need ansibleising.
This assumes:
- database/user/pass:
erpnext/erpnext/erpnext
- site:
erpnext.webarchitects.coop
database and user
Create a database user with password, and a database, I ran:
create user erpnext@localhost identified with 'mysql_native_password';
SET PASSWORD FOR 'erpnext'@'localhost' = PASSWORD('erpnext');
GRANT ALL PRIVILEGES ON *.* TO 'erpnext'@'localhost' IDENTIFIED VIA mysql_native_password WITH GRANT OPTION
create database erpnext;
mariadb configuration
Add /etc/mysql/mariadb.conf.d/80-erpnext.cnf
with these contents:
[mysqld]
innodb-file-format=barracuda
innodb-file-per-table=1
innodb-large-prefix=1
character-set-client-handshake = FALSE
character-set-server = utf8mb4
collation-server = utf8mb4_unicode_ci
[mysql]
default-character-set = utf8mb4
new-site
Run in /var/www/erpnext/frappe-bench
:
bench new-site --mariadb-root-username erpnext --mariadb-root-password erpnext erpnext.webarchitects.coop
bench get-app erpnext https://github.com/frappe/erpnext
bench --site erpnext.webarchitects.coop install-app erpnext
supervisor
It comes with a supervisord setup, seems a reasonable option. First install apt install supervisor
, then you can generate a config with:
bench setup supervisor
Then put it in place:
ln -s /var/www/erpnext/frappe-bench/config/supervisor.conf /etc/supervisor/conf.d/frappe-bench.conf
And restart:
systemctl restart supervisor
nginx
See !1 (merged)