constellation/docs/versioned_docs/version-2.0/getting-started/install.md
Felix Schuster 2b32b79026
Rewording in "Getting started" (#193)
* Small changes

* Update docs/docs/getting-started/first-steps.md

Co-authored-by: Nils Hanke <Nirusu@users.noreply.github.com>

* Update docs/docs/getting-started/first-steps.md

Co-authored-by: Nils Hanke <Nirusu@users.noreply.github.com>

* Update docs/versioned_docs/version-2.0/getting-started/first-steps.md

Co-authored-by: Nils Hanke <Nirusu@users.noreply.github.com>

Co-authored-by: Nils Hanke <Nirusu@users.noreply.github.com>
2022-09-26 15:19:09 +02:00

5.3 KiB

Installation and setup

Constellation runs entirely in your cloud environment and can be controlled via a dedicated command-line interface (CLI).

The following guides you through the steps of installing the CLI on your machine, verifying it, and connecting it to your cloud service provider (CSP).

Prerequisites

Make sure the following requirements are met:

  • Your machine is running Linux or macOS
  • You have admin rights on your machine
  • kubectl is installed
  • Your CSP is Microsoft Azure or Google Cloud Platform (GCP)

Install the Constellation CLI

The CLI executable is available at GitHub. Install it with the following commands:

  1. Download the CLI:
curl -LO https://github.com/edgelesssys/constellation/releases/latest/download/constellation-linux-amd64
  1. Verify the signature (optional)

  2. Install the CLI to your PATH:

sudo install constellation-linux-amd64 /usr/local/bin/constellation
  1. Download the CLI:
curl -LO https://github.com/edgelesssys/constellation/releases/latest/download/constellation-linux-arm64
  1. Verify the signature (optional)

  2. Install the CLI to your PATH:

sudo install constellation-linux-arm64 /usr/local/bin/constellation
  1. Download the CLI:
curl -LO https://github.com/edgelesssys/constellation/releases/latest/download/constellation-darwin-arm64
  1. Verify the signature (optional)

  2. Install the CLI to your PATH:

sudo install constellation-darwin-arm64 /usr/local/bin/constellation
  1. Download the CLI:
curl -LO https://github.com/edgelesssys/constellation/releases/latest/download/constellation-darwin-amd64
  1. Verify the signature (optional)

  2. Install the CLI to your PATH:

sudo install constellation-darwin-amd64 /usr/local/bin/constellation

:::tip The CLI supports autocompletion for various shells. To set it up, run constellation completion and follow the given steps. :::

Set up cloud credentials

The CLI makes authenticated calls to the CSP API. Therefore, you need to set up Constellation with the credentials for your CSP.

Required permissions

You need the following permissions for your user account:

  • Contributor (to create cloud resources)
  • User Access Administrator (to create a service account)

If you don't have these permissions with scope subscription, ask your administrator to create the service account and a resource group for your Constellation cluster. Your user account needs the Contributor permission scoped to this resource group.

Create a new project for Constellation or use an existing one. Enable the Compute Engine API on it.

You need the following permissions on this project:

  • compute.* (or the subset defined by roles/compute.instanceAdmin.v1)
  • iam.serviceAccountUser

Follow Google's guide on understanding and assigning roles.

Authentication

You need to authenticate with your CSP. The following lists the required steps for testing and production environments.

:::note The steps for a testing environment are simpler. However, they may expose secrets to the CSP. If in doubt, follow the production steps. :::

Testing

Simply open the Azure Cloud Shell.

Production

Use the latest version of the Azure CLI on a trusted machine:

az login

Other options are described in Azure's authentication guide.

Testing

You can use the Google Cloud Shell. Make sure your session is authorized. For example, execute gsutil and accept the authorization prompt.

Production

Use one of the following options on a trusted machine:

  • Use the gcloud CLI

    gcloud auth application-default login
    

    This will ask you to log-in to your Google account and create your credentials. The Constellation CLI will automatically load these credentials when needed.

  • Set up a service account and pass the credentials manually

    Follow Google's guide for setting up your credentials.

Next steps

You are now ready to deploy your first confidential Kubernetes cluster and application.