# Installing FIPS-compliant BEL (demo setup)

This guide will walk you through how to install BEL with FIPS on your Kubernetes
cluster in under five minutes.

> [!NOTE]
> **Note:** This guide contains instructions intended for non-production use. For
> production installations, please see our
> [complete BEL installation guide for FIPS](/buoyant-enterprise-linkerd/latest/installation/install-guide/#plan-features=fips).

## Step 1: Get your license key

BEL requires a valid license key to run. Log into the
[Buoyant portal](https://enterprise.buoyant.io/) and follow the instructions
there. You should end up with an environment variable like this:

```bash
export BUOYANT_LICENSE=[LICENSE]
```

## Step 2: Get the CLI with FIPS support

> [!WARNING]
> At present, FIPS-compliant Linkerd is only available for x86 clusters (though
> you can use the CLI on ARM64 too). ARM64 support is underway, but it's not here
> yet.

Download and install the BEL command-line interface, with FIPS enabled, onto
your local environment:

```bash
curl --proto '=https' --tlsv1.2 -sSfL https://enterprise.buoyant.io/install | FIPS=1 sh
```

Follow the instructions to add the FIPS-enabled BEL `linkerd` CLI to your system
path. You can verify that the CLI is installed and running the expected version
with:

```bash
linkerd version --client
```

You should see `Client version: enterprise-2.20.6-fips`.

## Step 3: Install the Gateway API CRDs on your cluster

Linkerd uses [Kubernetes Gateway API](https://gateway-api.sigs.k8s.io/)
resources to configure certain features. To install the latest supported version
of the Gateway API, run:

```bash
kubectl apply -f https://github.com/kubernetes-sigs/gateway-api/releases/download/v1.5.1/standard-install.yaml
```

If you already have the Gateway API CRDs on your cluster, you can likely just
use them as is. For details, see our
[Managing Gateway API resources doc](/buoyant-enterprise-linkerd/latest/guides/managing-gateway-api/).

## Step 4: Validate that your Kubernetes cluster is ready for installation:

Run the pre-installation checks:

```bash
linkerd check --pre
```

## Step 5: Install FIPS-compliant BEL onto your cluster (x86 only)

> [!WARNING]
> At present, FIPS-compliant Linkerd is only available for x86 clusters (though
> you can use the CLI on ARM64 too). ARM64 support is underway, but it's not here
> yet.

We're finally ready to install FIPS-compliant BEL on your cluster!

> [!WARNING]
> The TLS certificates generated in this step will expire after one year. If you
> expect your Linkerd installation to run for more than a year, please see our
> [complete BEL installation guide for FIPS](/buoyant-enterprise-linkerd/latest/installation/install-guide/#plan-features=fips).

To install BEL, run:

```bash
linkerd install --crds | kubectl apply -f -
linkerd install | kubectl apply -f -
```

**If you are on GKE 1.29+, you will also need to configure a custom `clusterNetworks` value.**

```bash
--set clusterNetworks=34.118.224.0/20\,10.0.0.0/8\,100.64.0.0/10\,172.16.0.0/12\,192.168.0.0/16\,fd00::/8
```

For more information see the
[GKE docs](https://cloud.google.com/kubernetes-engine/docs/concepts/alias-ips#-managed_secondary_ranges_default).

## Verify your installation

After the installation is complete, you can verify the health and configuration
of Linkerd by running the `linkerd check` command:

```bash
linkerd check
```

Congratulations! You have successfully installed BEL onto your cluster.

## Step 6: Install the dashboard and verify FIPS

In this step, we'll install the BEL [Linkerd dashboard](/linkerd-dashboard/) so
that we can take a look at Linkerd itself. Notably, this is the simplest way to
verify that Linkerd is using FIPS-compliant cryptography.

```bash
helm upgrade -i -n monitoring --create-namespace \
    linkerd-dashboard oci://ghcr.io/buoyantio/charts/linkerd-dashboard
kubectl rollout status -n monitoring deploy
```

Now we'll forward port 8081 to the the dashboard workload:

```bash
kubectl -n monitoring port-forward deployments/linkerd-dashboard 8081:8080 &
```

Then, open your browser and navigate to
[http://localhost:8081](http://localhost:8081). You should see the dashboard in
all its glory, notably including your Linkerd version in the leftmost cell of
the "Summary" row:

![Dashboard Overview](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-overview.jpg)

Click on the `mTLS` button in the left sidebar:

![Dashboard mTLS Button](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-mtls-button.jpg)

and you'll see the dashboard's mTLS view.

![Dashboard mTLS View](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-mtls-view.jpg)

Click on any of the "shield" icons:

![Dashboard mTLS Shield Button](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-mtls-shield.jpg)

and you'll see the details of the mTLS connection you selected, including the
cipher suites in use and the relevant CMVP number for connections using
FIPS-compliant cryptography:

![Dashboard mTLS Detail](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-mtls-detail.jpg)

Seeing the CMVP number proves that you're using FIPS, so when you're using
FIPS-compliant BEL, you should see a CMVP number for every meshed connection.
You'll also see an `Audit command` in that window; running that command is a
simple way to automate these checks. If it includes `tls_fips="true"`, you can
be sure you're using FIPS-compliant cryptography.

```bash
$ linkerd diagnostics proxy-metrics -n linkerd deployments/linkerd-identity | grep ^rustls_info
rustls_info{tls_suites="TLS13_AES_256_GCM_SHA384,TLS13_AES_128_GCM_SHA256,",tls_kx_groups="secp256r1,secp384r1,",tls_rand="AwsLcRs",tls_key_provider="AwsLcRs",tls_fips="true"} 1
```

## Step 7 (optional): Install a sample application

In this step we'll install a demo application, so that you can kick the tires.

We'll install a demo application called Emojivoto. Emojivoto is a simple
standalone Kubernetes application that uses a mix of gRPC and HTTP calls to
allow the user to vote on their favorite emojis.

Install Emojivoto into the `emojivoto` namespace by running:

```bash
curl --proto '=https' --tlsv1.2 -sSfL https://run.linkerd.io/emojivoto.yml \
  | kubectl apply -f -
```

Note that this command installs Emojivoto onto your cluster, but Linkerd hasn’t
been activated on it yet—we'll need to _mesh_ the application before Linkerd can
work its magic.

Before we mesh it, let’s take a look at Emojivoto in its natural state. We’ll do
this by forwarding traffic to its web-svc service so that we can point our
browser to it. Forward web-svc locally to port 8080 by running:

```bash
kubectl -n emojivoto port-forward svc/web-svc 8080:80 &
```

Now visit [http://localhost:8080](http://localhost:8080). Voila! You should see
Emojivoto in all its glory.

If you click around Emojivoto, you might notice that it’s a little broken! For
example, if you try to vote for the donut emoji, you’ll get a 404 page. Don’t
worry, these errors are intentional. (In a later guide, we’ll show you how to
identify the problem.)

With Emoji installed and running, we’re ready to mesh it—that is, to add
Linkerd’s data plane proxies to it. We can do this on a live application without
downtime, thanks to Kubernetes’s rolling deploys. Mesh your Emojivoto
application by running:

```bash
kubectl get -n emojivoto deploy -o yaml \
  | linkerd inject - \
  | kubectl apply -f -
```

This command retrieves all of the deployments running in the `emojivoto`
namespace, runs their manifests through the `linkerd inject` command, and then
reapplies it to the cluster.

Note that `linkerd inject` command simply adds annotations to the pod spec that
instruct Linkerd to inject the proxy into the pods when they are created.
Normally you would add these annotations through your build and deploy system,
not the CLI!

Once piped into kubectl apply, Kubernetes will execute a rolling deploy and
update each pod with the data plane’s proxies.

Congratulations! You’ve now added Linkerd to an application! Just as with the
control plane, it’s possible to verify that everything is working the way it
should on the data plane side. Check your data plane with:

```bash
linkerd -n emojivoto check --proxy
```

Since injecting Linkerd restarts the workloads being injected, you'll need to
restart the port-forward if you want to check out the GUI for the newly-meshed
Emojivoto:

```bash
kubectl -n emojivoto port-forward svc/web-svc 8080:80 &
```

After that, visiting [http://localhost:8080](http://localhost:8080) should look
exactly the same as it did before meshing.

## Step 8 (optional): Re-verify FIPS in the dashboard

Finally, you can use the dashboard to re-verify that Emojivoto is running with
FIPS-compliant cryptography. You shouldn't need to restart the port-forward for
the dashboard workload, but here's the command again if you do need to:

```bash
kubectl -n monitoring port-forward deployments/linkerd-dashboard 8081:8080 &
```

Navigating to [http://localhost:8081/mtls](http://localhost:8081/mtls) will show
the mTLS view again, but filtering to only show destinations in the `emojivoto`
namespace will help cut down the clutter. You can either pick the "emojivoto"
namespace from the `DST NS` pulldown menu:

![Dashboard mTLS Filter Menu](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-mtls-filter-menu.jpg)

or navigate to
[http://localhost:8081/mtls?query=dstNS:emojivoto](http://localhost:8081/mtls?query=dstNS:emojivoto).
Either will show you a more focused view of the mTLS overview:

![Dashboard Emojivoto mTLS](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-emojivoto-mtls.jpg)

As before, selecting a shield icon will show you details of the mTLS connection,
and every meshed connection should include the CMVP number to indicate
FIPS-compliant encryption.

![Dashboard Emojivoto FIPS](/buoyant-enterprise-linkerd/latest/installation/getting-started-with-fips/dashboard-emojivoto-fips.jpg)

## That's it!

If you get stuck on anything, please check out the places you can get
[help and support with BEL](/buoyant-enterprise-linkerd/latest/support/).

Happy meshing!
