Developers guide

Prerequisites

  • Golang
  • Trivy for license scanning

For other package dependencies, see Getting started guide

Build Image Creator binary

Run:

sudo make -C ./toolkit go-imagecreator

After running the command, the Image Creator binary will be located at ./toolkit/out/tools/imagecreator.

Run Image Creator specific tests

  1. Download the test RPM files and the tools tar file to create new image:

    ./toolkit/tools/internal/testutils/testrpms/download-test-utils.sh -t 3.0 -s true
    
  2. Run the tests:

    sudo go test -C ./toolkit/tools ./pkg/imagecreatorlib -args \
      --run-create-image-tests true
    
  3. To update go dependencies (direct and indirect) to minor or patch versions, run go get -u ./... then go mod tidy.