Problem building Hugo from source

I’m trying to build Hugo from source to be able to make custom Docker containers for different platforms. During initial testing though, I’m just working in a clean Ubuntu 22.04 container running on AMD64 and manually running the commands that will eventually go into my Dockerfile.

The steps:

apt update && \
    export DEBIAN_FRONTEND=noninteractive && \
    apt upgrade -y && \
    apt install -y golang git

CGO_ENABLED=1 go install -tags extended

This downloads the dependencies just fine until:

root/go/pkg/mod/ undefined: atomic.Int64

And the process dies with an exit code of 2.

I have tried searching for that error but, haven’t found anything related. Any suggestions as to what might be wrong would be greatly appreciated.

You need to install go, version 1.19 or later.

That did it. Thank you.

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.