Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs: document creating bind mount #2946

Merged
merged 5 commits into from
May 31, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -272,6 +272,39 @@ stages:
passwd: kairos
```

### Create Bind Mounts

Palette Edge allows you to create bind mounts from your Edge host to your cluster through the installer configuration
file named **user-data**, which allows your cluster to use directories or files from your Edge host directly within your
Kubernetes cluster. This setup is useful for scenarios where your applications are active in the cluster and need direct
access to files or directories on the Edge host.

Several packs require you set up bind mounts in order to function. For example, the
[Portworx pack](../../../integrations/portworx.md) requires several folders to be mounted on Edge deployments. You can
use the `install.bind_mounts` parameter to specify folders to be mounted. For example, the following user data mounts
three folders required by Portworx from the Edge host to the cluster.

```yaml
#cloud-config
stylus:
site:
debug: true
insecureSkipVerify: false
paletteEndpoint: api.console.spectrocloud.com
name: edge-appliance-1
caCerts:
- |
-----BEGIN CERTIFICATE-----

-----END CERTIFICATE-----

install:
bind_mounts:
- /etc/pwx
- /var/lib/osd
- /var/cores
```

## Multiple User Data Use Case

If you don't need to apply any unique configurations on the device once it arrives at the physical site, then your site
Expand Down
195 changes: 188 additions & 7 deletions docs/docs-content/integrations/calico.md
Original file line number Diff line number Diff line change
Expand Up @@ -43,28 +43,152 @@ Limitations: AWS, VMWare supports IP-in-IP encapsulation type. Azure supports VX

<TabItem label="3.26.x" value="3.26.x">

### Prerequisites

- You have created a bind mount for the `/var/lib/calico` folder on the Edge host. For more information, refer to
[Create Bind Mounts](#create-bind-mounts-for-edge-deployments).

### Parameters

| Name | Supported Values | Default value | Description |
| ------------------------ | ----------------------------------------------- | ------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| calico.encapsulationType | `CALICO_IPV4POOL_IPIP`, `CALICO_IPV4POOL_VXLAN` | `CALICO_IPV4POOL_IPIP` - AWS, VMware clouds | The encapsulation type to be used for networking (depends on the cloud) |
| | | `CALICO_IPV4POOL_VXLAN` - Azure cloud | |
| calico.encapsulationMode | `Always, CrossSubnet, Never` | Always | The mode to use the IPv4 POOL created at start up |
| calico.calicoNetworkCIDR | CIDR range | `192.168.0.0/16` | CIDR range to be assigned for Pods. This range should match the `podCIDR` range specified in the Kubernetes layer |

### Usage

#### Create Bind Mounts for Edge Deployments

In Edge deployments, Calico requires a bind mount on the host machine. Without the bind mount, it's possible for the
Calico pods to be stuck in the init state. Use the following example to create a bind mount from `/var/lib/calico` on
the Edge host. When you build an installer ISO with the `bind_mounts` block, the folders specified in the block will be
mounted. For more information about building the installer ISO, refer to
[Build Installer ISO](../clusters/edge/edgeforge-workflow/palette-canvos/build-installer-iso.md).

```yaml
#cloud-config
stylus:
site:
debug: true
insecureSkipVerify: false
paletteEndpoint: api.console.spectrocloud.com
name: edge-appliance-1
caCerts:
- |
-----BEGIN CERTIFICATE-----

-----END CERTIFICATE-----

