Ubuntu-image version 2.0. Now with more Golang!

Upon archive opening for JJ, we will be switching to a new version of ubuntu-image that has been written in Go. This tool will be available as a .deb package through apt and also as a snap. The purpose of this re-write was to integrate ubuntu-image more tightly with snapd. The legacy Python version of ubuntu-image had quite a bit of code duplication with snapd. Rewriting the tool in Go has allowed us to greatly reduce this duplication.

This new tool will have feature parity with the legacy Python version of ubuntu-image, with a few minor differences.

Differences from the Python version

  • The tool is written in Go rather than Python
  • The syntax for the command line argument --hooks-directory is slightly changed. It will no longer accept a comma separated list of hooks directories. Instead it will expect this flag to be specified once per hook directory. For example:
    ubuntu-image --hooks-directory dir1 --hooks-directory dir2
  • The command line option -o / --output has been removed. This option has been deprecated for many years, so now felt like the right time to remove it. Use -O or --output-dir instead.
1 Like