Don’t expose your REDIS or SQL ports to the world, limit which Docker containers can access them ( legacy solution )

A long time ago we had a temporary security breach. It was not really fully exploited as it was a pretty shielded use-case – but it could have been, if it was used in production. When you have Docker containers that share ports with each other, some of their ports may be exposed on your […]

How to add a sitemap of your Pod Page to WordPress Yoast SEO

Usually if you wanted to add Pods pages to your sitemaps, you would add the Pods SEO plugin. But that recently stopped working with Yoast, due to Yoast’s changes in the admin structure ( With sitemap configuration admin pages missing, the pods plugin had nowhere to show the options any longer ) So the next […]

How to import images from URLs into your WordPress Pods

Importing external images into your WordPress media library is a fairly common task when porting a site from one system to another. Or maybe you’re filling your database from a .CSV spreadsheet, and want to fill it as well with profile images or product images. So provided you’ve set up your Pod already, and it […]

Looping through WordPress Comments Programmatically and comparing their Meta

Recently I was importing comments and reviews from one CMS to a WordPress CMS. I couldn’t find a way to loop through comments fields with Pods unfortunately, as the comments themselves weren’t extended yet with Pods. But that doesn’t mean we can’t cycle through them in the good old-fashioned WordPress way : In this example […]

Go Anti-Patterns : os.IsExist(err) != !os.IsNotExist(err)

This article was first published 3 years ago as a gist. os.IsExist(err) != !os.IsNotExist(err) An old Golang anti-pattern is to mis-use the functions os.IsExist(err) and os.IsNotExist(err), thinking that they are the opposite of each other. But that couldn’t be further from the truth. They are error checkers, so use them only when err != nil, […]