install:
bind_mounts:
- /var/lib/calico
```

</TabItem>
<TabItem label="3.25.x" value="3.25.x">

### Prerequisites

- You have created a bind mount for the `/var/lib/calico` folder on the Edge host. For more information, refer to
[Create Bind Mounts](#create-bind-mounts-for-edge-deployments).

### Parameters

| Name | Supported Values | Default value | Description |
| ------------------------ | ----------------------------------------------- | ------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| calico.encapsulationType | `CALICO_IPV4POOL_IPIP`, `CALICO_IPV4POOL_VXLAN` | `CALICO_IPV4POOL_IPIP` - AWS, VMware clouds | The encapsulation type to be used for networking (depends on the cloud) |
| | | `CALICO_IPV4POOL_VXLAN` - Azure cloud | |
| calico.encapsulationMode | `Always, CrossSubnet, Never` | Always | The mode to use the IPv4 POOL created at start up |
| calico.calicoNetworkCIDR | CIDR range | `192.168.0.0/16` | CIDR range to be assigned for Pods. This range should match the `podCIDR` range specified in the Kubernetes layer |

### Usage

#### Create Bind Mounts for Edge Deployments

In Edge deployments, Calico requires a bind mount on the host machine. Without the bind mount, it's possible for the
Calico pods to be stuck in the init state. Use the following example to create a bind mount from `/var/lib/calico` on
the Edge host. When you build an installer ISO with the `bind_mounts` block, the folders specified in the block will be
mounted. For more information about building the installer ISO, refer to
[Build Installer ISO](../clusters/edge/edgeforge-workflow/palette-canvos/build-installer-iso.md).

```yaml
#cloud-config
stylus:
site:
debug: true
insecureSkipVerify: false
paletteEndpoint: api.console.spectrocloud.com
name: edge-appliance-1
caCerts:
- |
-----BEGIN CERTIFICATE-----

-----END CERTIFICATE-----

install:
bind_mounts:
- /var/lib/calico
```

</TabItem>

<TabItem label="3.24.x" value="3.24.x">

</TabItem>
### Prerequisites

<TabItem label="3.23.x" value="3.23.x">
- You have created a bind mount for the `/var/lib/calico` folder on the Edge host. For more information, refer to
[Create Bind Mounts](#create-bind-mounts-for-edge-deployments).

</TabItem>
### Parameters

<TabItem label="Deprecated" value="deprecated">
| Name | Supported Values | Default value | Description |
| ------------------------ | ----------------------------------------------- | ------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
| calico.encapsulationType | `CALICO_IPV4POOL_IPIP`, `CALICO_IPV4POOL_VXLAN` | `CALICO_IPV4POOL_IPIP` - AWS, VMware clouds | The encapsulation type to be used for networking (depends on the cloud) |
| | | `CALICO_IPV4POOL_VXLAN` - Azure cloud | |
| calico.encapsulationMode | `Always, CrossSubnet, Never` | Always | The mode to use the IPv4 POOL created at start up |
| calico.calicoNetworkCIDR | CIDR range | `192.168.0.0/16` | CIDR range to be assigned for Pods. This range should match the `podCIDR` range specified in the Kubernetes layer |

All versions below version 3.23.x are deprecated.
### Usage

#### Create Bind Mounts for Edge Deployments

In Edge deployments, Calico requires a bind mount on the host machine. Without the bind mount, it's possible for the
Calico pods to be stuck in the init state. Use the following example to create a bind mount from `/var/lib/calico` on
the Edge host. When you build an installer ISO with the `bind_mounts` block, the folders specified in the block will be
mounted. For more information about building the installer ISO, refer to
[Build Installer ISO](../clusters/edge/edgeforge-workflow/palette-canvos/build-installer-iso.md).

```yaml
#cloud-config
stylus:
site:
debug: true
insecureSkipVerify: false
paletteEndpoint: api.console.spectrocloud.com
name: edge-appliance-1
caCerts:
- |
-----BEGIN CERTIFICATE-----

-----END CERTIFICATE-----

