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

Commit26f787a

Browse files
committed
Update codefresh-runner.md
1 parentd517670 commit26f787a

File tree

1 file changed

+48
-21
lines changed

1 file changed

+48
-21
lines changed

‎_docs/administration/codefresh-runner.md‎

Lines changed: 48 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
22
title:"Codefresh Runner"
3-
description:"Run Codefresh pipelines on your private Kubernetes cluster"
3+
description:"Install Runner to run Codefresh pipelines on your private Kubernetes cluster"
44
group:administration
55
redirect_from:
66
-/docs/enterprise/codefresh-runner/
@@ -33,7 +33,7 @@ Install the Runner from any workstation or laptop with access to the Kubernetes
3333
You_must_ install the Codefresh Runner on_every cluster that runs Codefresh pipelines_.
3434
The Runner is**not** needed in clusters used for_deployment_, as you can deploy applications on clusters without the Runner.
3535
<br />
36-
Access to the Codefresh CLI is only needed when installing the Codefresh Runner. After installation, the Runnerthenauthenticates onit own using the details provided. You don't need to install the Codefresh CLI on the cluster running Codefresh pipelines.
36+
Access to the Codefresh CLI is only needed when installing the Codefresh Runner. After installation, the Runner authenticates onits own using the details provided. You don't need to install the Codefresh CLI on the cluster running Codefresh pipelines.
3737

