Skip to content

Instantly share code, notes, and snippets.

View danhhuynh25029's full-sized avatar
🎯
Focusing

Danh Huynh danhhuynh25029

🎯
Focusing
View GitHub Profile
@MicahParks
MicahParks / go get private GitLab with group and subgroup (Golang modules).md
Last active April 24, 2025 04:03
go get private GitLab with group and subgroup (Golang modules)

Problem

The go command line tool needs to be able to fetch dependencies from your private GitLab, but authenticaiton is required.

This assumes your private GitLab is hosted at privategitlab.company.com.

Environment variables

The following environment variables are recommended:

export GO111MODULE=on
export GOPRIVATE=privategitlab.company.com