Private dependencies

If your repository contains private dependencies, you can fetch them from the build action container. Buddy supports the following authorization methods:

  1. SSH keys
  2. HTTP authorization
  3. Environment variables

Authorization with SSH key

Select this method if your defined dependencies use the SSH protocol. Dependencies can be fetched using either Buddy's public key, or your own private key.

SSH Public Key

Hint
SSH keys generated in Buddy are unique for each project, which means that only pipelines belonging to this particular project are permitted to fetch the authorized dependencies.

You can find the SSH Public Key in Project Settings:

Image loading...Adding Buddy key

Private SSH Key

You can also define your own private SSH key and use it for authorization by adding it to the project's environment variables.

To do it, navigate to Variables, Keys & Assets, click Add variable, and either upload or generate a new key.

Warning
Make sure the key is not secured with a passphrase, or it won't work.

Image loading...Adding private key

HTTP authorization

If your dependencies are fetched over HTTP, you should include the authorization data in the repository URL:

default
https://ci-user:mypassword123@github.com/myorg/lib1.git

ENV VAR authorization

Some package managers, such as npm, support authorization with special authorization tokens.

In order to make the token available in the build action, it should be added to the project's variables with a proper name:

Image loading...Adding authorization token

Last modified on Jan 29, 2025

Recommended