Skip to content

Commit

Permalink
Run pre-commit run -a on the codebase
Browse files Browse the repository at this point in the history
  • Loading branch information
RothAndrew committed Nov 1, 2021
1 parent 5825443 commit 1182466
Show file tree
Hide file tree
Showing 18 changed files with 313 additions and 314 deletions.
66 changes: 33 additions & 33 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -31,14 +31,14 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<td width="150">

**Get Started**

_Using Zarf_

</td>
<td>

Experience just how easy it is to go from _**zero** to **chainsaw wielding hero** (of the Kubernetes cluster)_ using Zarf!

</td>
<td>

Expand All @@ -51,11 +51,11 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<!-- row start -->
<tr valign="top">
<td>

**Add Logging**

_Zarf components_

</td>
<td>

Expand All @@ -73,16 +73,16 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<!-- row start -->
<tr valign="top">
<td>

**Roll Your Own**

_Custom packages_

</td>
<td>

Once you're comfortable with the basic workflow & able to deploy _someone else's_ Zarf deployment packages, it's time to roll your own. Here's how.

</td>
<td>

Expand Down Expand Up @@ -113,14 +113,14 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<td width="150">

**Simple Applications**

_Appliance Mode_

</td>
<td>

If want to "run a Kubernetes app" but aren't into hand-rolling a cluster just for it, Zarf can help. Here's how, and _why_ you might want to.

</td>
<td>

Expand All @@ -133,16 +133,16 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<!-- row start -->
<tr valign="top">
<td>

**Disconnected GitOps**

_The Utility Cluster_

</td>
<td>

Zarf overcomes the "the Air Gap problem" using a Kubernetes cluster (and k8s-native tooling) for the care & feeding of _other k8s clusters_.

Here's how it works and what ops/support looks like.

</td>
Expand Down Expand Up @@ -175,10 +175,10 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<td width="150">

**Workstation Setup**

</td>
<td>

Thinking about hacking on the Zarf binary itself? Or, perhaps you want to run the examples in an isolated environment (the same way we do)? Get your machine setup _just right_ using these instructions!

</td>
Expand All @@ -193,12 +193,12 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<!-- row start -->
<tr valign="top">
<td>

**Build Your First Zarf**

</td>
<td>

You've got a development workstation setup, so... now what? Why not _build your own Zarf_? Step-by-step instructions, here.

</td>
Expand All @@ -213,12 +213,12 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<!-- row start -->
<tr valign="top">
<td>

**Contribution Guide**

</td>
<td>

As with most collaborative efforts there are guidelines for contributing to the project. Find out what they are & how to make them work, here.

</td>
Expand Down Expand Up @@ -251,12 +251,12 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<td width="150">

**Supported OSes**

</td>
<td>

Zarf is intended to run on a variety of Operating Systems&mdash;you can find out which _and_ discover how to take Zarf for a test-drive (in a VM of your favorite flavor) by clicking the link!

</td>
<td>

Expand All @@ -271,14 +271,14 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<td>

**Zarf Components**

</td>
<td>

Need to understand what's happening in your cluster? Zarf can give you visibility by injecting a _Logging_ component. Looking for some additional CLI tooling? Install the _Management_ component.

Find out all the other stuff Zarf offers, here.

</td>
<td>

Expand All @@ -293,12 +293,12 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<td>

**Usage Examples**

</td>
<td>

There are a bunch of interesting ways to use Zarf beyond "space-marine-ing" your way through _the_ pixel demon invasion. Browse our examples directory to find out what other neat things are available.

</td>
<td>

Expand All @@ -311,16 +311,16 @@ Zarf runs on [a bunch of operating systems](./docs/supported-oses.md) and aims t
<!-- row start -->
<tr valign="top">
<td>

**Iron Bank** <br/>

_Hardened image registry_

</td>
<td>

Zarf can build deployment packages using images pulled from pretty much anywhere... but for gov't-approved & "[hardened](https://en.wikipedia.org/wiki/Hardening_(computing))" container images check out Platform One's [Iron Bank](https://p1.dso.mil/#/products/iron-bank/).

</td>
<td>

Expand Down
2 changes: 1 addition & 1 deletion docs/asciinema/.gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
recordings/
.config/
*.log
*.log
2 changes: 1 addition & 1 deletion docs/asciinema/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ When you run `asciinema` commands, if you do not already have an `install-id` fi
If you need recordings to stick around and be listed in a specific group, however&mdash;and in this case you do&mdash;then you'll need access to an install id that has been registered with Zarf's account on asciinema.org.

> _**Dig in!**_
>
>
> Go ahead and have a look at the asciinema [usage page](https://asciinema.org/docs/usage) (under the "auth" heading) if you're interested in more detail / background on this topic.
&nbsp;
Expand Down
4 changes: 2 additions & 2 deletions docs/asciinema/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -14,10 +14,10 @@ Vagrant.configure("2") do |config|
config.vm.synced_folder '.', '/vagrant', disabled: true
config.vm.synced_folder '../..', '/zarf', SharedFoldersEnableSymlinksCreate: false
config.vm.synced_folder'./.config/asciinema', '/root/.config/asciinema',
SharedFoldersEnableSymlinksCreate: false,
SharedFoldersEnableSymlinksCreate: false,
owner: 'root', group: 'root'
config.vm.synced_folder'~/.docker', '/root/.docker',
SharedFoldersEnableSymlinksCreate: false,
SharedFoldersEnableSymlinksCreate: false,
owner: 'root', group: 'root'

config.ssh.insert_key = false
Expand Down
2 changes: 1 addition & 1 deletion docs/asciinema/asciinema-org
Original file line number Diff line number Diff line change
@@ -1 +1 @@
https://asciinema.org/~barrett
https://asciinema.org/~barrett
10 changes: 5 additions & 5 deletions docs/asciinema/asciinema.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ function help() {
echo ""
}

# executes (and records) a given scenario file's terminal session
# executes (and records) a given scenario file's terminal session
function run() {
local fname="${1##*/}"
local fpath="$SCENARIOS/$fname"
Expand Down Expand Up @@ -165,7 +165,7 @@ function sub() {
local lines="$( printf '%.0s- ' {1..12} )"
local found="$( cat - | paste -d '\t' $lines )" # <-- reads stdin!
local clean="$( echo "$found" | tr -s ' ' | sed -E 's/: \t/: -\t/g' )"

echo "$clean" | while IFS= read -r c ; do
local sub="$( echo "$c" | grep -Po 'sub : \K[^\t]*' )"
if [ "$sub" = "no" ] ; then continue ; fi
Expand Down Expand Up @@ -238,7 +238,7 @@ function zap() {
plan="$plan$r"$'\t'"$verdict"$'\n'
done <<< "$recordings"
plan="${plan::-1}"

# act on the plan?
echo ""
echo "$plan"
Expand All @@ -259,7 +259,7 @@ function zap() {

echo "$plan" | grep -P 'delete$' | while IFS= read -r p ; do
local path="$( echo "$p" | awk -F $'\t' '{print $2}' )"

# secure a csrf token via "get" request
local get="$( cat "$HERE/get.tmpl.curl" \
| sed 's|{{path}}|'"$path"'|g' \
Expand Down Expand Up @@ -300,7 +300,7 @@ case "$cmd" in
"run")
if [ "$#" -lt 1 ] || [ "$1" = "all" ] ; then run_all ; else run "$@" ; fi
;;

"pub")
if [ "$#" -lt 1 ] || [ "$1" = "all" ] ; then pub_all ; else pub "$@" ; fi
;;
Expand Down
2 changes: 1 addition & 1 deletion docs/asciinema/delete.tmpl.curl
Original file line number Diff line number Diff line change
Expand Up @@ -17,4 +17,4 @@ curl 'https://asciinema.org{{path}}' \
-H 'accept-language: en-US,en;q=0.9' \
-H 'cookie: auth_token={{auth_token}}; _asciinema_key={{_asciinema_key}}' \
--data-raw '_csrf_token={{csrf}}&_method=delete' \
--compressed
--compressed
2 changes: 1 addition & 1 deletion docs/asciinema/get.tmpl.curl
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@ curl 'https://asciinema.org{{path}}' \
-H 'referer: {{account}}' \
-H 'accept-language: en-US,en;q=0.9' \
-H 'cookie: auth_token={{auth_token}}; _asciinema_key={{_asciinema_key}}' \
--compressed
--compressed
1 change: 0 additions & 1 deletion docs/asciinema/scenarios/asciinema-demo.exp
Original file line number Diff line number Diff line change
Expand Up @@ -55,4 +55,3 @@ comment "Great. Let's say hi."
do "./zarf help"

comment "Perfect!"

2 changes: 1 addition & 1 deletion docs/components.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,4 +39,4 @@ These optional components are listed below along with the "magic strings" you pa

## Further reading

For more detail&mdash;like which components are on/off by default&mdash;there's no better place to check than the source: [zarf.yaml](../zarf.yaml).
For more detail&mdash;like which components are on/off by default&mdash;there's no better place to check than the source: [zarf.yaml](../zarf.yaml).
4 changes: 2 additions & 2 deletions docs/ironbank.md
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ In order to figure out what your personal "CLI secret" is you first need to log
Then, pop open your "User Profile" and copy down your `Username` and `CLI secret`.

> _**Take note**_
>
>
> You need your **Username** specifically&mdash;trying to log Zarf into Iron Bank using Email will not work!
&nbsp;
Expand All @@ -58,4 +58,4 @@ Zarf will dump an auth file into your user home directory&mdash;`$HOME/.docker/c

> _**Beware!**_
>
> This file contains your personal credentials for interacting with Iron Bank and _could be used to impersonate you_. Make sure to keep this file safe!
> This file contains your personal credentials for interacting with Iron Bank and _could be used to impersonate you_. Make sure to keep this file safe!
2 changes: 1 addition & 1 deletion docs/supported-oses.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,4 @@ Closing out the demo environment is _also_ a single command:
make vm-destroy
```

This will shutdown & destroy _all_ the demo VM instances it can find. Easy-peasy&mdash;nice and clean.
This will shutdown & destroy _all_ the demo VM instances it can find. Easy-peasy&mdash;nice and clean.
8 changes: 4 additions & 4 deletions docs/workstation.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,15 +18,15 @@ The simplest path to Zarf is to download a pre-built release and execute it on y
1. Download:

- The zarf cluster initialization package: `zarf-init.tar.zst`.

- The appropriate zarf binary for your system (choose _one_):

| system | binary |
| --- | --- |
| --- | --- |
| Linux (64bit) | `zarf` |
| Intel-based Mac | `zarf-mac-intel` |
| [Apple-based Mac](https://support.apple.com/en-us/HT211814) | `zarf-mac-apple` |

- (optional) The checksum file: `zarf.sha256`.

1. (optional) Verify integrity of the downloaded files by validating their hashes&mdash;more about that ( [here](https://en.wikipedia.org/wiki/Checksum) / [here](https://help.ubuntu.com/community/HowToSHA256SUM) ) if you're interested. From _the directory holding your files_, run:
Expand All @@ -53,7 +53,7 @@ chmod +x ./zarf && ./zarf help
```

> _**Take note**_
>
>
> Commands run this way _will_ make changes to your current system / environment!
>
>This is the expected usage pattern for production but for demonstration / development & test there are better, **virtual machine**-isolated ways to run Zarf. Keep reading to find out how to get setup for those!
Expand Down
2 changes: 1 addition & 1 deletion examples/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,4 +4,4 @@ The Zarf examples demonstrate different ways to utilize Zarf in your environment

To test create a virtual area to test all examples, you can run `make all` or `make vm-init` if you've already run the examples before. Run `make vm-destroy` to clean up.

> **NOTE**: This tool utilizes software pulled from multiple sources and _some_ of them require authenticated access! Check the examples themselves for the specific accounts / logins required!
> **NOTE**: This tool utilizes software pulled from multiple sources and _some_ of them require authenticated access! Check the examples themselves for the specific accounts / logins required!
4 changes: 2 additions & 2 deletions examples/game/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ zarf init
Answer the follow-on prompts as appropriate for your machine configuration & give it a few seconds to run.

Congratulations! Your machine is now a single node k8s cluster!

> _**Note**_
>
> Zarf supports fire-and-forget installs too! Give `zarf init --help` a call for more details on that.
Expand Down Expand Up @@ -237,4 +237,4 @@ It only takes a couple moments for the _entire Zarf cluster_ to disappear&mdash;
- https://www.reddit.com/r/programming/comments/nap4pt/dos_gaming_in_docker/
- https://earthly.dev/blog/dos-gaming-in-docker/
- https://earthly.dev/blog/dos-gaming-in-docker/
Loading

0 comments on commit 1182466

Please sign in to comment.