One other day on Nostr, one other app!
Today Iโll present you a new self-hosted Nostr blog web application recently released on github by dtonon), Oracolo:
https://github.com/dtonon/oracolo
Oracolo is a minimalist blog powered by Nostr, that consists of a single html file, weighing only ~140Kb. You can use whatever Nostr client that supports long format (habla.news, yakihonne, highlighter.com, etc ) to write your posts, and your personal blog is automatically updated.
It works also without a web server; for example you can send it via email as a business card.Oracolo fetches Nostr data, builds the page, execute the JavaScript code and displays article on clean and sobr blog (a Dark theme would be awesome ๐).
Blog articles are nostr events you published or will publish on Nostr relays through long notes applications like the ones quoted above.
Donโt forget to use a NIP07 web browser extensions to login on those websites. Old time where we were forced to fill our nsec key is nearly over!
For the hurry ones of you, you can find here the Oracolo demo with my Nostr long notes article. It will include this one when Iโll publish it on Nostr!
https://oracolo.fractalized.net/
How to self-host Oracolo?
You can build the application locally or use a docker compose stack to run it (or any other method). I just build a docker compose stack with Traefik and an Oracolo docker image to let you quickly run it.
The oracolo-docker github repo is available here:
https://github.com/PastaGringo/oracolo-docker
PS: donโt freak out about the commits number, oracolo has been the lucky one to let me practrice docker image CI/CD build/push with Forgejo, that went well but it took me a while before finding how to make Forgejo runner dood work ๐). Please ping me on Nostr if you are interested by an article on this topic!
This repo is a mirror from my new Forgejo git instance where the code has been originaly published and will be updated if needed (I think it will):
https://git.fractalized.net/PastaGringo/oracolo-docker
Here is how to do it.
First, you need to create an A DNS record into your domain.tld zone. You can create a A with โoracoloโ .domain.tld or โ*โ .domain.tld. The second one will allow traefik to generate all the future subdomain.domain.tld without having to create them in advance. You can verify DNS records with the website https://dnschecker.org.
Clone the oracolo-docker repository:
git clone https://git.fractalized.net/PastaGringo/oracolo-docker.git cd oracolo-docker
- Rename the .env.example file:
mv .env.example .env
- Modify and update your .env file with your own infos:
# Let's Encrypt email used to generate the SSL certificate LETSENCRYPT_EMAIL= # domain for oracolo. Ex: oracolo.fractalized.net ORACOLO_DOMAIN= # Npub author at "npub" format, not HEX. NPUB= # Relays where Oracolo will retrieve the Nostr events. # Ex: "wss://nostr.fractalized.net, wss://rnostr.fractalized.net" RELAYS= # Number of blog article with an thumbnail. Ex: 4 TOP_NOTES_NB=
- Compose Oracolo:
docker compose up -d && docker compose logs -f oracolo traefik
[+] Running 2/0 โ Container traefik Running 0.0s โ Container oracolo Running 0.0s WARN[0000] /home/pastadmin/DEV/FORGEJO/PLAY/oracolo-docker/docker-compose.yml: `version` is obsolete traefik | 2024-05-28T19:24:18Z INF Traefik version 3.0.0 built on 2024-04-29T14:25:59Z version=3.0.0 oracolo | oracolo | ___ ____ ____ __ ___ _ ___ oracolo | / \ | \ / | / ] / \ | | / \ oracolo | | || D )| o | / / | || | | | oracolo | | O || / | |/ / | O || |___ | O | oracolo | | || \ | _ / \_ | || || | oracolo | | || . \| | \ || || || | oracolo | \___/ |__|\_||__|__|\____| \___/ |_____| \___/ oracolo | oracolo | Oracolo dtonon's repo: https://github.com/dtonon/oracolo oracolo | oracolo | โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ oracolo | โ Docker Compose Env Vars โคต๏ธ โ oracolo | โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ oracolo | oracolo | NPUB : npub1ky4kxtyg0uxgw8g5p5mmedh8c8s6sqny6zmaaqj44gv4rk0plaus3m4fd2 oracolo | RELAYS : wss://nostr.fractalized.net, wss://rnostr.fractalized.net oracolo | TOP_NOTES_NB : 4 oracolo | oracolo | โญโโโโโโโโโโโโโโโโโโโโโโโโโโโโฎ oracolo | โ Configuring Oracolo... โคต๏ธ โ oracolo | โฐโโโโโโโโโโโโโโโโโโโโโโโโโโโโฏ oracolo | oracolo | > Updating npub key with npub1ky4kxtyg0uxgw8g5p5mmedh8c8s6sqny6zmaaqj44gv4rk0plaus3m4fd2... โ oracolo | > Updating nostr relays with wss://nostr.fractalized.net, wss://rnostr.fractalized.net... โ oracolo | > Updating TOP_NOTE with value 4... โ oracolo | oracolo | โญโโโโโโโโโโโโโโโโโโโโโโโโฎ oracolo | โ Installing Oracolo โคต๏ธ โ oracolo | โฐโโโโโโโโโโโโโโโโโโโโโโโโฏ oracolo | oracolo | added 122 packages, and audited 123 packages in 8s oracolo | oracolo | 20 packages are looking for funding oracolo | run `npm fund` for details oracolo | oracolo | found 0 vulnerabilities oracolo | npm notice oracolo | npm notice New minor version of npm available! 10.7.0 -> 10.8.0 oracolo | npm notice Changelog: https://github.com/npm/cli/releases/tag/v10.8.0 oracolo | npm notice To update run: npm install -g npm@10.8.0 oracolo | npm notice oracolo | oracolo | >>> done โ oracolo | oracolo | โญโโโโโโโโโโโโโโโโโโโโโโฎ oracolo | โ Building Oracolo โคต๏ธ โ oracolo | โฐโโโโโโโโโโโโโโโโโโโโโโฏ oracolo | oracolo | > oracolo@0.0.0 build oracolo | > vite build oracolo | oracolo | 7:32:49 PM [vite-plugin-svelte] WARNING: The following packages have a svelte field in their package.json but no exports condition for svelte. oracolo | oracolo | @splidejs/svelte-splide@0.2.9 oracolo | @splidejs/splide@4.1.4 oracolo | oracolo | Please see https://github.com/sveltejs/vite-plugin-svelte/blob/main/docs/faq.md#missing-exports-condition for details. oracolo | vite v5.2.11 building for production... oracolo | transforming... oracolo | โ 84 modules transformed. oracolo | rendering chunks... oracolo | oracolo | oracolo | Inlining: index-C6McxHm7.js oracolo | Inlining: style-DubfL5gy.css oracolo | computing gzip size... oracolo | dist/index.html 233.15 kB โ gzip: 82.41 kB oracolo | โ built in 7.08s oracolo | oracolo | >>> done โ oracolo | oracolo | > Copying Oracolo built index.html to nginx usr/share/nginx/html... โ oracolo | oracolo | โญโโโโโโโโโโโโโโโโโโโโโโโโโฎ oracolo | โ Configuring Nginx... โคต๏ธ โ oracolo | โฐโโโโโโโโโโโโโโโโโโโโโโโโโฏ oracolo | oracolo | > Copying default nginx.conf file... โ oracolo | oracolo | โญโโโโโโโโโโโโโโโโโโโโโโโฎ oracolo | โ Starting Nginx... ๐ โ oracolo | โฐโโโโโโโโโโโโโโโโโโโโโโโฏ oracolo |
If you donโt have any issue with the Traefik container, Oracolo should be live! ๐ฅ
You can now access it by going to the ORACOLO_DOMAIN URL configured into the .env file.
Have a good day!
Donโt hesisate to follow dtonon) on Nostr to follow-up the future updates โก๐ฅ
See you soon in another Fractalized story!
PastaGringo ๐คโก
http://localhost:5173//a/naddr1qvzqqqr4gupzpvftvvkgslcvsuw3grfhhjmw0s0p4qpxf59hm6p9t2se28v7rlmeqqxnzde3xcunywp3xv6nwvfjmgqha4