Frappe Installation from Scratch¶
Installing Dependencies¶
Create Ubuntu Image
SSH onto machine as root
- Create ubuntu user with
adduser ubuntu
- Make sure ubuntu user has sudo visudo below the root line
ubuntu ALL=(ALL:ALL) ALL
Update apt sudo apt-get -y update
- Install git and redis
sudo apt install -y git python-dev redis-server
Install MariaDB & set Root Password
sudo apt-get install software-properties-common sudo apt-key adv --recv-keys --keyserver hkp://keyserver.ubuntu.com:80 0xF1656F24C74CD1D8 sudo add-apt-repository 'deb [arch=amd64,i386,ppc64el] http://ftp.ubuntu-tw.org/mirror/mariadb/repo/10.3/ubuntu xenial main' sudo apt-get update sudo apt-get install mariadb-server-10.3
Install MySQL Client
sudo apt-get install libmysqlclient-dev
Update MySQL config sudo nano /etc/mysql/my.cnf
[mysqld] character-set-client-handshake = FALSE character-set-server = utf8mb4 collation-server = utf8mb4_unicode_ci [mysql] default-character-set = utf8mb4
Restart MySQL & check if its working fine
sudo service mysql restart mysql -uroot -p
Install NodeJS curl -sL https://deb.nodesource.com/setup_10.x | sudo -E bash - and sudo apt-get install -y nodejs
Install yarn curl -o- -L https://yarnpkg.com/install.sh | bash
Install emacs sudo apt-get install -y emacs
Install wkhtmltopdf sudo apt-get install -y xvfb libfontconfig wkhtmltopdf
Install pip sudo apt-get install -y python3-pip
Install bench¶
Create Installs directory mkdir ~/Installs && cd ~/Installs
Clone bench repo git clone https://github.com/frappe/bench bench-repo
Install bench cd bench-repo && sudo python3 setup.py install
Initialize Frappe Bench bench init frappe-bench –frappe-branch master && cd frappe-bench
Create new application¶
Make sure to run ./env/bin/pip3 install werkzeug==0.16.0
Create a new app: bench new-app library_management
Create a site & install our app
bench new-site site1.local bench --site site1.local install-app library_management