Hello,
Here is a steps that we follow for Production setup.
**Manual Installation : **
1. Install Pre-requisites
** Python 2.7**
** MariaDB 10+ ( entered password = root )**
** Nginx (for production)**
** Nodejs**
** Redis**
** wkhtmltopdf with patched Qt (for pdf generation)**
2. Install Bench
** Install bench as a non root user,**
** git clone GitHub - frappe/bench: CLI to manage Multi-tenant deployments for Frappe apps bench-repo**
** sudo pip install -e bench-repo**
3. Create a new bench
** The init command will create a bench directory with frappe framework installed. It will be setup for periodic backups and auto updates once a day.**
** bench init frappe-bench && cd frappe-bench (Following errors can be occured while running this command)**
Note: If you face error like OSerror:Permission Denied on ./cache/pip file then use this command {sudo chmod 777 /home/.cache/}. This remove Permission Denied Error.
Note: If you face {Command “python setup.py egg_info” failed with error code 1 in /tmp/pip-build-_F0_Pv/mysql-python/} error as well with above error then run following commands:
** 1) sudo easy_install pip**
** 2) sudo pip install pip --upgrade**
** 3) sudo pip install MySQL-python**
Above commands will install MySQLdb package. After that remove frappe-bench Directory and re-execute bench init frappe-bench && cd frappe-bench command.
4. Add apps
** The get-app command gets remote frappe apps from a remote git repository and installs it. Example: erpnext**
** bench get-app erpnext GitHub - frappe/erpnext: Free and Open Source Enterprise Resource Planning (ERP)**
5. Add site
** Frappe apps are run by frappe sites and you will have to create at least one site. The new-site command allows you to do that.**
** bench new-site ERPNext**
6. Install erpnext
** To install erpnext on your new site, use the bench install-app command**
** bench --site ERPNext install-app erpnext**
7. Run: {bench setup supervisor} and {bench setup nginx}
8. Bench start ( Then enter your server IP:8000 in browser URL).
Above Mention Steps Are successfully working for us on [amazon EC2 instance with ubuntu 16.04 EMI].
Regards,
Hardik Gadesha