Skip to content

Commit

Permalink
Update kubestash docs
Browse files Browse the repository at this point in the history
Signed-off-by: Md. Ishtiaq Islam <[email protected]>
  • Loading branch information
ishtiaqhimel committed Mar 6, 2024
2 parents 221fe69 + 378bd0a commit b998796
Show file tree
Hide file tree
Showing 14 changed files with 194 additions and 345 deletions.
6 changes: 3 additions & 3 deletions docs/guides/auto-backup/overview/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ section_menu_id: guides

# Auto Backup with KubeStash

KubeStash can be configured to automatically backup of any stateful workloads in your cluster. KubeStash enables cluster administrators to deploy backup blueprints ahead of time so that application owners can easily backup any types of workload with a few annotations. This allows Enterprises to stay prepared for disaster scenarios and recover from offsite secure backups in case of a disaster on public cloud and on-premises datacenters.
KubeStash can be configured to automatically backup of any stateful workloads in your cluster. KubeStash enables cluster administrators to deploy backup blueprints ahead of time so that application owners can easily backup any types of workload with a few annotations. This allows enterprises to stay prepared for disaster scenarios and recover from offsite secure backups in case of a disaster on public cloud and on-premises datacenters.

## What is Auto Backup

Expand All @@ -33,8 +33,8 @@ The following diagram shows how automatic backup works in KubeStash. Open the im

The automatic backup process consists of the following steps:

1. A user creates a `BackupStorage` and corresponding storage secret with necessary credentials of the backend where the backed up data will be stored.
2. Then, he creates a `BackupBlueprint` crd that specifies a blueprint for `BackupConfiguration` object.
1. A user creates a `BackupStorage` and corresponding storage `Secret` with necessary credentials of the backend where the backed up data will be stored.
2. Then, he creates a `BackupBlueprint` custom resource that specifies a blueprint for `BackupConfiguration` object.
3. Then, he creates a workload with some annotations for automatic backup.
4. KubeStash operator watches for workloads. When it finds a workload with annotations for automatic backup, it finds out the respective `BackupBlueprint`.
5. Then, KubeStash operator resolves the blueprint by replacing variable fields of the blueprint with respective information from the workload.
Expand Down
2 changes: 1 addition & 1 deletion docs/guides/workloads/overview/images/backup_overview.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
10 changes: 5 additions & 5 deletions docs/guides/workloads/overview/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ The backup process consists of the following steps:

3. KubeStash operator watches for `BackupStorage` custom resources. When it finds a `BackupStorage` object, it initializes the `BackupStorage` by uploading the `metadata.yaml` file into the target storage.

4. Then, she creates a `BackupConfiguration` crd which specifies the targeted workload and desired file paths to backup. The `BackupConfiguration` object specifies the `Repository` pointing to a `BackupStorage` that contains backend information, indicating where to upload backup data. It also defines the `Addon` information with a specified task to be used for backing up the volume.
4. Then, she creates a `BackupConfiguration` custom resource which specifies the targeted workload and desired file paths to backup. The `BackupConfiguration` object specifies the `Repository` pointing to a `BackupStorage` that contains backend information, indicating where to upload backup data. It also defines the `Addon` information with a specified tasks and their configuration parameters to be used for backing up the volume.

5. KubeStash operator watches for `BackupConfiguration` objects.

Expand All @@ -59,7 +59,7 @@ The backup process consists of the following steps:

12. Then it resolves the respective `Addon` and `Function` and prepares backup `Job`(s) definition.

13. Then, it mounts the targeted workload volume(s) into the `Job`(s) and creates it.
13. Then, it mounts the targeted workload volume(s) into the `Job`(s) and creates it/them.

14. The `Job`(s) takes backup of the targeted workload.

Expand All @@ -78,11 +78,11 @@ The restore process consists of the following steps:

1. At first, the user creates a workload where the data will be restored or the user can use the same workload.

2. Then, she creates a `RestoreSession` crd that specifies the target workload volume(s) where the backed-up data will be restored, the `Repository` object that points to a `BackupStorage` that holds backend information, and the target `Snapshot`, which will be restored. It also specifies the `Addon` info with task to use to restore the volume.
2. Then, she creates a `RestoreSession` custom resource that specifies the target workload volume(s) where the backed-up data will be restored, the `Repository` object that points to a `BackupStorage` that holds backend information, and the target `Snapshot`, which will be restored. It also specifies the `Addon` info with task to use to restore the volume.

