Skip to content

Commit

Permalink
migrate website docs main zarf repo (#590)
Browse files Browse the repository at this point in the history
* migrate website docs into this repo
* reorganize migrated docs structure
  • Loading branch information
YrrepNoj authored Jul 6, 2022
1 parent e96c5c8 commit 8ba3518
Show file tree
Hide file tree
Showing 92 changed files with 3,081 additions and 1,585 deletions.
2 changes: 1 addition & 1 deletion .adr-dir
Original file line number Diff line number Diff line change
@@ -1 +1 @@
docs/adr
adr
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
215 changes: 215 additions & 0 deletions docs/.images/Zarf Files - 3 Bubbles.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
732 changes: 732 additions & 0 deletions docs/.images/Zarf Left Underwater - Behind rock.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
4 changes: 4 additions & 0 deletions docs/.images/architecture.drawio.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
97 changes: 97 additions & 0 deletions docs/.images/favicon.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
78 changes: 78 additions & 0 deletions docs/0-zarf-overview.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
import TabItem from "@theme/TabItem";
import Tabs from "@theme/Tabs";

# Overview

![Zarf Underwater](.images/Zarf%20Left%20Underwater%20-%20Behind%20rock.svg)

## What is Zarf?

Zarf is an open-source tool that simplifies the setup & deployment of applications and resources onto AirGap or disconnected environments. You can think of a disconnected environment as a system that has the has limited connection to the internet, kind of like airplane mode.

Zarf equips you with the ability to quickly and securely deploy modern software onto these types of systems without relying on internet connectivity. It also simplifies the installation, updating, and maintenance of DevSecOps capabilities like Kubernetes clusters, logging, and SBOM compliance out of the box. Most importantly Zarf keeps applications and systems running even when they are disconnected.

## How Zarf works?

Zarf uses a static Go binary CLI that can be run on any machine, with or without internet connectivity. The Zarf CLI equips users with the ability to pull, package, and install all the resources their applications or clusters need to run without being connected to the internet. It can also deploy any necessary resources needed to stand up infrastructure tools (such as Terraform).

All that is needed to deploy your infrastructure, application, and resources in a disconnected environment is 3 files; the Zarf CLI binary, the Zarf init package, and a Zarf Package containing your app and resources.

![Zarf CLI + Zarf Init + Zarf Package](.images/Zarf%20Files%20-%20%203%20Bubbles.svg)

:::note

For more information on how zarf works under the hood visit our [Nerd Notes page](./6-developer-guide/3-nerd-notes.md)

:::

## Why Use Zarf?

- 💸 **Free and Open Source.** Zarf will always be free to use and maintained by the open source community.
- 🔓 **No Vender Lock.** There is no proprietary software that locks you into using Zarf. If you want to remove it, you still can use your help charts to deploy your software manually.
- 💻 **OS Agnostic.** Zarf supports numerous operating systems.For a full list, visit the [Supported OSes](./5-operator-manual/90-supported-oses.md) page.
- 📦 **Highly Distributable.** Integrate and deploy software from multiple, secure development environments including edge, embedded systems, secure cloud, data centers, and even local environments.
- 🚀 **Develop Connected Deploy Disconnected.** Teams can build, and configure individual applications or entire DevSecOps environments while connected to the internet and then package and ship them to a disconnected environment to be deployed.
- 💿 **Single File Deployments.** Zarf allows you to package the parts of the internet your app needs into a single compressed file to be installed without connectivity.
- ♻️ **Declarative Deployments.**
- 🦖 **Inherit Legacy Code**

## Quick Start

:::info

This quick start requires you to already have [home brew](https://brew.sh/) package manager installed on your machine.
For more install options please visit our [Getting Started page](3-getting-started.md)

:::

To download the Zarf CLI Binary,

1. Select your systems OS below
2. copy and past the quick start command into your computers terminal.

<Tabs>
<TabItem value="macOS" label="macOS" default>

```bash
brew tap defenseunicorns/tap
brew install zarf
```

</TabItem>
<TabItem value="Linux" label="Linux">

```bash
brew tap defenseunicorns/tap
brew install zarf
```

</TabItem>
<TabItem value="Windows" label="Windows">

```bash
Coming Soon!
```

</TabItem>
</Tabs>

27 changes: 27 additions & 0 deletions docs/1-understand-the-basics.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Understand The Basics

Before you are able to effectively use Zarf, it is would be useful to have an underlying understanding of the technology Zarf is built on/around. The section below provides some helpful links to start build up this foundation.

:::caution Hard Hat Area
This page is still being developed. More content will be added soon!
:::

<!-- TODO: This might be a good place to shamelessly plug the 'Air Gap' course -->
<!-- TODO: The links and information on this page need to be expanded a lot more to really be useful -->

<br />
<br />

## What is Kubernetes?
- [Kubernetes Overview](https://kubernetes.io/docs/concepts/overview/)
<br />
<br />

## What is the 'Air Gap'?


<br />
<br />

## What is GitOps?
- [CloudBees GitOps Definition](https://www.cloudbees.com/gitops/what-is-gitops)
21 changes: 21 additions & 0 deletions docs/10-roadmap.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Roadmap

:::caution Hard Hat Area
This page is still being developed. More content will be added soon!
:::

## Roadmap
The project roadmap for Zarf is hosted on a [GitHub Project Board](https://github.com/orgs/defenseunicorns/projects/1). There, you can see what we're working on and what work we're prioritizing.

If you want to add your own bug reports or feature requests to be considered on our roadmap, please feel free [add an issue](https://github.com/defenseunicorns/zarf/issues) on the GitHub repository.

<br />

## GA Release
Right now, Zarf is still in its 'beta' phase. We are working on a few final things before we release the official 1.0 general availability (GA) release. The current planned date for the GA release is mid June 2022. The work still needed for the GA release can be found on the roadmap with [this filter](https://github.com/orgs/defenseunicorns/projects/1/views/1?filterQuery=repo%3A%22defenseunicorns%2Fzarf%22+milestone%3A%22zarf+ga%22).



<!-- TODO: Expected release cycle? -->
<!-- TODO: Plan to be GA soon? (but we're currently not..) -->
<!-- TODO: Link to GitHub project backlog -->
12 changes: 12 additions & 0 deletions docs/11-community.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# Community

:::caution Hard Hat Area
This page is still being developed. More content will be added soon!
:::

- You can find us in the k8s slack in the [#zarf](https://kubernetes.slack.com/archives/C03B6BJAUJ3) channel or the [#zarf-dev](https://kubernetes.slack.com/archives/C03BP9Z3CMA) channel.
- The Zarf repository is hosted on [GitHub](https://github.com/defenseunicorns/zarf)
- [Zarf LinkedIn Project](https://www.linkedin.com/company/zarf-project/)


<!-- TODO: link to dev twitter (we don't have a zarf specific twitter yet but maybe we can link to the devs if they want?) -->
6 changes: 6 additions & 0 deletions docs/12-support.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Support

1. Make sure you've read the [Zarf Overview](./zarf-overview), [Understanding the Basics](./understand-the-basics), and the [Getting Started](./getting-started) guides.
2. Look for an answer in [the frequently asked questions](./faq).
3. Ask a question in [the Zarf Slack Channel](https://kubernetes.slack.com/archives/C03B6BJAUJ3)
4. [Read issues, report a bug, or rquest a new feature](https://github.com/defenseunicorns/zarf/issues)
6 changes: 6 additions & 0 deletions docs/13-walkthroughs.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
# Walkthroughs

:::caution Hard Hat Area
This page is still being developed. More content will be added soon!
:::

10 changes: 10 additions & 0 deletions docs/2-core-concepts.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# Core Concepts

:::caution Hard Hat Area
This page is still being developed. More content will be added soon!
:::

Now, assuming you're familiar with Kubernetes, the AirGap, and GitOps, we can get started on the core concepts of Zarf.

- **Package** - A binary files that contains the instructions and dependencies necessary to install an application on a system.
- **Component** - A set of defined functionality and resources that build up a package.
75 changes: 75 additions & 0 deletions docs/3-getting-started.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,75 @@
# Getting Started

Welcome to the documentation about Zarf, the air-gap tool! Let's get you started down your Zarfing journey!

## Installing Zarf

There are multiple ways to get the Zarf CLI onto your machine including installing from the Defense Unicorns Homebrew Tap, downloading a prebuilt binary from our GitHub releases, or even building the CLI from scratch yourself.

### Installing from the Defense Unicorns Homebrew Tap

[Homebrew](https://brew.sh/) is an open-source software package manager that simplifies the installation of software on macOS and Linux. With Homebrew, installing Zarf is super simple!

```bash
brew tap defenseunicorns/tap
brew install zarf
```

The above command detects your OS and system architecture and installs the correct Zarf CLI binary for your machine. Thanks to the magic of Homebrew, the CLI should be installed onto your $PATH and ready for immediate use.

### Downloading a prebuilt binary from our GitHub releases

All [Zarf releases](https://github.com/defenseunicorns/zarf/releases) on GitHub include prebuilt binaries that you can download and use. We offer a small range of combinations of OS and architecture for you to choose from. Once downloaded, you can install the binary onto your $PATH by moving the binary to the `/usr/local/bin` directory.

```bash
mv ./path/to/downloaded/{ZARF_FILE} /usr/local/bin/zarf
```

### Building the CLI from scratch

If you want to build the CLI from scratch, you can do that too! Our local builds depend on [Go 1.18.x](https://golang.org/doc/install) and are built using [make](https://www.gnu.org/software/make/).

```bash
git clone [email protected]:defenseunicorns/zarf.git
cd zarf
make build-cli # This builds all combinations of OS and architecture
mv ./build/{ZARF_FILE} /usr/local/bin/zarf
```

:::note
The `make build-cli` command builds a binary for each combinations of OS and architecture. If you want to shorten the build time, you can use an alternative command to only build the binary you need:

- `make build-cli-mac-intel`
- `make build-cli-mac-apple`
- `make build-cli-linux-amd`
- `make build-cli-linux-arm`
:::

<br />

## Verifying Zarf Install

Now that you have installed Zarf onto your path, let's verify that it is working by checking two things! First, we'll check the version of Zarf that has been installed with the command:

```bash
zarf version

# Expected output should look similar to the following
vX.X.X # X.X.X is replaced with the version number of your specific installation
```

If you are not seeing that, then it's possible that Zarf was not installed onto your $PATH, [this $PATH guide](https://zwbetz.com/how-to-add-a-binary-to-your-path-on-macos-linux-windows/) should help with that.

<br />

## Where to next?

Depending on how familiar you are with Kubernetes, DevOps, and Zarf, let's find what set of information would be most useful to you!

- If you want to dive straight into Zarf, you can find examples and guides in the [Walkthroughs](./walkthroughs) page.

- More information about the Zarf CLI is available in the [Zarf CLI](./user-guide/the-zarf-cli) page, or by browsing through the help descriptions of all the commands available through `zarf --help`.

- More information about the packages that Zarf create and deploy is available in the [Understanding Zarf Packages](./user-guide/zarf-packages/zarf-packages) page.

- If you want to take a step back and better understand the problem Zarf is trying to solve, you can find more context in the [Understand the Basics](./understand-the-basics) and [Core Concepts](./core-concepts) page.
42 changes: 42 additions & 0 deletions docs/4-user-guide/1-the-zarf-cli/1-building-your-own-cli.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Building Your Own Zarf CLI

:::note
As mentioned in the [Getting Started page](../../getting-started), a pre-compiled binary is available for arm64 and amd64 machines under the 'Assets' tab of our latest releases on [GitHub](https://github.com/defenseunicorns/zarf/releases). If you don't want to build the CLI yourself you could always download it from there.
:::

## Dependencies

:::info

If you want to built the CLI from scratch, you can easily do that! In order to build the cli you will need to make sure you have the following dependencies correctly configured:

1. The Zarf repository cloned down:
- `git clone [email protected]:defenseunicorns/zarf.git`
2. Have Go 1.18.x installed on your PATH (instructions can be found [here](https://go.dev/doc/install))
3. `make` utility installed on your PATH (instructions to install w/ Homebrew can be found [here](https://formulae.brew.sh/formula/make))

:::

## Building The CLI

Once you have the dependencies configured you can build the Zarf CLI by running the following commands:

```bash
cd zarf # go into the root level of the zarf repository

make build-cli # This will build binaries for linux, M1 Mac, and Intel Mac machines
# This puts the built binaries in the ./build directory
```

:::note Optimization Note
The `make build-cli` command builds a binary for each combinations of OS and architecture. If you want to shorten the build time, you can use an alternative command to only build the binary you need:

- `make build-cli-mac-intel`
- `make build-cli-mac-apple`
- `make build-cli-linux-amd`
- `make build-cli-linux-arm`
:::

#### Breaking Down Whats Happening

[Under the hood](https://github.com/defenseunicorns/zarf/blob/473cbd5be203bd38254556cf3d55561e5be247dd/Makefile#L44), the make command is executing a `go build .....` command with specific `CGO_ENABLED`, `GOOS`, and `GOARCH` flags depending on the distro and architecture of the system it is building for. The `CLI_VERSION` is passed in as a `ldflag` and is set to whatever the latest tag is in the repository as defined by `git describe --tags`.
29 changes: 29 additions & 0 deletions docs/4-user-guide/1-the-zarf-cli/100-cli-commands/0-zarf.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# zarf

Small tool to bundle dependencies with K3s for air-gapped deployments

```
zarf [COMMAND]|[ZARF-PACKAGE]|[ZARF-YAML] [flags]
```

### Options

```
-a, --architecture string Architecture for OCI images
-h, --help help for zarf
-l, --log-level string Log level when running Zarf. Valid options are: warn, info, debug, trace
-t, --toggle Help message for toggle
```

### SEE ALSO

* [zarf completion](./completion) - Generate the autocompletion script for the specified shell
* [zarf connect](./zarf_connect) - Access services or pods deployed in the cluster.
* [zarf destroy](./zarf_destroy) - Tear it all down, we'll miss you Zarf...
* [zarf init](./zarf_init) - Deploys the gitops service or appliance cluster on a clean linux box
* [zarf package](./package) - Pack and unpack updates for the Zarf gitops service.
* [zarf prepare](./prepare) - Tools to help prepare assets for packaging
* [zarf tools](./tools) - Collection of additional tools to make airgap easier
* [zarf version](./zarf_version) - Displays the version the zarf binary was built from

###### Auto generated by spf13/cobra on 20-May-2022
Original file line number Diff line number Diff line change
@@ -0,0 +1,25 @@
# zarf package

Pack and unpack updates for the Zarf gitops service.

### Options

```
-h, --help help for package
```

### Options inherited from parent commands

```
-a, --architecture string Architecture for OCI images
-l, --log-level string Log level when running Zarf. Valid options are: warn, info, debug, trace
```

### SEE ALSO

* [zarf](../zarf) - Small tool to bundle dependencies with K3s for air-gapped deployments
* [zarf package create](./zarf_package_create) - Create an update package to push to the gitops server (runs online)
* [zarf package deploy](./zarf_package_deploy) - Deploys an update package from a local file or URL (runs offline)
* [zarf package inspect](./zarf_package_inspect) - lists the payload of an update package file (runs offline)

###### Auto generated by spf13/cobra on 20-May-2022
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
# zarf package create

Create an update package to push to the gitops server (runs online)

```
zarf package create [flags]
```

### Options

```
--confirm Confirm package creation without prompting
-h, --help help for create
--skip-sbom Skip generating SBOM for this package
--zarf-cache string Specify the location of the Zarf image cache (default ".zarf-image-cache")
```

### Options inherited from parent commands

```
-a, --architecture string Architecture for OCI images
-l, --log-level string Log level when running Zarf. Valid options are: warn, info, debug, trace
```

### SEE ALSO

* [zarf package](./) - Pack and unpack updates for the Zarf gitops service.

###### Auto generated by spf13/cobra on 20-May-2022
Loading

0 comments on commit 8ba3518

Please sign in to comment.