Zeal + Vim = offline CakePHP (and other) documentation

As any long time Vim user, I’m constantly looking for ways to tweak and improve my text editor configuration, and make me even more efficient.  Today, I came across a very handy addition – Zeal – an offline documentation browser for developers. (Thanks to this blog post, which also mentions Dash as an alternative for those of you on the MacOS.)

With Zeal, you can download a whole lot of documentation sets for pretty much any web development technology out there – programming languages, frameworks, libraries, tools, and more.  And then you can easily integrate Zeal with whatever text editor or IDE you are using.

For Vim, there are, as always, several options.  Some of them are listed here. I personally opted for the Zeavim plugin.  The installation is straight forward and everything works out of the box.  After giving a quick try, I decided to adjust my .vimrc file to use CakePHP framework documentation together with the PHP programming language documentation whenever I’m working with any PHP file.  Here’s what I had to add:

" Zeal offline documentation
let g:zv_file_types = {
       \ 'php': 'cakephp,php',
       \ }

Now, whenever I edit a PHP file and hit “,z” (I use comma as a leader, by the way), Zeal window pops up with the relevant documentation search.

It’s super fast. It works offline, and it’s awesome!

Slimming down Docker images

It’s been a while since I posted anything about Docker.  That’s mostly because I still don’t really use it for anything – playing around locally, testing and learning doesn’t count yet.

But just to keep the ball rolling, here are a couple of handy links for the ideas on how to improve your Docker images, so that Docker uses much less space, benefits more from caching, and brings up the containers faster:

Both articles are around the same theme – choose your  base image carefully, try to minimize the layers, use only what you need, and don’t forget to clean up the disk space with “docker system prune“.

Happy 20th birthday, LWN!

Linux Weekly News (aka LWN) is celebrating its 20th birthday.  Wow, that’s quite impressive! Not many web sites can say that.  But even fewer can do so while covering technology news related to Linux and other Open Source Software.

I’ve been a reader of LWN since their early days.  I’ve been subscribed to it also at different times during the years (see 2002, and then 2004).  And I’m glad that they are still around.  I still catch up with the RSS feed on a weekly basis.

Happy birthday, LWN!  And thanks for all the hard work and excellent content.

Red Hat to Acquire CoreOS

Red Hat issued a press release announcing that it has signed a definitive agreement to acquire CoreOS Inc.

RALEIGH, N.C. —  — Red Hat, Inc. (NYSE: RHT), the world’s leading provider of open source solutions, today announced that it has signed a definitive agreement to acquire CoreOS, Inc., an innovator and leader in Kubernetes and container-native solutions, for a purchase price of $250 million, subject to certain adjustments at closing that are not expected to be material. Red Hat’s acquisition of CoreOS will further its vision of enabling customers to build any application and deploy them in any environment with the flexibility afforded by open source. By combining CoreOS’s complementary capabilities with Red Hat’s already broad Kubernetes and container-based portfolio, including Red Hat OpenShift, Red Hat aims to further accelerate adoption and development of the industry’s leading hybrid cloud platform for modern application workloads.
I find it to be very significant.  Have a look at other Red Hat acquisitions, especially lately, as well as their other programs and projects.

Getting the best performance out of Amazon EFS

Jeff Geerling shares his tips for “Getting the best performance out of Amazon EFS”.  Given how (still) new the Amazon EFS is and how limited is the documentation of the best practices, this stuff is golden.

tl;dr: EFS is NFS. Networked file systems have inherent tradeoffs over local filesystem access—EFS doesn’t change that. Don’t expect the moon, benchmark and monitor it, and you’ll do fine.

Nerd Fonts – Iconic font aggregator, collection, and patcher

Nerd Fonts is a collection of fonts for people who work with code snippets, command line, and text-based user interface applications.  The fonts are also patched with additional popular icon sets like Font Awesome, Devicons, Octicons, and others.

MySQL optimize, repair, and analyze

Years ago I had the following script running as a cron job, but then I lost it somewhere.  It took me a few minutes to find it again, but just in case I need it in the future, I’m saving it here.

#!/bin/bash
mysqlcheck --all-databases
mysqlcheck --all-databases -o
mysqlcheck --all-databases --auto-repair
mysqlcheck --all-databases --analyze

Found it here this time.

Nginx Performance Tuning – Tips & Tricks

Here are a whole lot of “Performance Tuning – Tips & Tricks” directly from the Nginx team.  I’m sure you’ve seen bits and pieces of these all over the place, but it’s nice to have them all together and from the credible source as well.

PHP-FPM tuning: Using ‘pm static’ for Max Performance

PHP-FPM tuning: Using ‘pm static’ for Max Performance” looks at different process management settings in PHP-FPM: static, dynamic, and ondemand, and the way they affect performance.  The default – ondemand – might work well for you if you have a large server with plenty of resources and not so many actual visitors.  Running on a smaller instance, or expecting high spikes of traffic might require you to look into your PHP-FPM configuration and adjust it.  The article is just what the doctor ordered.

Personally, I prefer having a dedicated instance for the web server, but that instance being as small as possible.  With that, figuring out the correct settings for static process management is easier.  It also minimizes all those nasty cases of running out of memory, swapping, and having an excessive CPU utilization.   Which is especially useful when running on Amazon AWS instances.

Linux Journal Ceases Publication

These are some sad, sad news, folks – Linux Journal is closing down:

EOF

It looks like we’re at the end, folks. If all goes according to a plan we’d rather not have, the November issue of Linux Journal was our last.

The simple fact is that we’ve run out of money, and options along with it. We never had a wealthy corporate parent or deep pockets of our own, and that made us an anomaly among publishers, from start to finish. While we got to be good at flying close to the ground for a long time, we lost what little elevation we had in November, when the scale finally tipped irrevocably to the negative.

I’ve been a subscriber of the Linux Journal for many years (just not the most recent ones), and I’ve learned a lot from it.  It’s very sad to see it go, even though it’s been years since I read it last.