> For the complete documentation index, see [llms.txt](https://docs.veedna.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.veedna.com/deploying-lineaje/hybrid-deployment/installing-and-registering-the-cli.md).

# Installing and Registering the CLI

Use this guide to install the CLI on your VM, register it with Lineaje, or deregister it when you no longer need it.

<details>

<summary>Installing the CLI</summary>

Download the CLI from the Lineaje Portal, extract it on your VM, and register it with your device code.

1. Log in to the [Lineaje Portal](https://app.veedna.com/auth/signup).
2. From the left-hand navigation, choose **Integrations**.
3. Under **SCA360**, click **Download SCA360**.
4. Extract the CLI using the following steps:

```
# Run these commands as a regular user
# Extract the veecli.tar.gz
ubuntu@ip-a.b.c.d:~$ tar -xzf veecli.tar.gz
# This will create a directory called veecli
ubuntu@ip-a.b.c.d:~$ cd veecli
# Run pre.sh to set the permissions of the CLI and associated files
ubuntu@ip-a.b.c.d:~$ bash pre.sh
```

5. Go to the Lineaje Portal and click **Verify Device**.

<figure><img src="/files/vwblQGscLU95tENsg0Oj" alt=""><figcaption></figcaption></figure>

6. Click **Verify Link**. The device confirmation code appears.

<div align="left"><figure><img src="/files/a8W9Wtw0XgSISu0TkSpq" alt=""><figcaption></figcaption></figure></div>

7. Click **Confirm**.
8. Provide your credentials, if prompted.

</details>

<details>

<summary>Registering the CLI</summary>

1. After device registration succeeds, copy the code shown in the Lineaje Portal. The device registration code is valid for 5 minutes. If it expires, click **Verify Device** → **Verify Link** to get a new code.

<div align="right"><figure><img src="/files/ZrM8dwVQYDM72OB1EvzZ" alt=""><figcaption></figcaption></figure></div>

2. Run the following commands from the Ubuntu machine where the CLI is extracted.

```
# Run these commands as a regular user
# Go inside the directory where CLI is extracted
ubuntu@ip-172-31-26-185:~$ cd veecli
# Register the CLI with the SBOM360 backend using the device code obtained from portal
ubuntu@ip-172-31-26-185:~$ ./veecli register --devicecode npbP_fImda2Cj_Hzk9LgxJUn
2022-07-07T14:18:15.584+0300 info Starting to register veeCLI
2022-07-07T14:18:16.924+0300 info Successfully configured authentication
2022-07-07T14:18:16.924+0300 debug Signature in auth0 access token payload is 
unknown
2022-07-07T14:18:16.933+0300 info Authenticated for Tenant Name - ******, Tenant 
Id - vdna_************** and Device Code - npbP_fImda2Cj_Hzk9LgxJUn
2022-07-07T14:18:16.934+0300 info Successfully registered veeCLI
```

</details>

<details>

<summary>Deregistering the CLI</summary>

Deregister the CLI when you want to stop it from communicating with the Lineaje backend.

```bash
cd veecli
./veecli deregister --force
```

</details>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter, and the optional `goal` query parameter:

```
GET https://docs.veedna.com/deploying-lineaje/hybrid-deployment/installing-and-registering-the-cli.md?ask=<question>&goal=<endgoal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is optional and describes the broader end goal you are ultimately trying to accomplish on behalf of the user. GitBook uses it to tailor the answer towards what is most useful for that goal.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
