Monday, October 15, 2018

SSL sucks

Don't read this post unless you want to read about FAILs.

Trying to deploy a secure "developer in a box" domain is non trivial. Which also means that trying to deploy any kind of domain is also non-trivial. The challenge is the bootstrap which is also a "race condition" or a "chicken and the egg".

For example in my system I have a single public IP address. The router forwards ports 80, 443 and a few others to my traefic server. My traefic server allows my projects to register with traefic so that their various network requests are forwarded properly. However, since my traefic server is also version controlled in my private git repo and I cannot deploy traefic until my git server is also in place. And therefore the chicken and egg.

As for the SSL title... when you let your SSL certificate expire because it's too hard to remember what you had to do last time to renew and reload the certificate or that you've imposed too many guardrails in the organization in order to manage secrets that any sort of tweak requires a complete redeploy... or when using mechanical and mutually dependent chicken-eggs systems that it's too easy to lose control.

Here's the outline of my hyper developer domain in a box.

  1. create an account on a VPS service like digital ocean
  2. create a project
  3. register a DNS domain and configure your nameservers.
  4. create a gitlab instance (good luck configuring it. so that it's secure)
  5. configure gitlab including letsencrypt
  6. import the baseline traefik project so that [1] you have a known version rather than relying on release version numbers or public repos [2] consistent deploys
  7. create a console machine instance that would be used to deploy the swarm of instances.
  8. ...
OK, first FAIL. Git is famously difficult to deploy and gitlab does not make that much easier especially since we are talking about the bootstrap and console. Starting again... this time instead of deploying a bootstrap git repo and a separate console I'm going to deploy a small container OS like rancher, install docker-machine and docker-compose then install fossil-scm.

  • Add support for Docker. Just install docker and type "sudo docker run -d -p 8080:8080 nijtmans/fossil" to get it running.
Another FAIL. RancherOS does not install anything less than 4GB of ram. Or at least not that I can be certain of. So this time I'm going to try fedora... I like CoreOS, however, releases have been slow and now that RedHat owns them it's tough to know what it's future is.

And another FAIL: FedoraAtomic 26 uses stock docker 1.13 and the latest docker release is 1.18++. Even though RancherOS has some heavy ram requirements at least it stock with the latest version. Now as I'm trying to upgrade my atomic host Atomic failed.

INSTALL DOCKER-MACHINE (link)

another FAIL -- 'curl' does not exist on the base RancherOS... you have to convert the console to alpine and then apk add curl... and CoreOS does not permit writing to the /usr partition. So you gotta change it to /opt and add that to the path. UGH And on CoreOS forget any plan to add auto-completion.

Now that fossil is running on my console machine and I've installed docker-compose and docker-machine... I've also updated the admin password on fossil. At this point I've gone back and deleted the RancherOS instance because it's 2GB requirement is 2x the 1GB for CoreOS. At this point this machine is meant to be basically idle although I need to add my swarm tools and traefik.

And another FAIL -- the fossil container is over 2 years old and does not provide any information on hosted persistence and no link to the Dockerfile.


No comments:

Post a Comment

static site generators

Static site generators are pretty cool. Granted they are an oversimplification of the java/json/xml/xslt site manifestation from the olden d...