Skip to content
Snippets Groups Projects
Commit d1b847ed authored by Michiel de Jong's avatar Michiel de Jong Committed by Pierre Ozoux
Browse files

adapt adding a domain instructions to 0.2 situation

parent 38b4c5f0
No related branches found
No related tags found
No related merge requests found
...@@ -31,15 +31,20 @@ Make sure you read [getting started](getting-started-as-a-hoster.md) first. ...@@ -31,15 +31,20 @@ Make sure you read [getting started](getting-started-as-a-hoster.md) first.
in real time, immediately when you click 'verify' in the StartSSL UI. If they forward the email the next day, then the token in real time, immediately when you click 'verify' in the StartSSL UI. If they forward the email the next day, then the token
will already have expired. will already have expired.
* If no, register it (at Namecheap or elsewhere). * If no, register it (at Namecheap or elsewhere).
* Decide which image to run as the user's main website software (in version 0.1 only 'nginx' is supported) * Decide which image to run as the user's main website software (in version 0.2, 'static', 'static-git', and 'wordpress' are supported)
* If you already have some content that should go on there, and which is compatible with the image you chose, * For the 'wordpress' image, all you need is the TLS certificate. Use the 'static-git' image if you already have some static
put it in a public git repository somewhere. content that should go on there, and which you can put in a public git repository somewhere.
* Unless there is already a TLS certificate at `./data/runtime/haproxy/example.com.pem` get one * Unless you already have a TLS certificate for example.com, get one
(from StartSSL or elswhere) for example.com and concatenate the certificate (from StartSSL or elsewhere), and concatenate the certificate
and its unencrypted private key into `indiehosters/user-data/example.com/tls.pem` and its unencrypted private key into one file.
* Make sure the TLS certificate is valid (use `scripts/check-cert.sh` for this). * Make sure the TLS certificate is valid (use `scripts/check-cert.sh` for this), and scp it to `/data/import/example.com/TLS/example.com.pem` on k3.
* Now run `deploy/add-site.sh k3 example.com ../hoster-data/TLS/example.com.pem nginx https://github.com/someone/example.com.git root`. * Now ssh into k3, and if for instance 'wordpress' is the image you chose, run:
It will make sure the server is in the correct state, and git pull and scp the user data and the
approved cert into place, start a container running the image requested, update haproxy config, and restart the haproxy container. systemctl enable wordpress@example.com
* Test the site using your /etc/hosts. You should see the data from the git repo on both http and https. systemctl start wordpress@example.com
* In case you're going for the 'static-git' repo, store the git url with the content in `/data/domains/example.com/static-git/GITURL`.
* In case you're going for the 'static' repo, store the html content under `/data/domains/example.com/static/www-content`.
* Test the site using your /etc/hosts. You should see the data from the git repo, or the static content, or a wordpress start page
on both http and https.
* Switch DNS and monitoring. * Switch DNS and monitoring.
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment