Skip to content

Commit 4d86879

Browse files
authored
Improve capitalization and formats of README.md. (roboll#1545)
1 parent 1aca099 commit 4d86879

File tree

3 files changed

+55
-44
lines changed

3 files changed

+55
-44
lines changed

.editorconfig

+5
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
root = true
2+
3+
[*.md]
4+
insert_final_newline = true
5+
trim_trailing_whitespace = true

PATHS.md

+12-10
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,50 @@
1-
# Paths Overivew
2-
Using manifest files in conjunction with command line argument can be a bit confusing.
1+
# Paths Overivew
32

4-
A few rules to clear up this ambiguity:
3+
Using manifest files in conjunction with command line argument can be a bit confusing.
4+
5+
A few rules to clear up this ambiguity:
56

67
- Absolute paths are always resolved as absolute paths
78
- Relative paths referenced *in* the helmfile manifest itself are relative to that manifest
89
- Relative paths referenced on the command line are relative to the current working directory the user is in
910

1011
### Examples
11-
There are several examples that we can go through in the `/examples` folder which demonstrate this.
12+
13+
There are several examples that we can go through in the [`/examples`](examples) folder which demonstrate this.
1214

1315
**Local Execution**
1416

15-
This is an example of a Helmfile manifest referencing a local value directly.
17+
This is an example of a Helmfile manifest referencing a local value directly.
1618

1719
Indirect:
1820
```
1921
helmfile -f examples/deployments/local/charts.yaml sync
2022
```
2123

22-
Direct:
24+
Direct:
2325
```
2426
cd examples/deployments/local/
2527
helmfile sync
2628
```
2729

2830
**Relative Paths in Helmfile**
2931

30-
This is an example of a Helmfile manifest using relative paths for values.
32+
This is an example of a Helmfile manifest using relative paths for values.
3133

3234
Indirect:
3335
```
3436
helmfile -f examples/deployments/dev/charts.yaml sync
3537
```
3638

37-
Direct:
39+
Direct:
3840
```
3941
cd examples/deployments/dev/
4042
helmfile sync
4143
```
4244

4345
**Relative Paths in Helmfile w/ --values overrides**
4446

45-
This is an example of a Helmfile manifest using relative paths for values including an additional `--values` from the command line.
47+
This is an example of a Helmfile manifest using relative paths for values including an additional `--values` from the command line.
4648

4749
NOTE: The `--values` is resolved relative to the CWD of the terminal *not* the Helmfile manifest. You can see this with the `replicas` being adjusted to 3 now for the deployment.
4850

@@ -51,7 +53,7 @@ Indirect:
5153
helmfile -f examples/deployments/dev/charts.yaml sync --values values/replica-values.yaml
5254
```
5355

54-
Direct:
56+
Direct:
5557
```
5658
cd examples/deployments/dev/
5759
helmfile sync --values ../../values/replica-values.yaml

README.md

+38-34
Original file line numberDiff line numberDiff line change
@@ -351,15 +351,15 @@ releases:
351351

352352
If you wish to treat your enviroment variables as strings always, even if they are boolean or numeric values you can use `{{ env "ENV_NAME" | quote }}` or `"{{ env "ENV_NAME" }}"`. These approaches also work with `requiredEnv`.
353353

354-
## installation
354+
## Installation
355355

356356
- download one of [releases](https://github.com/roboll/helmfile/releases) or
357357
- run as a [container](https://quay.io/roboll/helmfile) or
358358
- install from [AUR](https://aur.archlinux.org/packages/kubernetes-helmfile-bin/) for Archlinux or
359359
- Windows (using [scoop](https://scoop.sh/)): `scoop install helmfile`
360360
- macOS (using [homebrew](https://brew.sh/)): `brew install helmfile`
361361

362-
## getting started
362+
## Getting Started
363363

364364
Let's start with a simple `helmfile` and gradually improve it to fit your use-case!
365365

@@ -389,7 +389,7 @@ Iterate on the `helmfile.yaml` by referencing:
389389
- [CLI reference](#cli-reference).
390390
- [Helmfile Best Practices Guide](https://github.com/roboll/helmfile/blob/master/docs/writing-helmfile.md)
391391

392-
## cli reference
392+
## CLI Reference
393393

394394
```
395395
NAME:
@@ -496,7 +496,6 @@ The `helmfile delete` sub-command deletes all the releases defined in the manife
496496
497497
Note that `delete` doesn't purge releases. So `helmfile delete && helmfile sync` results in sync failed due to that releases names are not deleted but preserved for future references. If you really want to remove releases for reuse, add `--purge` flag to run it like `helmfile delete --purge`.
498498
499-
500499
### secrets
501500
502501
The `secrets` parameter in a `helmfile.yaml` causes the [helm-secrets](https://github.com/futuresimple/helm-secrets) plugin to be executed to decrypt the file.
@@ -516,6 +515,7 @@ Use `--cleanup` to delete pods upon completion.
516515
The `helmfile lint` sub-command runs a `helm lint` across all of the charts/releases defined in the manifest. Non local charts will be fetched into a temporary folder which will be deleted once the task is completed.
517516
518517
## Paths Overview
518+
519519
Using manifest files in conjunction with command line argument can be a bit confusing.
520520
521521
A few rules to clear up this ambiguity:
@@ -524,9 +524,10 @@ A few rules to clear up this ambiguity:
524524
- Relative paths referenced *in* the Helmfile manifest itself are relative to that manifest
525525
- Relative paths referenced on the command line are relative to the current working directory the user is in
526526
527-
For additional context, take a look at [paths examples](PATHS.md)
527+
For additional context, take a look at [paths examples](PATHS.md).
528528
529529
## Labels Overview
530+
530531
A selector can be used to only target a subset of releases when running Helmfile. This is useful for large helmfiles with releases that are logically grouped together.
531532
532533
Labels are simple key value pairs that are an optional field of the release spec. When selecting by label, the search can be inverted. `tier!=backend` would match all releases that do NOT have the `tier: backend` label. `tier=fronted` would only match releases with the `tier: frontend` label.
@@ -535,7 +536,7 @@ Multiple labels can be specified using `,` as a separator. A release must match
535536
536537
The `selector` parameter can be specified multiple times. Each parameter is resolved independently so a release that matches any parameter will be used.
537538
538-
`--selector tier=frontend --selector tier=backend` will select all the charts
539+
`--selector tier=frontend --selector tier=backend` will select all the charts.
539540
540541
In addition to user supplied labels, the name, the namespace, and the chart are available to be used as selectors. The chart will just be the chart name excluding the repository (Example `stable/filebeat` would be selected using `--selector chart=filebeat`).
541542
@@ -544,7 +545,7 @@ For instance, you install a number of charts on every customer but need to provi
544545
545546
templates/common.yaml:
546547
547-
```
548+
```yaml
548549
templates:
549550
nginx: &nginx
550551
name: nginx
@@ -563,7 +564,7 @@ templates:
563564

564565
helmfile.yaml:
565566

566-
```
567+
```yaml
567568
{{ readFile "templates/common.yaml" }}
568569

569570
commonLabels:
@@ -984,14 +985,14 @@ that is accessible by running a command:
984985

985986
A usual usage of `exec` would look like this:
986987

987-
```
988+
```yaml
988989
mysetting: |
989990
{{ exec "./mycmd" (list "arg1" "arg2" "--flag1") | indent 2 }}
990991
```
991992

992993
Or even with a pipeline:
993994

994-
```
995+
```yaml
995996
mysetting: |
996997
{{ yourinput | exec "./mycmd-consume-stdin" (list "arg1" "arg2") | indent 2 }}
997998
```
@@ -1037,7 +1038,7 @@ This is the counterpart to `prepare`, as any release on which `prepare` has been
10371038

10381039
The following is an example hook that just prints the contextual information provided to hook:
10391040

1040-
```
1041+
```yaml
10411042
releases:
10421043
- name: myapp
10431044
chart: mychart
@@ -1072,10 +1073,11 @@ For templating, imagine that you created a hook that generates a helm chart on-t
10721073
It will allow you to write your helm releases with any language you like, while still leveraging goodies provided by helm.
10731074
10741075
### Global Hooks
1076+
10751077
In contrast to the per release hooks mentioned above these are run only once at the very beginning and end of the execution of a helmfile command and only the `prepare` and `cleanup` hooks are available respectively.
10761078
10771079
They use the same syntax as per release hooks, but at the top level of your helmfile:
1078-
``` yaml
1080+
```yaml
10791081
hooks:
10801082
- events: ["prepare", "cleanup"]
10811083
showlogs: true
@@ -1146,17 +1148,17 @@ We also have dedicated documentation on the following topics which might interes
11461148

11471149
Or join our friendly slack community in the [`#helmfile`](https://slack.sweetops.com) channel to ask questions and get help. Check out our [slack archive](https://archive.sweetops.com/helmfile/) for good examples of how others are using it.
11481150

1149-
## Using env files
1151+
## Using .env files
11501152

1151-
Helmfile itself doesn't have an ability to load env files. But you can write some bash script to achieve the goal:
1153+
Helmfile itself doesn't have an ability to load .env files. But you can write some bash script to achieve the goal:
11521154

11531155
```console
11541156
set -a; . .env; set +a; helmfile sync
11551157
```
11561158

11571159
Please see #203 for more context.
11581160

1159-
## Running helmfile interactively
1161+
## Running Helmfile interactively
11601162

11611163
`helmfile --interactive [apply|destroy]` requests confirmation from you before actually modifying your cluster.
11621164

@@ -1170,29 +1172,14 @@ Once you download all required charts into your machine, you can run `helmfile c
11701172
It basically run only `helm upgrade --install` with your already-downloaded charts, hence no Internet connection is required.
11711173
See #155 for more information on this topic.
11721174

1173-
## Experimental features
1175+
## Experimental Features
1176+
11741177
Some experimental features may be available for testing in perspective of being (or not) included in a future release.
11751178
Those features are set using the environment variable `HELMFILE_EXPERIMENTAL`. Here is the current experimental feature :
11761179
* `explicit-selector-inheritance` : remove today implicit cli selectors inheritance for composed helmfiles, see [composition selector](#selectors)
11771180

11781181
If you want to enable all experimental features set the env var to `HELMFILE_EXPERIMENTAL=true`
11791182

1180-
## Azure ACR integration
1181-
1182-
Azure offers helm repository [support for Azure Container Registry](https://docs.microsoft.com/en-us/azure/container-registry/container-registry-helm-repos) as a preview feature.
1183-
1184-
To use this you must first `az login` and then `az acr helm repo add -n <MyRegistry>`. This will extract a token for the given ACR and configure `helm` to use it, e.g. `helm repo update` should work straight away.
1185-
1186-
To use `helmfile` with ACR, on the other hand, you must either include a username/password in the repository definition for the ACR in your `helmfile.yaml` or use the `--skip-deps` switch, e.g. `helmfile template --skip-deps`.
1187-
1188-
An ACR repository definition in `helmfile.yaml` looks like this:
1189-
1190-
```
1191-
repositories:
1192-
- name: <MyRegistry>
1193-
url: https://<MyRegistry>.azurecr.io/helm/v1/repo
1194-
```
1195-
11961183
## Examples
11971184

11981185
For more examples, see the [examples/README.md](https://github.com/roboll/helmfile/blob/master/examples/README.md) or the [`helmfile`](https://github.com/cloudposse/helmfiles/tree/master/releases) distribution by [Cloud Posse](https://github.com/cloudposse/).
@@ -1202,6 +1189,7 @@ For more examples, see the [examples/README.md](https://github.com/roboll/helmfi
12021189
- [renovate](https://github.com/renovatebot/renovate) automates chart version updates. See [this PR for more information](https://github.com/renovatebot/renovate/pull/5257).
12031190
- For updating container image tags and git tags embedded within helmfile.yaml and values, you can use [renovate's regexManager](https://docs.renovatebot.com/modules/manager/regex/). Please see [this comment in the renovate repository](https://github.com/renovatebot/renovate/issues/6130#issuecomment-624061289) for more information.
12041191
- [ArgoCD Integration](#argocd-integration)
1192+
- [Azure ACR Integration](#azure-acr-integration)
12051193

12061194
### ArgoCD Integration
12071195

@@ -1235,7 +1223,7 @@ git push origin $BRANCH
12351223

12361224
> Note that `$(pwd)` is necessary when `hemlfile.yaml` has one or more sub-helmfiles in nested directories,
12371225
> because setting a relative file path in `--output-dir` or `--output-dir-template` results in each sub-helmfile render
1238-
> to the directory relative to the specified path.
1226+
> to the directory relative to the specified path.
12391227
12401228
so that they can be deployed by Argo CD as usual.
12411229

@@ -1252,7 +1240,23 @@ Recommendations:
12521240
- If you don't directly push it to the main Git branch and instead go through a pull-request, do lint rendered manifests on your CI, so that you can catch easy mistakes earlier/before ArgoCD finally deploys it
12531241
- See [this ArgoCD issue](https://github.com/argoproj/argo-cd/issues/2143#issuecomment-570478329) for why you may want this, and see [this helmfile issue](https://github.com/roboll/helmfile/pull/1357) for how `--output-dir-template` works.
12541242

1255-
# Attribution
1243+
### Azure ACR Integration
1244+
1245+
Azure offers helm repository [support for Azure Container Registry](https://docs.microsoft.com/en-us/azure/container-registry/container-registry-helm-repos) as a preview feature.
1246+
1247+
To use this you must first `az login` and then `az acr helm repo add -n <MyRegistry>`. This will extract a token for the given ACR and configure `helm` to use it, e.g. `helm repo update` should work straight away.
1248+
1249+
To use `helmfile` with ACR, on the other hand, you must either include a username/password in the repository definition for the ACR in your `helmfile.yaml` or use the `--skip-deps` switch, e.g. `helmfile template --skip-deps`.
1250+
1251+
An ACR repository definition in `helmfile.yaml` looks like this:
1252+
1253+
```yaml
1254+
repositories:
1255+
- name: <MyRegistry>
1256+
url: https://<MyRegistry>.azurecr.io/helm/v1/repo
1257+
```
1258+
1259+
## Attribution
12561260
12571261
We use:
12581262

0 commit comments

Comments
 (0)