Posts

  • Why you might want to avoid building C++ applications w/ `vcpkg`

    Dockerizing šŸ³ a C++ application can be much more difficult than dockerizing a Node.js or Python application. And it is not the execution of the binary that is difficult (that is easy). Itā€™s rather that compiling the source code requires a further stage in the Dockerfile, a so-called build stage, in which all build tools (gcc, cmake, etc.) and all dependencies (boost, zlib, etc.) must be installed and available.

    To define these dependencies, one might be tempted to use vcpkg, a ā€œC++ Library Manager for Windows, Linux, and MacOSā€ (https://github.com/microsoft/vcpkg), which is basically the equivalent of using npm+package.json in Node.js or pip+Pipfile in Python, right?

    Unfortunately, it is not. This approach leads to several problems.

  • Making use of Ubuntu's `unattended-upgrades` package to keep servers up-to-date without breaking them (hopefully)

    During my life, Iā€™ve mainly seen and used three ways to keep Ubuntu servers šŸ§ up-to-date:

    1. Manually (not recommended šŸ›‘ time-consuming and error-prone)
    2. Cron job via /etc/crontab (works, but still not greatā€¦)
    3. unattended-upgrades (the easiest and most robust way!)
  • Hello, world!

    def print_hello(name)
      puts "Hello, #{name}!"
    end
    print_hello('world')
    #=> prints 'Hello, world!' to STDOUT.

subscribe via RSS