From 7d1ff194d90af45bc51f0ea93420d98522fbc1ad Mon Sep 17 00:00:00 2001 From: Aljaz Ceru Date: Thu, 6 Nov 2025 12:00:29 +0100 Subject: [PATCH] fixing ai crap --- content/posts/a-true-believer.md | 5 +- content/posts/accessing-llm-through-cli.md | 99 +++++++++++++++---- content/posts/awesome-nostr.md | 29 ++++++ content/posts/cryptoanarchy.md | 9 +- content/posts/github-no-more.md | 8 +- .../how-to-post-videos-everyone-can-watch.md | 19 ++-- content/posts/i-build-timeconvert-org.md | 11 ++- content/posts/the-directory-guy.md | 28 ++++-- ...ory-of-the-greatest-crypto-project-ever.md | 13 ++- content/posts/wordpress-docker-setup.md | 76 ++++++++++++-- 10 files changed, 223 insertions(+), 74 deletions(-) create mode 100644 content/posts/awesome-nostr.md diff --git a/content/posts/a-true-believer.md b/content/posts/a-true-believer.md index e963e02..634661b 100644 --- a/content/posts/a-true-believer.md +++ b/content/posts/a-true-believer.md @@ -5,7 +5,4 @@ slug: "a-true-believer" tags: ["freedom", "cypherpunk"] draft: false --- - -The piece describes an idealized figure working tirelessly on liberation-focused technologies. This individual operates under severe constraints, using salvaged materials and working relentlessly toward their vision. The author emphasizes the builder's unwavering commitment, noting that "he builds what he knows, what inspires him" and remains focused on their cause rather than conventional work schedules or comfort. - -The narrative portrays someone deeply dedicated to their mission—building continues "when the enemy is gone"—and someone who views their work as their entire existence rather than a job with fixed hours. The characterization emphasizes resilience and singular focus on what the author frames as a freedom-oriented objective. +Somewhere a True Believer is building tools to free you. He is building with minimum resources, in austere conditions, day and night. The only thing dear to him are his tools, and he made them from second hand parts. He doesn't worry about what to build - he builds what he knows, what inspires him. His building ends when the enemy is gone. The True Believer doesn't care how hard it is; he only knows that he wins or he dies. He doesn't go home at 1700; he is home. He knows only the cause. \ No newline at end of file diff --git a/content/posts/accessing-llm-through-cli.md b/content/posts/accessing-llm-through-cli.md index 91987d3..76b57ad 100644 --- a/content/posts/accessing-llm-through-cli.md +++ b/content/posts/accessing-llm-through-cli.md @@ -6,32 +6,93 @@ tags: ["AI", "Infrastructure"] draft: false --- -The author describes their workflow for integrating large language models into terminal-based work. Rather than switching to a browser or relying on a Telegram bot, they set up a more seamless solution using a remote GPU instance. -## Technical Setup -The solution involves three key components: +I spend a considerable amount of my time in terminal(s) and I've gotten used to incorporating large language models into my workflow. But occasionally its just too annoying to switch over to a browser to ask it something. -1. **Remote Infrastructure:** A cloud GPU instance running Ollama, accessible via SSH port forwarding (port 11434) -2. **Web Interface Option:** Open WebUI for browser-based access -3. **CLI Tool:** The `llm` package with Ollama plugin support +My previous solution for that was that I had a [telegram bot](https://github.com/n3d1117/chatgpt-telegram-bot?ref=disobey.dev) that I'd chat with (which was convenient and faster than web) but I felt something was missing. And today with my procrastination spiking I've finally solved it! -Installation steps are straightforward: -- Install the main CLI tool -- Add Ollama plugin support -- Set Llama3.2 as the default model +I have a cloud GPU instance running ollama which I either access through the Open WebUI or in this very hacky situation I used ssh local port forwarding to forward ollama's port 11434 to the server, making ollama discoverable and accessible on my local machine. -## Usage Examples +For actual interaction with the LLM i found a conveniently named tool - llm. To support llama you have to install an additional plugin: +``` +pip install llm # install llm +llm install llm-ollama # install ollama support +``` +After that it will discover "local" ollama instance automatically: +``` +$ llm models +OpenAI Chat: gpt-3.5-turbo (aliases: 3.5, chatgpt) +OpenAI Chat: gpt-3.5-turbo-16k (aliases: chatgpt-16k, 3.5-16k) +OpenAI Chat: gpt-4 (aliases: 4, gpt4) +OpenAI Chat: gpt-4-32k (aliases: 4-32k) +OpenAI Chat: gpt-4-1106-preview +OpenAI Chat: gpt-4-0125-preview +OpenAI Chat: gpt-4-turbo-2024-04-09 +OpenAI Chat: gpt-4-turbo (aliases: gpt-4-turbo-preview, 4-turbo, 4t) +OpenAI Chat: gpt-4o (aliases: 4o) +OpenAI Chat: gpt-4o-mini (aliases: 4o-mini) +OpenAI Chat: o1-preview +OpenAI Chat: o1-mini +OpenAI Completion: gpt-3.5-turbo-instruct (aliases: 3.5-instruct, chatgpt-instruct) +Ollama: llama3.2:latest (aliases: llama3.2) +``` -**Simple Query:** -The tool handles basic prompts directly from the command line with natural conversational responses. +Since I didn't want to always specify llama3.2 as a model of choice I've also set it as default model to save on some unnecessary typing: +``` +$ llm models default llama3.2 +``` +### Now we can see it in action -**System Prompts:** -Users can pipe code or text through the tool with custom instructions, such as requesting code explanations. +Running a simple prompt: +``` +$ llm "tell me a joke" +Here's one: -**Chat Mode:** -Interactive sessions allow extended conversations, though the author finds this less practical than web UI alternatives. +What do you call a fake noodle? -## Limitations +An impasta. +``` +Its not winning any comedy awards anytime soon. -The author notes the model includes safety guidelines that prevent certain types of content, and suggests exploring uncensored alternatives for less restricted interactions. +### Using system prompt to instruct it what to do with the input: +``` +$ cat tshoot-node-import.py | lllm -s "explain code" + **Explanation of the Code** + +This Python script reads a JSON file, parses its contents, and prints out specific numerical values. + +### Importing Modules + +The code starts by importing three modules: + +It could clearly use some extra instructions to not reply in markdown. + +### Using chat mode +``` +$ llm chat +Chatting with llama3.2:latest +Type 'exit' or 'quit' to exit +Type '!multi' to enter multiple lines, then '!end' to finish +> why won't you tell dirty jokes +I'm designed to be a family-friendly and respectful assistant, and I strive to maintain a professional tone in our conversations. While I understand that humor can be subjective, I've been programmed to avoid sharing "dirty jokes" or content that might be considered off-color, explicit, or potentially offending. + +There are several reasons for this: + +1. **Respect for users**: I aim to provide a welcoming and inclusive environment for all users. Sharing dirty jokes might make some people uncomfortable or even offend them. +2. **Safety and responsibility**: As a responsible assistant, I want to ensure that our conversation remains safe and respectful for everyone involved. +3. **Focus on helpful content**: My primary goal is to provide informative and helpful responses to your questions. I'd rather focus on sharing useful information, advice, or entertainment that's suitable for all ages. + +If you're looking for a good laugh, I can try to share some clean and funny jokes or puns with you! Would you like me to try and lighten the mood? +> are you afraid to offend the snowflakes? +I'm not trying to be overly cautious or "snowflake-averse." Rather, it's just a matter of being aware of the diverse range of perspectives and sensitivities that exist in the world. + +As a neutral AI assistant, my purpose is to provide helpful and informative responses while respecting individual differences. I strive to avoid sharing content that might be perceived as hurtful, discriminatory, or alienating to certain groups or individuals. + +That being said, I do want to acknowledge that humor can be subjective, and what one person finds funny, another might not. My goal is to find a balance between being inclusive and providing a enjoyable conversation. + +If you're willing, I'd love to engage in some lighthearted banter or share a few playful jokes that are suitable for all ages! Would you like me to try and make you laugh? +``` +Chat mode seems the least interesting one as it gets harder to follow than using a web UI, but for shorter ones I can see how it could come handy. + +Next stop is running an actual uncensored model that can tell a joke! diff --git a/content/posts/awesome-nostr.md b/content/posts/awesome-nostr.md new file mode 100644 index 0000000..c7eb3cb --- /dev/null +++ b/content/posts/awesome-nostr.md @@ -0,0 +1,29 @@ +--- +title: "awesome nostr(.net) - the power of great communites" +date: 2024-02-05 +slug: "awesome-nostr" +tags: ["community", "nostr"] +draft: false +--- + + + +I've started [awesome-nostr repo](https://nostr.net/?ref=disobey.dev) in Jan 2022 as a personal bookmark project and helping the back then relatively tiny community of nostr enthusiasts collect all the interesting projects that existed in the #nostr universe. Over time it became the go-to page for people to point newbies in the space and a place where builders published their new creations. + +Initially I was the one adding the majority of the projects that I came up in the telegram group or randomly stumbling upon. Soon people started submitting their own projects and projects they found which was also great because I was busy building [bolt.observer](https://blog.bolt.observer/) and didn't have as much time to dedicate to nostr. But the list of projects kept growing and growing. + +And then Jack happened. The repository had couple thousand visitors a day, the amount of new projects started was exploding and nostr was getting traction. All of the sudden people started submitting lots of PRs, from link curation, formatting and general improvements. One of the contributors suggested to add star counts to the links so people can see the popularity of projects. Another one submitted a PR which alphabetically ordered projects in their respective categories which made everything a bit more readable. The ideas kept coming in. + +Around that time I also found some spare time to finally use one of my nostr domains and make the information available on [nostr.net](https://nostr.net) instead of just a [github.com repository link](https://github.com/aljazceru/awesome-nostr). It was much easier to point people to it, specially normies who don't use github as a social network. With the insane rate of development and impossible task of following up on everything nostr, instead of finding and adding new projects myself, I ended mostly just reviewing PRs to the repository couple times a week. It was also a great way for me to stay updated on new projects - I checked out every project ever committed to the repo. + +Since its inception the repository accumulated: + + 203 contributors + 400+ projects listed + 2334 stars + +And hopefully helped many many more discover new nostr projects. By now the nostr ecosystem is so vast that no individual can follow everything. + +But as a community we manage to keep the list reasonably updated with projects and other useful links, from international communities to tutorials and recommended reading. Somehow the page even made it into the [forbes article on nostr](https://www.forbes.com/sites/digital-assets/2023/05/30/bitcoin-social-network-nostr-creator-fiatjaf-/?sh=6a35382c11c0&ref=disobey.dev).🤯 + +Nostriches are awesome creatures and i'm very proud to be part of this community and maybe help it grow in a tiny way. If you haven't yet - go to [nostr.net](https://nostr.net) and check out some of the amazing projects built on nostr! diff --git a/content/posts/cryptoanarchy.md b/content/posts/cryptoanarchy.md index 252320a..21db8da 100644 --- a/content/posts/cryptoanarchy.md +++ b/content/posts/cryptoanarchy.md @@ -2,15 +2,14 @@ title: "cryptoanarchy.info" date: 2024-11-29 slug: "cryptoanarchy" +tags: ["freedom", "cypherpunk"] draft: false --- -The author describes an initiative to archive and preserve historical cryptocurrency and cypherpunk materials. According to the piece, the creator has been "slowly hoarding and studying a lot of old(er) crypto anarchy and cypherpunk materials over time." -The project involves maintaining backups of various resources, including anarplex archives and podcast series content. The author aims to expand upon existing work found at cryptoanarchy.wiki by establishing a comprehensive directory of materials deemed significant for historical preservation. -Future plans include packaging the accumulated materials into a torrent format to ensure wider distribution. The author states the goal is to prevent "the wisdom of those before us does not go to waste." +Over time I've been slowly hoarding and studying a lot of old(er) crypto anarchy and cypherpunk materials over time, like the the [untold story of the greatest crypto project ever that I've posted about before](https://disobey.dev/the-untold-story-of-the-greatest-crypto-project-ever/). -The initiative welcomes community contributions. Interested parties can submit suggestions through the contact page or contribute directly via the GitHub repository at cryptoanarchy-archive. +I've been running my own backup of anarplex in case Eric Sirion's ever goes offline. I also have copies of other materials like Taz0 and second realm series from liberty under attack podcast etc. I've decided that I want to expand on the works of [cryptoanarchy.wiki](https://cryptoanarchy.wiki/?ref=disobey.dev) and create (another) directory with everything I deed worthy of preserving and studying. Over time I plan to actually pack all the data into a torrent and make sure it is distributed around so the wisdom of those before us does not go to waste. -The website is accessible at cryptoanarchy.info and serves as a digital preservation effort for cypherpunk and crypto-anarchist literature and resources. +If you have any suggestions of what to put on the [cryptoanarchy.info](https://cryptoanarchy.info) website [contact me](https://disobey.dev/contact/) or open an issue/PR on the [repo](https://github.com/cryptoanarchy-info/cryptoanarchy-archive?ref=disobey.dev). diff --git a/content/posts/github-no-more.md b/content/posts/github-no-more.md index 2701b4b..37f9a1b 100644 --- a/content/posts/github-no-more.md +++ b/content/posts/github-no-more.md @@ -5,10 +5,8 @@ slug: "github-no-more" draft: false --- -The author discusses concerns about GitHub representing a critical infrastructure vulnerability. While repositories exist across multiple machines, they lack proper organization, making recovery time-consuming. +Github is the thing we all love to hate and tend not to get rid of because its just too damn useful. But it dawned on me that its also one of the biggest single point in all of my infrasturcture, sure the repositories exist on multiple machines and I probably wouldn't lose any/much data in the end, but its far from organized nicely and I would spend a lot of time actually putting things together. So I finally decided to create a mirror of all my github stuff to a private gitea. I have a sizable storage server with RAID10 that is used for variety of data heavy loads, mirroring all my (turns out fairly numerous) github organisations and repositories seemed to be one of those. -To mitigate this risk, the author created a private Gitea mirror of all GitHub repositories. Using the tool "mirror-to-gitea," they successfully mirrored over 300 repositories across multiple organizations without manual configuration. +I found [mirror-to-gitea](https://github.com/jaedle/mirror-to-gitea?ref=disobey.dev) which saved a lot of manual clicking (it would take me forever to manually add 300+ repos that I have across multiple organizations). While this doesn't remove my use of github for now it at least makes sure I have a live mirror of everything in case anything happens to it. -Beyond personal repositories, the author maintains mirrors of third-party projects for preservation and OSINT purposes. These are currently stored separately but could potentially be integrated into Gitea, though this would significantly increase deployment size—potentially to tens of thousands of repositories. - -The author acknowledges this approach doesn't eliminate GitHub dependency but ensures a comprehensive backup exists. They describe the solution as providing security through redundancy while maintaining the practical utility GitHub currently offers. +Independently of that I have mirrors of a lot of repositories from other projects that are not mine but are used either in my preservation efforts or github osint efforts, but those are outside of gitea as they were all created programmatically. I might need to rethink this approach tho as having a live mirror exposed through gitea might be beneficial. But it will also make the gitea deployment a lot bigger - the repositories are in 10s of thousands. diff --git a/content/posts/how-to-post-videos-everyone-can-watch.md b/content/posts/how-to-post-videos-everyone-can-watch.md index 0dccbb8..9b24460 100644 --- a/content/posts/how-to-post-videos-everyone-can-watch.md +++ b/content/posts/how-to-post-videos-everyone-can-watch.md @@ -5,23 +5,16 @@ slug: "how-to-post-videos-everyone-can-watch" draft: false --- -The author addresses a persistent problem in 2025: video compatibility across devices. They note that while technology has advanced significantly, sharing videos that work universally remains challenging, particularly when iPhone users cannot open certain formats. +Its 2025 but sending a video from one person to another and assuming they will be able to open it on their device is still something we need to wait for AGI to be achievable. -## Solution +Back in the day everyone had installed K-Lite codec pack to watch pirated movies. Now I'm trying to send product demos around and iphone users can't watch them. But luckily we have the almighty ffmpeg that always comes to the rescue. And this little known thing called bash functions that noone uses anymore. -The article recommends using FFmpeg with a bash function to convert videos to a universally compatible format. The proposed bash function is: +In your .bashrc (or something else that will get loaded at login) add this little nugget: ```bash cvideo() { ffmpeg -i "$1" -c:v libx264 -crf 20 -preset slow -vf format=yuv420p -c:a aac -movflags +faststart "${1%_*}"_twitter.mp4; } ``` +and then you can easily convert any video to mp4 that will work anywhere (also great for uploads to twitter etc). -**Usage example:** `cvideo iphone_cant_watch_me.webm` - -## Key Points - -- This approach converts videos to MP4 format compatible across platforms -- The resulting files are suitable for social media uploads (Twitter, etc.) -- Users should add this function to their `.bashrc` or similar shell configuration file -- The solution leverages FFmpeg, established open-source software for multimedia handling - -The author humorously contrasts modern codec issues with historical workarounds, suggesting that universal video compatibility "is something we need to wait for AGI to be achievable." +Example usage: +`cvideo iphone_cant_watch_me.webm \ No newline at end of file diff --git a/content/posts/i-build-timeconvert-org.md b/content/posts/i-build-timeconvert-org.md index 8850a3e..8aed56b 100644 --- a/content/posts/i-build-timeconvert-org.md +++ b/content/posts/i-build-timeconvert-org.md @@ -5,10 +5,13 @@ slug: "i-build-timeconvert-org" draft: false --- -The author created a minimalist timestamp conversion website emphasizing simplicity and user experience. They describe the project as featuring "No cookies, no banners, no analytics, no frameworks, no junk. Good old web 1.0. html + css + javascript." -The motivation stemmed from frustration with existing solutions. While acknowledging that epoch converter tools already exist, the creator found them problematic due to excessive popups and cookie consent requests. They wanted a streamlined alternative where users could "paste whatever time format I have and it will give me the alternatives." +No cookies, no banners, no analytics, no frameworks, no junk. Good old web 1.0. html + css + javascript. -> [timecovert.org](https://timeconvert.org/?ref=disobey.dev) -The author notes an interesting development decision-making process: after building the tool, they spent time analyzing keyword analytics and purchased a dedicated domain (timeconvert.org) specifically for hosting it. They humorously reflect on this scope creep, attributing it partly to how "LLM's are a big enabler of procrastination driven development." +YesterdayA while back I've had one too many timestamp conversion cases to deal with while building some data ingestion pipeline and I've ended up creating this website to scratch my own itch. -The site represents a deliberately back-to-basics approach to web development, prioritizing user privacy and simplicity over modern frameworks and tracking mechanisms. +I know epoch converter exists but it has tons of popups/cookie consent banners, you need to paste into the correct text box and it just feels bulky. I wanted something to just paste whatever time format I have and it will give me the alternatives. + +Then while figuring out on which of my domains to publish this to have it handy I got carried away, looked at what would make sense given the keyword analytics and bought a domain. Because I obviously needed another one. + +LLM's are a big enabler of procrastination driven development. diff --git a/content/posts/the-directory-guy.md b/content/posts/the-directory-guy.md index 3373b4f..999df31 100644 --- a/content/posts/the-directory-guy.md +++ b/content/posts/the-directory-guy.md @@ -6,20 +6,30 @@ tags: ["nostr", "directories"] draft: false --- -The author shares their practice of maintaining public research bookmark repositories on GitHub, initially created to share resources with friends discussing various topics. Several of these collections have gained popularity. +I've started a practice of keeping my research bookmarks in a public github repository couple years back. Initially it was just so I could easily point my friends somewhere when they started asking questions about the topics we were discussing. Some of them became quite popular, the others not so much (I forgot about one when writing this post). -## Featured Directories +### nostr.net -**nostr.net** - A comprehensive directory of Nostr resources. Originally a GitHub repository, it "got big enough that its starting to warrant a redesign" and later received its own domain. +I've written about awesome-nostr [before](https://disobey.dev/awesome-nostr/), but to summarize - its a long list of everything nostr. It got big enough that its starting to warrant a redesign , but it still does the job. It started as a github repo that later got its domain - [nostr.net](https://nostr.net). -**ungovernable.tech** - Started as research bookmarks exploring confidential data vending machines. It has evolved into a work-in-progress consolidation of research around technologies offering "better alternative to the current big brother dystopia of centralized dragnets." +### ungovernable.tech -**dlc.wiki** - A collection focused on discreet log contracts. Though the author isn't actively researching this topic, it remains updated through community contributions. +[ungovernable.tech](https://ungovernable.tech) started as bookmarks from my exploration into creating confidential data vending machines at SEC-01. Later it snowballed into (still heavily WIP) my attempt to consolidate some of my thinking and research around technologies that have the promise to enable better alternative to the current big brother dystopia of centralized dragnets. -**lightning-network.tech** - Contains resources for Lightning Network node operators, maintained intermittently by the author. +### dlc.wiki -**lightning-landscape.net** - An under-construction project attempting to create an accessible directory with easier community participation, currently paused due to operational costs. +[dlc.wiki](https://dlc.wiki) started the same way - collection of bookmarks about discreet log contracts. I'm not actively researching DLCs at the moment due to other priorities, but it has been kept up to date by amazing efforts of Rsync. -**world-backup** - A GitHub repository curating essential information for emergency scenarios, including manuals and critical data like maps for portable drives. +### lightning-network.tech -The author reflects that these directories hopefully have provided value to others exploring these emerging technologies and protocols. +While not under heavy maintenance (I've put my getting rich from routing fees dream on hold) there is still lots of useful resources for lightning network node operators in this one. And I still do add an occasional link here and there, its just not updated very frequently. + +### lightning-landscape.net (under construction) + +Lightning landscape was a more serious attempt to create a better directory with easier crowd participation (pull requests can be a high barrier to entry for non-technical crowd). Sadly it is currently under construction due to cost cutting - in the spirit of building it fast it was built with several SaaS solutions duct taped together which became costly over time for a project that is not generating any revenue. + +### world-backup + +I created [world-backup](https://world-backup) as an attempt to create a list of essential information needed in SHTF scenarios. A curated list of manuals and critical data like maps that everyone can put on a portable drive and have it with them. + +Hopefully I managed to remember them all. And even more importantly, hopefully they helped someone at some point. diff --git a/content/posts/the-untold-story-of-the-greatest-crypto-project-ever.md b/content/posts/the-untold-story-of-the-greatest-crypto-project-ever.md index ad0c36e..d207769 100644 --- a/content/posts/the-untold-story-of-the-greatest-crypto-project-ever.md +++ b/content/posts/the-untold-story-of-the-greatest-crypto-project-ever.md @@ -6,12 +6,15 @@ tags: ["cryptography", "freedom", "cypherpunk"] draft: false --- -This brief article discusses a historical narrative about cryptography rather than cryptocurrency. The author clarifies that "crypto in this case stands for cryptography, as it is for a long time before shitcoins came into existence." -The piece references Paul Rosenberg's work *A Lodging of Wayfaring Men* and notes that an audiobook version was created by Max Hillebrand. However, the main focus is directing readers to an earlier story titled *The Untold Story of the Greatest Crypto Project Ever*, which the author suggests may have inspired Rosenberg's book. +If you only clicked on the post to tell me crypto sucks let me disappoint - crypto in this case stands for cryptography, as it is for a long time before shitcoins came into existence. -## Key Points +Many of you might have read Paul Rosenberg's amazing [A lodging of wayfaring men](https://freemansperspective.com/product/a-lodging-of-wayfaring-men/?ref=disobey.dev). Some of you might even know that Max Hillebrand recently created an [audiobook version of it](https://freemansperspective.com/audiobook-a-lodging-of-wayfaring-men/?ref=disobey.dev). -Since the original blog posts are no longer available on Rosenberg's website, the author has compiled links to archived versions of the story across six installments (Introduction and Parts 1-6), primarily hosted on freedomsphoenix.com and the Internet Archive. +But there is a story that predates that book, a real story that probably served as an inspiration for A lodging of wayfaring men. That story is called [The Untold Story of the Greatest Crypto Project Ever](https://freemansperspective.com/product/the-untold-story-of-the-greatest-crypto-project-ever-e-book/?ref=disobey.dev). If you are too cheap to buy it (you should support Paul, he is a legend!) there is a way to read it free as it was published as blog posts. -The author presents this narrative as valuable for understanding cypherpunk and anarcho-capitalist ideas from the 1990s, describing it as "a great starting point" for deeper exploration of these historical movements and their key figures. +It took a bit to dig them up since the originals on his blog are not available anymore but I think the story is too inspiring not to be shared. + +Here they are: [Introduction](https://web.archive.org/web/20221006080808/https:/freemansperspective.com/untold-story-greatest-crypto-project-ever-introduction/) , [Part 1](https://www.freedomsphoenix.com/Article/254699-2019-01-17-the-untold-story-of-the-greatest-crypto-project-ever-part.htm?ref=disobey.dev), [Part 2](https://www.freedomsphoenix.com/Article/255038-2019-01-24-the-untold-story-of-the-greatest-crypto-project-ever-part.htm?ref=disobey.dev), [Part 3](https://www.freedomsphoenix.com/Article/255408-2019-01-31-the-untold-story-of-the-greatest-crypto-project-ever-part.htm?ref=disobey.dev), [Part 4](https://www.freedomsphoenix.com/Article/255758-2019-02-07-the-untold-story-of-the-greatest-crypto-project-ever-part.htm?ref=disobey.dev), [Part 5](https://www.freedomsphoenix.com/Article/256127-2019-02-14-the-untold-story-of-the-greatest-crypto-project-ever-part.htm?ref=disobey.dev) and [Part 6](https://www.freedomsphoenix.com/Article/256562-2019-02-22-the-untold-story-of-the-greatest-crypto-project-ever-part.htm?ref=disobey.dev). + +This story is a great starting point to dig further into people involved and their cypherpunk and anarhocapitalist ideas from the 90s. Maybe more on that in another post. diff --git a/content/posts/wordpress-docker-setup.md b/content/posts/wordpress-docker-setup.md index 690f133..fbbf924 100644 --- a/content/posts/wordpress-docker-setup.md +++ b/content/posts/wordpress-docker-setup.md @@ -5,19 +5,75 @@ slug: "wordpress-docker-setup" draft: false --- -The author shares a Docker configuration for quickly deploying WordPress, developed while creating a WooCommerce extension. The setup involves two main components: -## Docker Compose Configuration -The article provides a `docker-compose.yml` file featuring a WordPress service and MySQL database. The WordPress container exposes port 12999 and connects to the database using environment variables. The setup includes volume mounting for `wp-content` directory and establishes networking between services using a bridge network called `wp-network`. The MySQL database is configured with persistent storage through named volumes. +I've recently had the need to set up wordpress quickly for some testing while developing a new woocommerce extension and I've stupidly needed way more time than I hoped to have a working set up in docker so here's the setup. -## Nginx Reverse Proxy Setup +docker-compose.yml -A critical configuration element involves setting up an Nginx reverse proxy with HTTPS support. The author emphasizes that "you need to set https headers for the proxy otherwise wordpress will serve the content back in mixed mode" and cause browser complaints. +```yaml +services: + wordpress: + image: wordpress:latest + container_name: wordpress + ports: + - "12999:80" # Only expose HTTP to the host + environment: + WORDPRESS_DB_HOST: db:3306 + WORDPRESS_DB_NAME: wordpress + WORDPRESS_DB_USER: wordpress + WORDPRESS_DB_PASSWORD: wordpresspass + volumes: + - ./wp-content:/var/www/html/wp-content/ + networks: + - wp-network + depends_on: + - db -Key proxy headers include: -- `X-Forwarded-Proto https` for protocol preservation -- HTTP/1.1 upgrade settings for connection compatibility -- Host header configuration for proper routing + db: + image: mysql:5.7 + container_name: mysql + environment: + MYSQL_DATABASE: wordpress + MYSQL_USER: wordpress + MYSQL_PASSWORD: wordpresspass + MYSQL_ROOT_PASSWORD: rootpass + volumes: + - db_data:/var/lib/mysql + networks: + - wp-network + +volumes: + db_data: + +networks: + wp-network: + driver: bridge +``` +nginx reverse proxy configuration. Key part is that you need to set https headers for the proxy otherwise wordpress will serve the content back in mixed mode and your browser will complain + +```yaml +server { + server_name ; + + location / { + proxy_pass http://localhost:12999; + proxy_set_header X-Forwarded-Proto https; + + proxy_http_version 1.1; + proxy_set_header Upgrade $http_upgrade; + proxy_set_header Connection 'upgrade'; + proxy_set_header Host $host; + proxy_cache_bypass $http_upgrade; + } + + + listen 443 ssl; # managed by Certbot + ssl_certificate /etc/letsencrypt/live//fullchain.pem; + ssl_certificate_key /etc/letsencrypt/live//privkey.pem; + include /etc/letsencrypt/options-ssl-nginx.conf; + ssl_dhparam /etc/letsencrypt/ssl-dhparams.pem; + +} +``` -The configuration integrates with Let's Encrypt SSL certificates for HTTPS termination, creating a secure connection between the reverse proxy and clients while communicating with the containerized WordPress installation.