From 3abb247c36205281afe0add8b562b700748d3f28 Mon Sep 17 00:00:00 2001 From: AJ ONeal Date: Wed, 2 Aug 2017 15:58:38 -0600 Subject: [PATCH] Update INSTALL.md --- INSTALL.md | 75 ++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 75 insertions(+) diff --git a/INSTALL.md b/INSTALL.md index 9f301f1..28b2d6b 100644 --- a/INSTALL.md +++ b/INSTALL.md @@ -33,6 +33,14 @@ rest of this tutorial: my_domain=example.com ``` +You can purchase a domain with daplie tools + +``` +npm install -g git+https://git.daplie.com/Daplie/daplie-tools.git + +daplie domains:search -n $my_domain +``` + Subodmains ---------- @@ -52,6 +60,73 @@ api.example.com assets.example.com ``` +The domains can be setup through the Daplie Desktop App or with daplie-tools + +Replace `foodevice` with whatever you like to call this device + +```bash +my_device=$(hostname) # i.e. foodevice + +# curl https://api.oauth3.org/api/tunnel@oauth3.org/checkip +my_address=127.0.0.1 + +# set device address and attach primary domain +daplie devices:attach -d $my_device -n $my_domain -a $my_address + +# attach all other domains with same device/address +daplie devices:attach -d foodevice -n www.example.com +daplie devices:attach -d foodevice -n api.example.com +daplie devices:attach -d foodevice -n assets.example.com +daplie devices:attach -d foodevice -n cloud.example.com +daplie devices:attach -d foodevice -n api.cloud.example.com +``` + +Initialization +-------------- + +needs to know its primary domain + +``` +POST https://api./api/walnut@daplie.com/init + +{ "domain": "" } +``` + + +Example `/etc/goldilocks/goldilocks.yml`: +```yml +tls: + email: domains@example.com + servernames: + - example.com + - www.example.com + - api.example.com + - assets.example.com + - cloud.example.com + - api.cloud.example.com + +http: + trust_proxy: true + modules: + - name: proxy + domains: + - '*' + address: '127.0.0.1:3000' +``` + +Resetting the Initialization +---------------------------- + +Once you run the app the initialization files will appear in these locations + +``` +/srv/walnut/var/com.daplie.walnut.config.sqlite3 +/srv/walnut/config//config.json +``` + +Deleting those files and restarting walnut will reset it to its bootstrap state. + + Basic Walnut Install --------------------