Depbot is in beta stage which means some of the features are still being fine tuned based on user feedback. While in beta our platform is invite-only. If you're interested in getting access to the platform you can request an invite.

Getting Started

In order to get started with DepBot both the agent and the codebase need to be set up. This guide will walk you through the setup of both of these components so that at the end you can on every push to your codebase depbot can keep track of the dependencies in your codebase.

Creating a Depbot Account

The first step to get started is creating a Depbot account. If you have done this please skip to the next step. Creating an account can be done by requesting access through this form. our team will provide you with an access link which requires an email address to create your account.

Creating a Codebase

The next thing needed to keep track of your dependencies is to create a codebase that will be tracked commit by commit so you can get insights from the dependencies used by your team. To make this happen you will need to click on the “Create Codebase” button in the top right of the page.

  1. Click on the “Create Codebase” button in the top right of the page.
  2. Enter a name for your codebase.
  3. You will be presented with the codebase homepage.

One important data point here is the API_KEY generated for this newly created codebase. This is the key that will be used to communicate with the Depbot API, the Depbot Agent needs this API_KEY to know the codebase that the dependencies are related with.

Setting up the Agent

The agent will need to be setup in your CI in order to be able to track the dependencies on each commit in your codebase. This section explains how to do it, this only needs to be done once per repository.

Adding DEPBOT_API_KEY Secret

The first step is to add the DEPBOT_API_KEY secret to your CI. This secret will be used to communicate with the Depbot API. The Depbot Agent will look for that secret in the environment variables of the CI and use it when posting the dependencies to the Depbot API.

To do that on Github:

  • Go to your Github repository.
  • Click on the “Settings” tab.
  • Click on “Secrets”"Actions" in the sidebar.
  • Click on “New Repository Secret”.
  • Enter the name of the secret as “DEPBOT_API_KEY”.
  • Enter the value of the secret as the API_KEY generated for your codebase.

Once this is done we can add our agent to the Github Actions CI.

Adding the Depbot CI workflow

Once your github repository has the DEPBOT_API_KEY secret added we will need to add the Depbot CI workflow to the Github Actions CI. To to this we will add the following file to the .github/workflows/depbot.yml file:

name: Depbot

on: [push]

jobs:
  build:
    runs-on: ubuntu-latest
    steps:
      - uses: actions/checkout@v3

      - name: Installing Depbot
        run: |
          wget https://github.com/godepbot/depbot/releases/latest/download/depbot_linux_amd64.tar.gz
          tar -xvzf depbot_linux_amd64.tar.gz
          sudo mv depbot /usr/local/bin/depbot          
      - name: Running Depbot
        run: depbot sync --api-key=${{secrets.DEPBOT_API_KEY }}

And commit the changes to github. Once this is done, depbot will get the first set of dependencies for the repository we set at the start of the guide.