next.js, nginx, reverse-proxy, ssl
$ sudo apt-get update
$ sudo apt-get install nginx letsencrypt
/** | |
* Create a web friendly URL slug from a string. | |
* | |
* Requires XRegExp (http://xregexp.com) with unicode add-ons for UTF-8 support. | |
* | |
* Although supported, transliteration is discouraged because | |
* 1) most web browsers support UTF-8 characters in URLs | |
* 2) transliteration causes a loss of information | |
* | |
* @author Sean Murphy <sean@iamseanmurphy.com> |
This example uses curl. You can use any other means of making http requests. Responses are in JSON format.
% curl https://demo.frappecloud.com/api/method/login -XPOST \-d "usr=demo%40frappecloud.com&pwd=demo" -c frappe.cookie
{"message":"Logged In","full_name":"Demo User"}
# Run as your work user | |
# Make sure you are not using root | |
# Disable sudo timeout | |
sudo sh -c 'echo "\nDefaults timestamp_timeout=-1">>/etc/sudoers' | |
# Projects root directory | |
ODOO_PROJECTS_DIR="projects" | |
# Odoo version | |
ODOO_VERSION="8.0" |
set daemon 600 #in seconds | |
set logfile /home/webapp/log/monit.log | |
check process rabbit with pidfile /var/run/odoo.pid | |
start program = "/etc/init.d/odoo start" | |
stop program = "/etc/init.d/odoo stop" |
Apache Configuration:
<VirtualHost *:80>
ServerName blah.com
DirectoryIndex index.html index.php
ProxyRequests On
ProxyPreserveHost On
ProxyVia full