I was reminded that one shouldn’t proxy non-web servers through Cloudflare (at least on their free plan).
Continue reading post "#3763"WWW posts page 5
Porkbun DNS was back up by the next morning after being down at least 4 hours on April 24th. The only word I got from Porkbun about the incident was from a ticket I sent them, in which they said they had a DDoS attack on their DNS servers.
Continue reading post "#3734"Porkbun DNS seems to be down and has been so for the last several hours at least. I have added Fastmail nameservers to my NS list so that things work for the moment, since I get that as part of my account there. Can’t for my client though, who I had recommended Porkbun to.
April Fools
I have made my first (I believe) April fools feature for my website. On April 1st, the page will spin around 360Β° on load and every time the user clicks. It’s a quick script I threw together this evening after deciding I wanted to finally do something for the day, as a number of websites do such things. It didn’t come together as smoothly as I hoped, which made me all the more determined to get something in place before the end of the day.
Continue reading post "April Fools"Goodbye, Google G Suite
When I registered my domain “tobymackenzie.com” in 2009, Dreamhost offered the then free Google Apps to provide email for the domain. Already having a normal Gmail account and preferring the labels system over folders, I went with it. For 12 some years, it provided my email service for that domain. It changed names and eventually became “G Suite legacy free edition” after they started charging all new accounts. But this summer they are finally killing off the free version, requiring me to pay up or leave. I chose to leave, migrating over to my existing Fastmail account being used for other domains.
Continue reading post "Goodbye, Google G Suite"Git info alias
I do a lot of management of work and personal projects with git
. I’ve been making shell and gitconfig aliases to make things that I do often quicker or to store logic of things that I won’t remember easily. One recent one that I really like is a git info
(or g i
) alias that shows status
and a number of other bits of information about the repository quickly with one command. I’ve been using it in place of status
most of the time.
Rsync and dealing with “some files vanished” warning
I use rsync
for backups, site deployments, and other purposes where I need to sync two folders. It took a little while to figure out, but has been great for those purposes since. Every once in a while, though, I run into issues with it. Recently, I set up an rsync
script to back up most of the files on my entire computer. Since this takes a while and the computer is actively running during the backup, things can change while it is still running. This can lead to some errors like “rsync warning: some files vanished before they could be transferred”. Even though this is a warning, and the sync works perfectly fine, it returns a non-zero exit code. This caused my script to stop and thus the rest of the backup activity didn’t finish.
I looked for an option or simple solution to allow it to go on without complaining.
Continue reading post "Rsync and dealing with “some files vanished” warning"MySQL: DELETE with sub-query on same table
I had an issue with a MySQL query containing a sub-query recently where it worked fine when done as a SELECT
query, but gave an error when switching it to a DELETE
query. The error given was something like ‘You can’t specify target table “items” for update in FROM clause’. The sub-query was referencing the same table as the main query, which apparently can’t be done directly in MySQL because the table will be modified during deletion. But there is a sort of a hack I found in this StackOverflow answer, among others, to force it to create a temp table and allow it to work.
Swap file for composer out of memory problems
PHP’s defacto package manager, composer, has long required large amounts of memory to do updates for larger projects, often more than servers or virtual machines have. The script will die with an out of memory error, or more recently, the simple message “Killed”, and do no work in these situations. The normal procedure is to develop locally, deploy local lock file (composer.lock
) to the server, and run composer install
instead of update
. But I’ve recently moved to doing most of my development in VMs, so I have had to work around this problem to get things installed or updated. A swap file is the solution for Linux machines provided in the official docs and expanded in a StackOverflow answer.
Unprivileged Homebrew install, 2021 edition
On my new MacBook, I’ve been isolating responsibilities into separate user accounts. This includes an unprivileged “manager” account for installing most global third-party software, and a few development accounts for different purposes. I use Homebrew to install some dev related software, but my old Homebrew setup didn’t work with this conceptually, nor with the more locked down privileges of newer Mac OS versions. I didn’t want to give Homebrew or its packages admin or root privileges, so I have adapted Homebrew’s untar anywhere method to install a globally available Homebrew using the unprivileged manager account, only requiring a privileged account briefly. I’ve also used untar anywhere for a per-account Homebrew install to allow each dev account to have custom versions of any desired packages, with no privileged account required.
Continue reading post "Unprivileged Homebrew install, 2021 edition"