[ Web Proxy ]
URL:
Viewing: https://raw.githubusercontent.com/stackitcloud/stackit-cli/main/INSTALLATION.md [Back]  [Original]

# Installation

## Package managers

[![Packaging status](https://repology.org/badge/vertical-allrepos/stackit-cli.svg?columns=1)](https://repology.org/project/stackit-cli/versions)

### Platform independent

#### mise

The STACKIT CLI is available on all major platforms via [mise](https://mise.jdx.dev/):

```shell
mise u -g github:stackitcloud/stackit-cli
```

### macOS

The STACKIT CLI can be installed through the [Homebrew](https://brew.sh/) package manager.

1. First, you need to register the [STACKIT tap](https://github.com/stackitcloud/homebrew-tap) via:

```shell
brew tap stackitcloud/tap
```

2. You can then install the CLI via (this also trusts the STACKIT CLI cask):

```shell
brew install --cask stackitcloud/tap/stackit
```

### Linux

#### Snapcraft

The STACKIT CLI is available as a [Snap](https://snapcraft.io/stackit), and can be installed via:

```shell
sudo snap install stackit --classic
```

or via the [Snap Store](https://snapcraft.io/snap-store) for desktop.

#### Debian/Ubuntu (`APT`)

The STACKIT CLI can be installed through the [`APT`](https://ubuntu.com/server/docs/package-management) package manager.

##### Before you begin

To install the STACKIT CLI package, you will need to have the `curl` and `gnupg` packages installed:

```shell
sudo apt-get update
sudo apt-get install curl gnupg
```

##### Installing

1. Import the STACKIT public key:

```shell
curl https://packages.stackit.cloud/keys/key.gpg | sudo gpg --dearmor -o /usr/share/keyrings/stackit.gpg
```

2. Add the STACKIT CLI package repository as a package source:

```shell
echo "deb [signed-by=/usr/share/keyrings/stackit.gpg] https://packages.stackit.cloud/apt/cli stackit main" | sudo tee -a /etc/apt/sources.list.d/stackit.list
```

3. Update repository information and install the `stackit` package:

```shell
sudo apt-get update
sudo apt-get install stackit
```

> If you can't install the `stackit` package due to an expired key, please go back to step `1` to import the latest public key.

#### Nix / NixOS

The STACKIT CLI is available as a [Nix package](https://search.nixos.org/packages?channel=unstable&show=stackit-cli), and can be used via:

```shell
nix-shell -p stackit-cli
```

#### Eget

The STACKIT CLI binaries are available via our [GitHub releases](https://github.com/stackitcloud/stackit-cli/releases), you can install them from there using [Eget](https://github.com/zyedidia/eget).

```toml
# ~/.eget.toml
["stackitcloud/stackit-cli"]
asset_filters=["stackit-cli_", "_linux_amd64.tar.gz"]
```

```shell
eget stackitcloud/stackit-cli
```

#### RHEL/Fedora/Rocky/Alma/openSUSE/... (`DNF/YUM/Zypper`)

The STACKIT CLI can be installed through the [`DNF/YUM`](https://docs.fedoraproject.org/en-US/fedora/f40/system-administrators-guide/package-management/DNF/) / [`Zypper`](https://de.opensuse.org/Zypper) package managers.

> Requires rpm version 4.15 or newer to support Ed25519 signatures.

> `$basearch` is supported by modern distributions. On older systems that don't expand `$basearch`, replace it in the `baseurl` with your architecture explicitly (for example, `.../rpm/cli/x86_64` or `.../rpm/cli/aarch64`).

##### Installation via DNF/YUM

1. Add the repository:

```shell
sudo tee /etc/yum.repos.d/stackit.repo > /dev/null  /dev/null  We are currently working on distributing the CLI on more package managers for Linux.

### Windows

#### Scoop

The STACKIT CLI can be installed through the [Scoop](https://scoop.sh/) package manager.

1. Install Scoop (if not already installed):

```powershell
Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser
Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression
```

2. Install the CLI:

```powershell
scoop install stackit
```

## Manual installation

You can also get the STACKIT CLI by compiling it from source or downloading a pre-compiled binary.

### Compile from source

1. Clone the repository
2. Build the application locally by running:

   ```bash
   make build
   ```

   To use the application from the root of the repository, you can run:

   ```bash
   ./bin/stackit     
   ```

3. Skip building and run the Go application directly using:

   ```bash
   go run .     
   ```

### FreeBSD

The STACKIT CLI can be installed through the [FreeBSD ports or packages](https://docs.freebsd.org/en/books/handbook/ports/).

To install the port:

```shell
cd /usr/ports/sysutils/stackit/ && make install clean
```

To add the package, run one of these commands:

```shell
pkg install sysutils/stackit
# OR
pkg install stackit
```

### Pre-compiled binary

1. Download the binary corresponding to your operating system and CPU architecture from our [Releases](https://github.com/stackitcloud/stackit-cli/releases) page
2. Extract the contents of the file to your file system and move it to your preferred location (make sure the directory is added to your `PATH`)

Web Proxy Viewer  |  New URL  |  Original Page