3. KubeStash operator watches for `RestoreSession` crds.
3. KubeStash operator watches for `RestoreSession` custom resources.

4. When it finds a `RestoreSession` crd, it resolves the respective `Addon` and `Function` and prepares a restore `Job`(s) definition.
4. When it finds a `RestoreSession` custom resource, it resolves the respective `Addon` and `Function` and prepares a restore `Job`(s) definition.

5. The restore `Job`(s) restores the backed-up data into the targeted workload volume(s).

Expand Down
22 changes: 11 additions & 11 deletions docs/setup/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
---
title: Setup | Stash
description: Setup guides for Stash by AppsCode
title: Setup | KubeStash
description: Setup guides for KubeStash by AppsCode
menu:
docs_{{ .version }}:
identifier: setup-readme
Expand All @@ -18,19 +18,19 @@ aliases:
# Setup

<div style="text-align: center;">
<a class="button is-info is-medium is-active has-text-weight-normal" href="/docs/setup/install/stash/index.md" style="background:#FC6011; width: 18rem;">Install Stash</a>
<a class="button is-info is-medium is-active has-text-weight-normal" href="/docs/setup/install/kubestash/index.md" style="background:#FC6011; width: 18rem;">Install KubeStash</a>
</div>
<br>

The setup section contains instructions for installing the Stash and its various components in Kubernetes. This section has been divided into the following sub-sections:
The setup section contains instructions for installing the KubeStash and its various components in Kubernetes. This section has been divided into the following sub-sections:

- **Install Stash:** Installation instructions for Stash and its various components.
- [Stash operator](/docs/setup/install/stash/index.md): Installation instructions for Stash operator.
- [Stash kubectl Plugin](/docs/setup/install/kubectl-plugin/index.md): Installation instructions for Stash `kubectl` plugin.
- **Install KubeStash:** Installation instructions for KubeStash and its various components.
- [KubeStash operator](/docs/setup/install/kubestash/index.md): Installation instructions for KubeStash operator.
- [KubeStash kubectl Plugin](/docs/setup/install/kubectl-plugin/index.md): Installation instructions for kubeStash `kubectl` plugin.
- [Troubleshooting](/docs/setup/install/troubleshooting/index.md): Troubleshooting guide for various installation problems.

- **Uninstall Stash:** Uninstallation instructions for Stash and its various components.
- [Stash operator](/docs/setup/uninstall/stash/index.md): Uninstallation instructions for Stash operator.
- [Stash kubectl Plugin](/docs/setup/uninstall/kubectl-plugin/index.md): Uninstallation instructions for Stash `kubectl` plugin.
- **Uninstall KubeStash:** Uninstallation instructions for KubeStash and its various components.
- [KubeStash operator](/docs/setup/uninstall/kubestash/index.md): Installation instructions for KubeStash operator.
- [KubeStash kubectl Plugin](/docs/setup/uninstall/kubectl-plugin/index.md): Uninstallation instructions for KubeStash `kubectl` plugin.

- [Upgrading Stash](/docs/setup/upgrade/index.md): Instruction for updating Stash license and upgrading between various Stash versions.
- [Upgrading KubeStash](/docs/setup/upgrade/index.md): Instructions for updating KubeStash license and upgrading between various KubeStash versions.
2 changes: 1 addition & 1 deletion docs/setup/_index.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
---
title: Setup | Stash
title: Setup | KubeStash
menu:
docs_{{ .version }}:
identifier: setup
Expand Down
50 changes: 25 additions & 25 deletions docs/setup/install/kubectl-plugin/index.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
---
title: Install Stash kubectl Plugin
description: Installation guide for Stash kubectl Plugin
title: Install KubeStash kubectl Plugin
description: Installation guide for KubeStash kubectl Plugin
menu:
docs_{{ .version }}:
identifier: install-stash-kubectl-plugin
name: Stash kubectl Plugin
identifier: install-kubestash-kubectl-plugin
name: KubeStash kubectl Plugin
parent: installation-guide
weight: 30
product_name: kubestash
menu_name: docs_{{ .version }}
section_menu_id: setup
---

# Install Stash kubectl Plugin
# Install KubeStash kubectl Plugin

Stash provides a `kubectl` plugin to interact with Stash resources.
KubeStash provides a `kubectl` plugin to interact with KubeStash resources.

## Install using Krew

Stash `kubectl` plugin can be installed using Krew. [Krew](https://krew.sigs.k8s.io/) is the plugin manager for kubectl command-line tool. To install follow the steps below:
KubeStash `kubectl` plugin can be installed using Krew. [Krew](https://krew.sigs.k8s.io/) is the plugin manager for kubectl command-line tool. To install follow the steps below:

- Install `krew` following the steps [here](https://krew.sigs.k8s.io/docs/user-guide/setup/install/).

Expand All @@ -37,46 +37,46 @@ kubectl krew index list
kubectl krew update
```

- Install Stash `kubectl` plugin following the commands below:
- Install Kubestash `kubectl` plugin following the commands below:

```bash
kubectl krew install appscode/stash
kubectl stash version
kubectl krew install appscode/kubestash
kubectl kubestash version
```

- If Stash `kubectl` plugin is already installed, run the following command to upgrade the plugin:
- If KubeStash `kubectl` plugin is already installed, run the following command to upgrade the plugin:

```bash
kubectl krew upgrade
kubectl stash version
kubectl kubestash version
```

## Install using pre-built binary

You can download the pre-build binaries from [stashed/cli](https://github.com/kubestash/cli/releases) releases and put it into one of your installation directory denoted by `$PATH` variable.
You can download the pre-build binaries from [kubestash/cli](https://github.com/kubestash/cli/releases) releases and put it into one of your installation directory denoted by `$PATH` variable.

Here is a simple Linux command to install the latest 64-bit Linux binary directly into your `/usr/local/bin` directory:

```bash
# Linux amd 64-bit
curl -o kubectl-stash.tar.gz -fsSL https://github.com/kubestash/cli/releases/download/{{< param "info.cli" >}}/kubectl-stash-linux-amd64.tar.gz \
&& tar zxvf kubectl-stash.tar.gz \
&& chmod +x kubectl-stash-linux-amd64 \
&& sudo mv kubectl-stash-linux-amd64 /usr/local/bin/kubectl-stash \
&& rm kubectl-stash.tar.gz LICENSE.md
curl -o kubectl-kubestash.tar.gz -fsSL https://github.com/kubestash/cli/releases/download/{{< param "info.cli" >}}/kubectl-kubestash-linux-amd64.tar.gz \
&& tar zxvf kubectl-kubestash.tar.gz \
&& chmod +x kubectl-kubestash-linux-amd64 \
&& sudo mv kubectl-kubestash-linux-amd64 /usr/local/bin/kubectl-kubestash \
&& rm kubectl-kubestash.tar.gz LICENSE.md

# Mac OSX 64-bit
curl -o kubectl-stash.tar.gz -fsSL https://github.com/kubestash/cli/releases/download/{{< param "info.cli" >}}/kubectl-stash-darwin-amd64.tar.gz \
&& tar zxvf kubectl-stash.tar.gz \
&& chmod +x kubectl-stash-darwin-amd64 \
&& sudo mv kubectl-stash-darwin-amd64 /usr/local/bin/kubectl-stash \
&& rm kubectl-stash.tar.gz LICENSE.md
curl -o kubectl-kubestash.tar.gz -fsSL https://github.com/kubestash/cli/releases/download/{{< param "info.cli" >}}/kubectl-kubestash-darwin-amd64.tar.gz \
&& tar zxvf kubectl-kubestash.tar.gz \
&& chmod +x kubectl-kubestash-darwin-amd64 \
&& sudo mv kubectl-kubestash-darwin-amd64 /usr/local/bin/kubectl-kubestash \
&& rm kubectl-kubestash.tar.gz LICENSE.md
```

If you prefer to install kubectl Stash cli from source code, make sure that your go development environment has been setup properly. Then, just run:
If you prefer to install kubectl KubeStash cli from source code, make sure that your go development environment has been setup properly. Then, just run:

```bash
go get github.com/kubestash/cli/...
```

>Please note that this will install Stash cli from master branch which might include breaking and/or undocumented changes.
> Please note that this will install KubeStash cli from master branch which might include breaking and/or undocumented changes.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit b998796

Please sign in to comment.