Intro
CI/CD Fundamentals
git-vars package
Role Based Access Control
Protected Branches and Tags
Security Templates
Artifact Management
Installation
Via PIP
pip install git-vars
GitLab Authentication
To authenticate with GitLab, you need an access token. This token can be created in GitLab and set using the --access-token
or -t
option, or by setting an environment variable using the command export GITLAB_VARIABLE_ACCESS_TOKEN=<YOUR_GITLAB_ACCESS_TOKEN>
.
Creating a GitLab Access Token
- Go to your GitLab instance and log in.
- Click on your profile picture in the top right corner and select “Settings”.
- In the left sidebar, select “Access Tokens”.
- Give your token a name and select the scopes you need (e.g.,
read_api
andwrite_api
). - Click “Create personal access token”.
- Copy the token value and store it securely.