Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commitaffd506

Browse files
committed
Update hybrid-gitops-helm-installation.md
Restructured according to feedback
1 parent1a140a2 commitaffd506

File tree

1 file changed

+145
-138
lines changed

1 file changed

+145
-138
lines changed

‎_docs/installation/gitops/hybrid-gitops-helm-installation.md‎

Lines changed: 145 additions & 138 deletions
Original file line numberDiff line numberDiff line change
@@ -7,96 +7,41 @@ redirect_from:
77
toc:true
88
---
99

10-
Install the Hybrid Runtime for GitOps through a Helm chart.
11-
1210
>**ATTENTION**:
13-
We have transitioned to a Helm-based installation for Hybrid GitOps Runtimes for improved experience and performance,and is now the default Runtime for GitOps.
11+
We have transitioned to a Helm-based installation for Hybrid GitOps Runtimes for improved experience and performance,which is now the default Runtime for GitOps.
1412
The[CLI-based installation for Hybrid GitOps]({{site.baseurl}}/docs/installation/gitops/hybrid-gitops/) is now considered legacy.
1513
We will deprecate this installation mode permanently in the coming months. Please stay tuned for further updates and instructions, including the migration process.
1614

1715

18-
If you already have a Codefresh acccount, go for the[quick Helm install](#quick-helm-install-for-hybrid-gitops-runtime).
19-
20-
For step-by-step installation from the Codefresh UI, see[Step-by-step Hybrid GitOps Runtime installation](#step-by-step-hybrid-gitops-runtime-installation).
21-
22-
23-
##ArgoCD password
24-
25-
>**WARNING**:
26-
Do not change the ArgoCD password by logging into the ArgoCD UI with the`argocd-initial-admin-secret`.
27-
Changing the ArgoCD password can result in system instability, and disrupt the proper functioning of the Codefresh platform.
28-
29-
##Quick Helm install for Hybrid GitOps Runtime
30-
31-
Install the Hybrid GitOps Runtime via Helm with the default tunnel-based access mode. You will copy the Helm install command from the UI to get the values that Codefresh automatically retrieves for you such as your account ID, and then run the command.
32-
33-
The Codefresh`values.yaml` is located[here](https://github.com/codefresh-io/gitops-runtime-helm/blob/main/charts/gitops-runtime/){:target="\_blank"}. It contains all the arguments that can be configured, including optional ones.
34-
35-
###Before running quick install
36-
37-
**Notes & assumptions**
38-
Quick installation assumes that:
39-
* You have set up a Git provider and the Shared Configuration Repository for your account. If these are not defined, you can define them_after_ installation from the Codefresh UI, when prompted to do so.
40-
See[Update Git credentials for GitOps Runtimes]({{site.baseurl}}/docs/installation/gitops/monitor-manage-runtimes/#update-git-credentials-for-gitops-runtimes) and[Shared Configuration Repository]({{site.baseurl}}/docs/installation/gitops/shared-configuration/).
41-
* Your cluster does not have[Argo project components & CRDs](#argo-project-components--crds).
42-
43-
44-
**Automated validation**
45-
Codefresh automatically validates the`values` file before initiating the installation. If there is a validation failure, Codefresh terminates the installation.
46-
47-
* Validation failures
48-
To get more details on the reasons for the failure, run:
49-
`kubectl logs jobs/validate-values -n ${NAMESPACE}`
50-
where:
51-
*`{NAMESPACE}` must be replaced with the namespace of the Hybrid GitOps Runtime.
52-
53-
* To disable automated validation, add`--set installer.skipValidation=true` to the install command.
54-
55-
For more details, see[Step 1: (Optional) Validate Helm values file](#step-1-optional-validate-helm-values-file) in this article.
16+
Install Hybrid Runtimes for GitOps in Codefresh accounts through Helm charts.
5617

57-
###Copy & run Helm installation command
5818

59-
1. In the Codefresh UI, go to[Install Hybrid GitOps Runtime](https://g.codefresh.io/2.0/account-settings/runtimes/info/list?drawer=install-codefresh-runtime){:target="\_blank"}.
60-
1. Copy the command in_Step 4_ and define the values that are not automatically populated.
61-
62-
{% include
63-
image.html
64-
lightbox="true"
65-
file="/images/runtime/hybrid-helm-quick-install-copy-values.png"
66-
url="/images/runtime/hybrid-helm-quick-install-copy-values.png"
67-
alt="Copy command with automatically populated values from UI"
68-
caption="Copy command with automatically populated values from UI"
69-
max-width="40%"
70-
%}
19+
***First-time GitOps Runtime installation**
20+
If you are installing the first GitOps Runtime in a Codefresh account, make sure you the complete the[pre-requisites](#prepare-for-gitops-runtime-installation) and meet[system requirements](#minimum-system-requirements), before starting the installation. Then follow our[step-by-step guide](#install-first-gitops-runtime-in-account) to complete the installation through the Codefresh UI.
7121

22+
***Installing additional Runtimes in account**
23+
If you have already installed a GitOps Runtime in your account, as you have already set up the Git provider and Shared Configuration Repository for your accounts, you can go to our[quick install](#install-additional-gitops-runtimes-in-account) section.
24+
7225

73-
where:
74-
*`<helm-release-name>` is the name of the Helm release, and is either the default`cf-gitops-runtime`, or any custom release name that you define.
75-
*`<namespace>` is the namespace in which to install the Hybrid GitOps runtime, and is either`codefresh` which is the default, or any custom name that you define.
76-
*`<codefresh-account-id>` is mandatory only for_tunnel-based Hybrid GitOps Runtimes_ which is also the default access mode. Automatically populated by Codefresh in the command.
77-
*`<codefresh-token>` is the API key, either an existing one or the new API key you generated. When generated, it is automatically populated in the command.
78-
*`<runtime-name>` is the name of the runtime, either`codefresh` which is the default, or a custom name that you define.
79-
*`<helm-repo-chart-name>` is the name of the repo in which to add the Helm chart, and is either`cf-gitops-runtime` which is the default, or any custom name you define.
80-
*`--wait` waits until all the pods are up and running for the deployment.
8126

27+
##Prepare for GitOps Runtime installation
8228

8329

84-
##Argo project components & CRDs
30+
###Argo project components & CRDs
8531
Hybrid GitOps installation requires a cluster without Argo project components and CRDs.
8632

87-
Argo project components include Argo Rollouts, Argo CD, Argo Events, and Argo Workflows.
88-
89-
You can handle Argo project CRDs outside the chart, or as recommended, adopt the CRDs to be managed by the GitOps Runtime Helm release.
33+
* Argo project components include Argo Rollouts, Argo CD, Argo Events, and Argo Workflows.
9034

91-
If you already have Argo project CRDs on your cluster, do one of the following:
92-
* Handle Argo projects CRDs outside of the chart (see[Argo's readme on Helm charts](https://github.com/argoproj/argo-helm/blob/main/README.md){:target="\_blank"})
93-
Disable CRD installation under the relevant section for each of the Argo projects in the Helm chart:<br>
94-
`--set <argo-project>.crds.install=false`<br>
95-
where:<br>
96-
`<argo-project>` is the argo project component:`argo-cd`,`argo-workflows`,`argo-rollouts` and`argo-events`.
35+
* You can handle Argo project CRDs outside the chart, or as recommended, adopt the CRDs to be managed by the GitOps Runtime Helm release.
36+
If you already have Argo project CRDs on your cluster, do one of the following:
37+
* Handle Argo projects CRDs outside of the chart (see[Argo's readme on Helm charts](https://github.com/argoproj/argo-helm/blob/main/README.md){:target="\_blank"})
38+
Disable CRD installation under the relevant section for each of the Argo projects in the Helm chart:<br>
39+
`--set <argo-project>.crds.install=false`<br>
40+
where:<br>
41+
`<argo-project>` is the argo project component:`argo-cd`,`argo-workflows`,`argo-rollouts` and`argo-events`.
9742

98-
* Adopt the CRDs<br>
99-
Adopting the CRDs allows them to be managed by the`gitops-runtime helm release`. Doing so ensures when you upgrade the Hybrid GitOps Runtime, the CRDs are also automatically upgraded.
43+
* Adopt the CRDs<br>
44+
Adopting the CRDs allows them to be managed by the`gitops-runtime helm release`. Doing so ensures when you upgrade the Hybrid GitOps Runtime, the CRDs are also automatically upgraded.
10045

10146
Run this script_before_ installation:
10247

@@ -108,79 +53,25 @@ kubectl label --overwrite crds $(kubectl get crd | grep argoproj.io | awk '{prin
10853
kubectl annotate --overwrite crds $(kubectl get crd | grep argoproj.io | awk '{print $1}' | xargs) meta.helm.sh/release-name=$RELEASE
10954
kubectl annotate --overwrite crds $(kubectl get crd | grep argoproj.io | awk '{print $1}' | xargs) meta.helm.sh/release-namespace=$NAMESPACE
11055
```
56+
###ArgoCD password
11157

112-
##Using Terraform for installation
113-
114-
You can also use Terraform to install a Codefresh runtime with the[Helm provider](https://registry.terraform.io/providers/hashicorp/helm/latest/docs){:target="\_blank"}.
115-
116-
Here is an example
117-
118-
```hcl
119-
resource "helm_release" "my_gitops_runtime" {
120-
name = "my-codefresh-runtime"
121-
122-
repository = "https://chartmuseum.codefresh.io/gitops-runtime"
123-
chart = "gitops-runtime"
124-
namespace = "my-codefresh-runtime"
125-
version = "0.2.14"
126-
create_namespace = true
127-
set {
128-
name = "global.codefresh.accountId"
129-
value = var.cf_account_id
130-
}
131-
set {
132-
name = "global.codefresh.userToken.token"
133-
value = var.cf_token
134-
}
135-
set {
136-
name = "global.runtime.name"
137-
value = "from-terraform"
138-
}
139-
}
140-
```
141-
142-
Feel free to user a different chart version and your own runtime name. You can get both values for Codefresh token and account ID from the Codefresh UI as explained in the previous section.
143-
144-
By default the Codefresh runtime can deploy to the cluster it is installed on.
145-
You can also[use Terraform to connect additional]({{site.baseurl}}/docs/installation/gitops/managed-cluster/#add-a-managed-cluster-with-terraform) external clusters to your runtime.
58+
>**WARNING**:
59+
Do not change the Argo CD password by logging into the ArgoCD UI with the`argocd-initial-admin-secret`.
60+
Changing the Argo CD password can result in system instability, and disrupt the proper functioning of the Codefresh platform.
14661

14762

14863

14964

150-
##Image overrides for private registries
151-
If you use private registries, you need to override specific image values for the different subcharts and container images.
152-
We have a utility to help override image values for GitOps Runtimes. The utility creates values files that match the structure of the subcharts, allowing you to easily replace image registries. During chart installation, you can provide these values files to override the images, as needed.
153-
For more details, see[ArtifactHub](https://artifacthub.io/packages/helm/codefresh-gitops-runtime/gitops-runtime#using-with-private-registries---helper-utility){:target="\_blank"}.
15465

155-
##Custom repository certificates
15666

157-
Repository certificates are required to authenticate users to on-premises Git servers.
15867

159-
If your Git servers are on-premises, add the repository certificates to your Codefresh`values` file, in`.values.argo-cd`. These values are used by the argo-cd Codefresh deploys. For details on adding repository certificates, see this[section](https://github.com/codefresh-io/argo-helm/blob/argo-cd-5.29.2-cap-CR-18430/charts/argo-cd/values.yaml#LL336C7-L336C7){:target="\_blank"}.
16068

161-
{% highlight yaml %}
162-
global:
163-
codefresh:
164-
tls:
165-
caCerts:
166-
# optional - use an existing secret that contains the cert
167-
# secretKeyRef:
168-
# name: my-certificate-secret
169-
# key: ca-bundle.crt
170-
# or create "codefresh-tls-certs" secret
171-
secret:
172-
create: true
173-
content: |
174-
-----BEGIN CERTIFICATE-----
175-
...
176-
-----END CERTIFICATE-----
177-
{% endhighlight yaml %}
17869

17970

180-
##Step-by-step Hybrid GitOps Runtimeinstallation
181-
InstalltheHybrid GitOps RuntimeviaHelm from the Codefresh UI.
71+
##Install first GitOps Runtimein account
72+
To installthefirst GitOps Runtimein your Codefresh account, If this is the firstHelmRuntime install in your Codefresh account, install the Runtimefrom the Codefresh UI, following our step-by-step Hybrid GitOps Runtime installation procedure
18273

183-
The Codefresh`values.yaml`islocated[here](https://github.com/codefresh-io/gitops-runtime-helm/blob/main/charts/gitops-runtime/){:target="\_blank"}. Itcontains all the argumentsthat canbe configured, including optional ones.
74+
The Codefresh`values.yaml` located[here](https://github.com/codefresh-io/gitops-runtime-helm/blob/main/charts/gitops-runtime/){:target="\_blank"}contains all the argumentsyou canconfigure, including optional ones.
18475

18576
###Before you begin
18677
* Make sure you meet the[minimum requirements](#minimum-system-requirements) for installation
@@ -198,9 +89,6 @@ The Codefresh `values.yaml` is located [here](https://github.com/codefresh-io/gi
19889
*[Traefik ingress configuration](#traefik-ingress-configuration)
19990
<br><br>
20091

201-
202-
203-
20492
###Step 1: (Optional) Validate Helm values file
20593
Codefresh automatically validates the`values.yaml` file before initiating the installation to verify that the supplied values are correct.
20694
You also have the option to manually run the validation if desired.
@@ -493,6 +381,125 @@ That's it! You have successfully completed installing a Hybrid GitOps Runtime wi
493381
You can now add[external clusters to the Runtime]({{site.baseurl}}/docs/installation/gitops/managed-cluster/), and[create and deploy GitOps applications]({{site.baseurl}}/docs/deployments/gitops/create-application/).
494382

495383

384+
##Install additional GitOps Runtimes in account
385+
Install additional GitOps Runtimes via Helm in the same account
386+
387+
Install the Hybrid GitOps Runtime via Helm with the default tunnel-based access mode. You will copy the Helm install command from the UI to get the values that Codefresh automatically retrieves for you such as your account ID, and then run the command.
388+
389+
The Codefresh`values.yaml` is located[here](https://github.com/codefresh-io/gitops-runtime-helm/blob/main/charts/gitops-runtime/){:target="\_blank"}. It contains all the arguments that can be configured, including optional ones.
390+
391+
###Before running quick install
392+
393+
**Notes & assumptions**
394+
Quick installation assumes that:
395+
* You have set up a Git provider and the Shared Configuration Repository for your account. If these are not defined, you can define them_after_ installation from the Codefresh UI, when prompted to do so.
396+
See[Update Git credentials for GitOps Runtimes]({{site.baseurl}}/docs/installation/gitops/monitor-manage-runtimes/#update-git-credentials-for-gitops-runtimes) and[Shared Configuration Repository]({{site.baseurl}}/docs/installation/gitops/shared-configuration/).
397+
* Your cluster does not have[Argo project components & CRDs](#argo-project-components--crds).
398+
399+
400+
**Automated validation**
401+
Codefresh automatically validates the`values` file before initiating the installation. If there is a validation failure, Codefresh terminates the installation.
402+
403+
* Validation failures
404+
To get more details on the reasons for the failure, run:
405+
`kubectl logs jobs/validate-values -n ${NAMESPACE}`
406+
where:
407+
*`{NAMESPACE}` must be replaced with the namespace of the Hybrid GitOps Runtime.
408+
409+
* To disable automated validation, add`--set installer.skipValidation=true` to the install command.
410+
411+
For more details, see[Step 1: (Optional) Validate Helm values file](#step-1-optional-validate-helm-values-file) in this article.
412+
413+
##Install GitOps Runtime via Terraform
414+
415+
You can also use Terraform to install a Codefresh runtime with the[Helm provider](https://registry.terraform.io/providers/hashicorp/helm/latest/docs){:target="\_blank"}.
416+
417+
Here is an example
418+
419+
```hcl
420+
resource "helm_release" "my_gitops_runtime" {
421+
name = "my-codefresh-runtime"
422+
423+
repository = "https://chartmuseum.codefresh.io/gitops-runtime"
424+
chart = "gitops-runtime"
425+
namespace = "my-codefresh-runtime"
426+
version = "0.2.14"
427+
create_namespace = true
428+
set {
429+
name = "global.codefresh.accountId"
430+
value = var.cf_account_id
431+
}
432+
set {
433+
name = "global.codefresh.userToken.token"
434+
value = var.cf_token
435+
}
436+
set {
437+
name = "global.runtime.name"
438+
value = "from-terraform"
439+
}
440+
}
441+
```
442+
443+
Feel free to user a different chart version and your own runtime name. You can get both values for Codefresh token and account ID from the Codefresh UI as explained in the previous section.
444+
445+
By default the Codefresh runtime can deploy to the cluster it is installed on.
446+
You can also[use Terraform to connect additional]({{site.baseurl}}/docs/installation/gitops/managed-cluster/#add-a-managed-cluster-with-terraform) external clusters to your runtime.
447+
448+
###Copy & run Helm installation command
449+
450+
1. In the Codefresh UI, go to[Install Hybrid GitOps Runtime](https://g.codefresh.io/2.0/account-settings/runtimes/info/list?drawer=install-codefresh-runtime){:target="\_blank"}.
451+
1. Copy the command in_Step 4_ and define the values that are not automatically populated.
452+
453+
{% include
454+
image.html
455+
lightbox="true"
456+
file="/images/runtime/hybrid-helm-quick-install-copy-values.png"
457+
url="/images/runtime/hybrid-helm-quick-install-copy-values.png"
458+
alt="Copy command with automatically populated values from UI"
459+
caption="Copy command with automatically populated values from UI"
460+
max-width="40%"
461+
%}
462+
463+
464+
where:
465+
*`<helm-release-name>` is the name of the Helm release, and is either the default`cf-gitops-runtime`, or any custom release name that you define.
466+
*`<namespace>` is the namespace in which to install the Hybrid GitOps runtime, and is either`codefresh` which is the default, or any custom name that you define.
467+
*`<codefresh-account-id>` is mandatory only for_tunnel-based Hybrid GitOps Runtimes_ which is also the default access mode. Automatically populated by Codefresh in the command.
468+
*`<codefresh-token>` is the API key, either an existing one or the new API key you generated. When generated, it is automatically populated in the command.
469+
*`<runtime-name>` is the name of the runtime, either`codefresh` which is the default, or a custom name that you define.
470+
*`<helm-repo-chart-name>` is the name of the repo in which to add the Helm chart, and is either`cf-gitops-runtime` which is the default, or any custom name you define.
471+
*`--wait` waits until all the pods are up and running for the deployment.
472+
473+
##Post-installation GitOps Runtime configuration
474+
475+
###Image overrides for private registries
476+
If you use private registries, you need to override specific image values for the different subcharts and container images.
477+
We have a utility to help override image values for GitOps Runtimes. The utility creates values files that match the structure of the subcharts, allowing you to easily replace image registries. During chart installation, you can provide these values files to override the images, as needed.
478+
For more details, see[ArtifactHub](https://artifacthub.io/packages/helm/codefresh-gitops-runtime/gitops-runtime#using-with-private-registries---helper-utility){:target="\_blank"}.
479+
480+
##Custom repository certificates
481+
482+
Repository certificates are required to authenticate users to on-premises Git servers.
483+
484+
If your Git servers are on-premises, add the repository certificates to your Codefresh`values` file, in`.values.argo-cd`. These values are used by the argo-cd Codefresh deploys. For details on adding repository certificates, see this[section](https://github.com/codefresh-io/argo-helm/blob/argo-cd-5.29.2-cap-CR-18430/charts/argo-cd/values.yaml#LL336C7-L336C7){:target="\_blank"}.
485+
486+
{% highlight yaml %}
487+
global:
488+
codefresh:
489+
tls:
490+
caCerts:
491+
# optional - use an existing secret that contains the cert
492+
# secretKeyRef:
493+
# name: my-certificate-secret
494+
# key: ca-bundle.crt
495+
# or create "codefresh-tls-certs" secret
496+
secret:
497+
create: true
498+
content: |
499+
-----BEGIN CERTIFICATE-----
500+
...
501+
-----END CERTIFICATE-----
502+
{% endhighlight yaml %}
496503

497504
##Minimum system requirements
498505

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp