2016-03-28 23:50:36 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
2016-03-29 01:12:35 +00:00
|
|
|
sudo mkdir -p /srv/walnut/{certs,core,letsencrypt,lib}
|
2016-03-28 23:50:36 +00:00
|
|
|
sudo mkdir -p /srv/walnut/packages/{api,pages,services}
|
|
|
|
sudo chown -R $(whoami):$(whoami) /srv/walnut
|
|
|
|
|
|
|
|
#git clone git@github.com:Daplie/walnut.git
|
|
|
|
git clone https://github.com/Daplie/walnut.git /srv/walnut/core
|
|
|
|
|
|
|
|
pushd /srv/walnut/core
|
|
|
|
npm install
|
2016-03-28 23:51:32 +00:00
|
|
|
sudo rsync -av /srv/walnut/core/etc/init/walnut.conf /etc/init/walnut.conf
|
2016-03-29 01:12:35 +00:00
|
|
|
rsync -av /srv/walnut/core/etc/letsencrypt/ /srv/walnut/certs/
|
2016-03-28 23:50:36 +00:00
|
|
|
|
|
|
|
popd
|
|
|
|
mv /srv/walnut/core/node_modules /srv/walnut
|
|
|
|
|
|
|
|
sudo service walnut stop
|
|
|
|
sudo service walnut start
|