install:
bind_mounts:
- /var/lib/calico
```

</TabItem>

</Tabs>
<TabItem label="3.23.x" value="3.23.x">

### Prerequisites

## Parameters
- You have created a bind mount for the `/var/lib/calico` folder on the Edge host. For more information, refer to
[Create Bind Mounts](#create-bind-mounts-for-edge-deployments).

### Parameters

| Name | Supported Values | Default value | Description |
| ------------------------ | ----------------------------------------------- | ------------------------------------------- | ----------------------------------------------------------------------------------------------------------------- |
Expand All @@ -73,11 +197,68 @@ All versions below version 3.23.x are deprecated.
| calico.encapsulationMode | `Always, CrossSubnet, Never` | Always | The mode to use the IPv4 POOL created at start up |
| calico.calicoNetworkCIDR | CIDR range | `192.168.0.0/16` | CIDR range to be assigned for Pods. This range should match the `podCIDR` range specified in the Kubernetes layer |

### Usage

#### Create Bind Mounts for Edge Deployments

In Edge deployments, Calico requires a bind mount on the host machine. Without the bind mount, it's possible for the
Calico pods to be stuck in the init state. Use the following example to create a bind mount from `/var/lib/calico` on
the Edge host. When you build an installer ISO with the `bind_mounts` block, the folders specified in the block will be
mounted. For more information about building the installer ISO, refer to
[Build Installer ISO](../clusters/edge/edgeforge-workflow/palette-canvos/build-installer-iso.md).

```yaml {14-16}
#cloud-config
stylus:
site:
debug: true
insecureSkipVerify: false
paletteEndpoint: api.console.spectrocloud.com
name: edge-appliance-1
caCerts:
- |
-----BEGIN CERTIFICATE-----

-----END CERTIFICATE-----

install:
bind_mounts:
- /var/lib/calico
```

</TabItem>

<TabItem label="Deprecated" value="deprecated">

All versions below version 3.23.x are deprecated.

</TabItem>

</Tabs>

## Troubleshooting

- A daemon set is installed and so a calico-node pod should run on all the nodes in the cluster to provide networking.
- For any issues with networking, check calico-node and calico-kube-controller pods on the cluster.

## Terraform

Use the following Terraform snippet to reference the Calico CNI pack in your Terraform template.

```hcl

data "spectrocloud_registry" "public_registry" {
name = "Public Repo"
}

data "spectrocloud_pack_simple" "calico" {
name = "cni-calico"
version = "3.26.0"
type = "helm"
registry_uid = data.spectrocloud_registry.public_registry.id
}
```

## References

- [Calico Documentation](https://docs.tigera.io/calico/latest/reference)
12 changes: 12 additions & 0 deletions docs/docs-content/integrations/rook-ceph.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@ The pack has two presets that provide the following two configurations:

- If you are using Rook on Edge, the Edge host needs to be created with at least two hard disks.

- If you are using Rook on Edge, you must have create a bind mount for the `/var/lib/rook` folder on the Edge host. For
more information, refer to
[Create Bind Mounts](../clusters/edge/edgeforge-workflow/prepare-user-data.md#create-bind-mounts).

## Parameters

| Parameter | Description | Default |
Expand Down Expand Up @@ -142,6 +146,10 @@ clusters.
- If you are using Rook on Edge, the Edge host needs to be created with at least two hard disks. The actual required
number of disks depend on your cluster configuration.

- If you are using Rook on Edge, you must have create a bind mount for the `/var/lib/rook` folder on the Edge host. For
more information, refer to
[Create Bind Mounts](../clusters/edge/edgeforge-workflow/prepare-user-data.md#create-bind-mounts).

## Parameters

| Parameter | Description | Default |
Expand Down Expand Up @@ -245,6 +253,10 @@ clusters.
- If you are using Rook on Edge, the Edge host needs to be created with at least two hard disks. The actual required
number of disks depend on your cluster configuration.

- If you are using Rook on Edge, you must have create a bind mount for the `/var/lib/rook` folder on the Edge host. For
more information, refer to
[Create Bind Mounts](../clusters/edge/edgeforge-workflow/prepare-user-data.md#create-bind-mounts).

## Parameters

| Parameter | Description | Default |
Expand Down