4 ms·
How do people in general test their https during development? I've never done it but will for my current project, but am dreading it. I was thinking of Docker
by rrosen326 7y ago
How do people in general test their https during development? I've never done it but will for my current project, but am dreading it. I was thinking of Docker or Vagrant. Or maybe this localdots.
This must be a solved problem. How do you all do it?
- benologist 7y agoI liked using a service called serveo that just uses SSH but recently it went offline so I am back to using either ngrok or localtunnel. These let a remotely-hosted HTTPS domain point to a local port on your computer or server you just request a URL pointing to local port X. http://serveo.net http://serveo.net https://ngrok.io https://ngrok.io https://localtunnel.me https://localtunnel.me These are command-line tools with NodeJS libraries, you can run them parallel to your project or internally. I am using the NodeJS libraries to create a URL when my tests start. Stripe recently added webhook endpoints to their API so you can also create webhooks bound to whatever URL you are assigned.
- checker 7y agoYeah containers are the way to go. Run a sidecar proxy such as Envoy and you can offload the TLS at the proxy so you don't have to write any TLS code yourself.
- scient 7y agoNot sure what the complexity here would be, you can set up nginx with some simple DNS (or even hosts file) stuff and run HTTP locally. Something like puma-dev does this pretty painlessly out of the box too. Running a container just for that seems frankly overkill.
- 4lun 7y agoSelf signed certificate (can generate against any domain I need) or utilising a dev specific hostname against a domain I already own, e.g. dev.mydomain.org, so that I can get a certificate most browsers trust out of the box (e.g. via letsencrypt). Then typically I just pass through nginx to HTTP locally, which is typically what I do in prod so the config isn't new to me