@small-tech/https version 5.3.0 released
⢠Uses Auto Encrypt 4.1.1 (removes OCSP stapling support because Let]s Encrypt has removed OCSP support).
https://www.npmjs.com/package/@small-tech/https
This module is a drop in replacement for Node HTTPS module that automatically handles TLS certificate provisioning and renewal both at localhost (via Auto Encrypt Localhost¹) and at hostname (via Auto Encrypt with Letās Encrypt certificates²).
So, this is how you create a HTTPS server in Node.js that uses this module and automatically handles TLS certificate provisioning and renewal for you both at localhost (during development) and at hostname (during production):
```js
import https from '@small-tech/https'
const server = https.createServer((request, response) => {
response.end('Hello, world!')
})
server.listen(443, () => {
console.log(' š Server running at https://localhost.')
})
```
(Yes, thatās it! I wrote a metric shit-tonne of meticulously-tested code so you donāt have to.) :)
š” Note that the localhost certificate support via Auto Encrypt Localhost is 100% JavaScript and does NOT rely on an external binary like mkcert or certutil.
Needless to say, Kitten³ uses this module under the hood and itās a big part of why Domainā“ can deploy servers so easily that donāt require any day-to-day maintenance.
In case youāre wondering why Iām spending so much time releasing all these modules, itās because I believe in sharing every brick of the house Iām building so others can easily build different houses if they want to. Iām not saying that what Iām building with Kitten, Domain, and Placeāµ will be the end all be all of the Small Webā¶ (the peer-to-peer web). And I want others to be able to experiment by building their own tools without having to go through the grueling development process Iāve had to in the past six years to build basic infrastructure.
Enjoy!
š
¹ https://codeberg.org/small-tech/auto-encrypt-localhost
² https://codeberg.org/small-tech/auto-encrypt
³ https://kitten.small-web.org
ā“ https://codeberg.org/domain/app
āµ https://codeberg.org/place/app
ā¶ https://ar.al/2024/06/24/small-web-computer-science-colloquium-at-university-of-groningen/
#SmallWeb #SmallTech #AutoEncrypt #LetsEncrypt #localhost #TLS #SSL #HTTPS #Kitten #NodeJS #JavaScript #servers #web #dev #FOSS