Categories
Linux Pi-hole SSH The Horror!

Pi-hole

I recently installed Pi-hole on a brand spankin’ new Raspberry Pi to blacklist advertisements.

The install was very simple – all I had to do was follow their directions. My only frustration was that I forgot to enable SSH to start on boot. Evidently chkconfig has gone out of style, so I had to google The New Way. I suffered from ignorance for like 30 seconds. The horror!

I couldn’t find out how I change the DNS server in the router. I fear I shall have to contact my ISP. The horror!

Categories
CLI Linux NPM Programming Vue.js

Pro-tip: `npm run dev` Relies on /etc/hostname

In my ongoing effort to play with Vue.js, I’ve been attempting to run the command npm run dev, which is required to turn the Vue magic into regular Javascript magic (all computers are magic). I couldn’t figure out why it kept insisting it couldn’t bind to the address.

I was looking for a config file with a hostname defined. There isn’t one. It uses the contents of /etc/hostname.

PS1 and hostname showed my hostname as kraken. But according to /etc/hostname, it was kraken.kjcoop.com. NPM was trying to bind to kjcoop.com’s IP address.

There’s no reason the hostname had to include kjcoop.com. I originally took to putting it in the hostname when I first registered the domain name in 1998 because I thought it was neat. I never got out of the habit because until [longer ago than I care to admit], it never caused me problems.

Categories
CMSes MySQL Software Wordpress

Changing a Username in WordPress

When I installed WordPress, I reflexively made my username the same as it is everywhere. Its ease of being guessed makes it that much easier for an interloper to get into my system.

The WordPress UI says you can’t change your username. Actually you can just pop into the database and make the change.

The table is wp_users by default. You may have set the prefix to be different, but out of the box it’s “wp_”. To alter the row in question:

update wp_users set user_login="[new username]" where user_login="[existing username]";

Categories
CMSes Software SSH This Site Wordpress

WordPress on kjcoop.com is Live, as You May Have Observed

Most of what I spent my time on was making it pretty. I’m not a graphic designer, but I think it looks pretty good.

My only real annoyance with WordPress is the Gravatar nonsense – it’s a third party service used to have a pretty picture in your profile. I get that it offers users the ability to have the same picture on any WordPress site they comment on, but for those of us who don’t care, would it be so bad to be able to upload a profile picture locally?

Ten seconds of Googling revealed a couple plugins that will do that, but then you have to trust an internet stranger (no disrespect to the author or plugin intended) or invest time into reviewing the code yourself.

While I was pulling down a new version of master, I was getting a key error. Apparently my public key wasn’t in authorized_keys. Fortunately the error messages were pretty good, so I was able to deduce the cause of the problem in just a couple minutes.

Categories
CMSes Software Wordpress

Tinkering with WordPress

I spent a few hours tonight tinkering with WordPress. It’s different than I remember it from several years ago – imagine that!

Theming will be a challenge. I don’t want to have to write and maintain one from scratch, but if I make code changes to an existing theme (spoiler alert: I have), it makes it difficult to update the theme, which again puts me in the position to have to maintain it myself.

This is why I enjoyed the portion of customizing a theme where you can add extra CSS without having to worry about your theme overwriting your changes. Of course, you could always just make your own stylesheet and give it a name unlikely to be clobbered, such as your name (if your name is Style, I shall eat my words). I wound up using it’s inbuilt functionality.