The most basic possible project for testing a Web Server using Node.js http-server.
The purpose of this repo is to test deployment with the simplest possible node.js app.
git clone [email protected]:nelsonic/hello-world-node-http-server.git && cd hello-world-node-http-server
npm start
Visit: http://localhost:3000 in your web browser.
You should see:
That's it!
This app was/is used to test our "ACID" deployment process. see: https://github.com/dwyl/learn-devops/issues/24
See: branch.sh
e.g: 42
create the Dokku app for the issue number:
ssh [email protected] dokku apps:create <appname>
e.g:
ssh [email protected] dokku apps:create $(sh ./issue.sh)
Or for the master
:
ssh [email protected] dokku apps:create hello-world-node
git remote add dokku [email protected]:$(sh ./issue.sh)
Delete the remote
git remote rm dokku
Master:
git remote add dokku [email protected]:hello-world-node
git push dokku $(sh ./branch.sh):master
Add the wildcard Cert to the Newly Created App
ssh [email protected] "sudo dokku certs:add $(sh ./issue.sh) < /etc/letsencrypt/live/ademo.app/certs.tar"
ssh [email protected] "sudo dokku certs:add hello-world-node < /etc/letsencrypt/live/ademo.app/certs.tar"
nginx
ssh [email protected] "nginx -t && nginx -s reload"
If you are using Dokku to deploy your app, run the following command on your server instance:
ssh [email protected]
cat ~/.ssh/id_rsa.pub | sudo sshcommand acl-add dokku root
sh .bin/docker-exited.sh