You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am new to Hugo and Docsy and I am having the following error when attempting to build my website locally using the hugo or hugo server commands:
Error: failed to load modules: failed to download modules: binary with name "go": not found
My repo is stored on Gitlab.com and my website fully functions when built with Gitlab and published to Gitlab Pages, and the first time I tried to build it locally using hugo server it worked fine, but now both hugo and hugo server commands result in this error. I am using Hugo Modules (basically I have cloned the Docsy example site and tweaked it for my use).
My local server is Ubuntu 22.04 and I have the following:
Hugo extended version installed via dpkg v 0.119.0
Git 2.34.1 via apt
Go 1.21.3 downloaded directly and installed to /usr/local/go, with /usr/local/go/bin on the PATH
Node.js 18.18.2 via nvm
My hugo.toml file contains these lines:
[module]
# uncomment line below for temporary local development of module
# replacements = "github.com/google/docsy -> ../../docsy"
[module.hugoVersion]
extended = true
min = "0.110.0"
[[module.imports]]
path = "github.com/google/docsy"
disable = false
[[module.imports]]
path = "github.com/google/docsy/dependencies"
disable = false
OK, so I apologise, but it seems that I had only set the PATH environment variable for go temporarily. Adding it to /etc/profile rebooting and trying again now works.
Rather embarrassed, but at least that also gives me a clue for Amplify. Sorry for the "noise"...
I am new to Hugo and Docsy and I am having the following error when attempting to build my website locally using the
hugo
orhugo server
commands:Error: failed to load modules: failed to download modules: binary with name "go": not found
My repo is stored on Gitlab.com and my website fully functions when built with Gitlab and published to Gitlab Pages, and the first time I tried to build it locally using
hugo server
it worked fine, but now bothhugo
andhugo server
commands result in this error. I am using Hugo Modules (basically I have cloned the Docsy example site and tweaked it for my use).My local server is Ubuntu 22.04 and I have the following:
My hugo.toml file contains these lines:
And I have go.mod and go.sum files.
Incidentally I have the same issue when trying to deploy via AWS Amplify: aws-amplify/amplify-hosting#884 (comment).
Does anyone have any suggestions about this error and how to fix it? I appreciate I might be doing something wrong herr and expecting it work....!
The text was updated successfully, but these errors were encountered: