I managed to do it with a hack. I documented it in this note, but short version is: 1) pass each module’s deploy key to the build via environment variables, 2) run build with a custom script that clones each module via git-ssh, and 3) point hugo to the locally cloned modules using the replacements mechanism.
mmr
2
Related topics
| Topic | Replies | Views | Activity | |
|---|---|---|---|---|
| Proper way to get "private" repo's Hugo Modules? | 10 | 4066 | August 1, 2021 | |
| Netlify and Hugo Modules with private repo (fatal: could not read Username for 'https://github.com' | 4 | 888 | February 10, 2024 | |
| Finally Resolved Failed Netlify Deployments: git subtree solution | 2 | 1218 | December 25, 2020 | |
| Git Lab to Netlify error | 3 | 1302 | August 5, 2019 | |
|
Go.mod for local and netlify deploy
|
0 | 366 | September 7, 2023 |