3838
Use any of the following options to install the Codefresh Runner:
3939
*[Install Codefresh Runner with CLI Wizard](#install-runner-with-cli-wizard)
@@ -47,8 +47,6 @@ If the Kubernetes cluster with the Codefresh Runner is behind a proxy server, [c
4747
<!--Questions: Add prereq to authenticate the CLI using the token and everything about the token-->
4848

4949

50-
Access to the Codefresh CLI is only needed during the Runner installation. After that, the Runner will authenticate on it own using the details provided. You do NOT need to install the Codefresh CLI on the cluster that is running Codefresh pipelines.
51-
5250
During installation, you can see which API token will be used by the runner (if you don't provide one). The printed token includes the permissions used by the Runner to communicate with the Codefresh platform and run pipelines. If you save the token, even if or when you delete the deployment, you can use the same token to restore the Runner's permissions without having to re-install the Codefresh Runner.
5351

5452
>Generate your API Key from your[user settings page](https://g.codefresh.io/user/settings).
@@ -426,7 +424,9 @@ codefresh runner init --values values-ebs.yaml --exec-demo-pipeline false --skip
426424
427425
### GKE (Google Kubernetes Engine) backend volume configuration
428426
429-
427+
GKE volume configuration includes:
428+
* [Local SSD storage configuration](#local-ssd-storage-configuration)
429+
* [GCE disk storage configuration](#gce-disk-storage-configuration)
430430
431431
#### Local SSD storage configuration
432432
@@ -509,29 +509,23 @@ The Codefresh Runner does not currently support [Regional Persistent Disks](http
509509
510510
### Configure internal registry mirror
511511
512-
You can configure your Codefresh Runner to use an internal registry as a mirror for any container images that are mentioned in your pipelines.
513-
514-
First set up an internal registry as described in [https://docs.docker.com/registry/recipes/mirror/](https://docs.docker.com/registry/recipes/mirror/).
515-
516-
Then locate the`codefresh-dind-config` config map in the namespace that houses the runner and edit it.
512+
You can configure your Codefresh Runner to use an internal registry as a mirror for any container images that are specified in your pipelines.
517513
514+
1. Set up an internal registry as described in [https://docs.docker.com/registry/recipes/mirror/](https://docs.docker.com/registry/recipes/mirror/).
515+
1. Locate the`codefresh-dind-config` config map in the namespace that houses the Runner.
518516
```shell
519517
kubectl -n codefresh edit configmap codefresh-dind-config
520518
```
521-
522-
Change the`data` field from:
523-
519+
1. Add the line`\ \"registry-mirrors\": [\"https://<my-docker-mirror-host>\" ],\n` to define the single registry to use as a mirror to`data` after the`tlskey`:
520+
<!--->
524521
```yaml
525522
data:
526523
daemon.json:"{\n\"hosts\": [\"unix:///var/run/docker.sock\",\n\"tcp://0.0.0.0:1300\"],\n
527524
\\"storage-driver\":\"overlay2\",\n\"tlsverify\": true, \n\"tls\": true,\n
528525
\\"tlscacert\":\"/etc/ssl/cf-client/ca.pem\",\n\"tlscert\":\"/etc/ssl/cf/server-cert.pem\",\n
529526
\\"tlskey\":\"/etc/ssl/cf/server-key.pem\",\n\"insecure-registries\" : [\"192.168.99.100:5000\"],\n
530527
\\"metrics-addr\" :\"0.0.0.0:9323\",\n\"experimental\" : true\n}\n"
531-
```
532-
533-
to
534-
528+
``` -->
535529
```yaml
536530
data:
537531
daemon.json:"{\n\"hosts\": [\"unix:///var/run/docker.sock\",\n\"tcp://0.0.0.0:1300\"],\n
@@ -541,10 +535,43 @@ data:
541535
\\"registry-mirrors\": [\"https://<my-docker-mirror-host>\" ], \n
542536
\\"metrics-addr\" :\"0.0.0.0:9323\",\n\"experimental\" : true\n}\n"
543537
```
538+
1. Save and quit by typing`:wq`.
539+
540+
Now any container image used in your pipeline and isn't fully qualified, will be pulled through the Docker registry that is configured as a mirror.
541+
542+
### Add custom labels to dind and engine pods
543+
Add custom labels to your Engine and Dind pods in Runtime Environment (RE) by patching it.
544+
545+
1. Get the configuration of the RE and place it in a file named`runtime.yaml`.
546+
`codefresh get runtime-environments -o yaml<$RUNTIME_ENVIRONMENT>> runtime.yaml`
547+
where:
548+
`$RUNTIME_ENVIRONMENT` must be replaced with the name of your RE.
549+
1. Edit the`dockerDaemonScheduler.labels` or`runtimeScheduler.labels` property of`runtime.yaml` to include the label, as in the example below.
550+
>If the`dockerDaemonScheduler.labels` are not included in the RE configuration by default, add them.
551+
```yaml
552+
version: 1
553+
metadata:
554+
[...]
555+
runtimeScheduler:
556+
labels:
557+
my-custom-ENGINE-label:"true"
558+
cluster:
559+
[...]
560+
dockerDaemonScheduler:
561+
cluster:
562+
[...]
563+
annotations: {}
564+
labels:
565+
my-custom-DIND-label:"true"
566+
[...]
567+
```
568+
1. Patch the runtime environment:
569+
`codefresh patch re$RUNTIME_ENVIRONMENT -f runtime.yaml`
570+
where:
571+
`$RUNTIME_ENVIRONMENT` must be replaced with the name of your RE.
544572
545-
This adds the line`\ \"registry-mirrors\": [\"https://<my-docker-mirror-host>\" ],\n` which contains a single registry to use as a mirror. Quit and Save by typing`:wq`.
573+
Once you have applied the patch, future builds include the label preventing eviction.
546574
547-
Now any container image that is used in your pipeline and isn't fully qualified, will be pulled through the Docker registry that is configured as a mirror.
548575
549576
## View Codefresh Runner and runtime environments
550577
@@ -567,7 +594,7 @@ Once installed, the Runner polls Codefresh every three seconds by default to aut
567594
568595
### Select a default runtime environment
569596
570-
If you have multiple runtime environments, select the one to use as the default environment. The default runtime environment is usedfor all pipelines in the account.
597+
If you have multiple runtime environments, select the one to use as the default environmentfor all the pipelines in the account.
571598
572599
* From the list of [Runtime Environments](https://g.codefresh.io/account-admin/account-conf/runtime-environments){:target="\_blank"}, click the context menu of the runtime to set as the default.
573600
* Select **Set as Default**.
@@ -665,7 +692,7 @@ Codefresh pipelines require disk space for:
665692
666693
Codefresh offers two options to manage disk space and prevent out-of-space errors:
667694
* Use runtime cleaners on Docker images and volumes
668-
* [Set the disk space per pipeline build volume]({{site.baseurl}}/docs/configure-ci-cd-pipeline/pipelines/#runtime)
695+
* [Set theminimumdisk space per pipeline build volume]({{site.baseurl}}/docs/configure-ci-cd-pipeline/pipelines/#runtime)
669696
670697
<!--- not sure where this fits in -->
671698
To improve performance by using Docker cache and decreasing I/O rate,`volume-provisioner` can provision previously used disks with Docker images and pipeline volumes from previously run builds.

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp