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

Commit28f2fa1

Browse files
committed
Refactor how tos
Refactored how tos 1 to 5 in order of list
1 parent3cc9666 commit28f2fa1

File tree

5 files changed

+89
-81
lines changed

5 files changed

+89
-81
lines changed
Lines changed: 13 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title:"How To: Acquire webhook information after agit triggerhas been created"
2+
title:"How To: Acquire webhook information after aGit triggeris created"
33
description:
44
group:kb
55
sub-group:articles
@@ -11,12 +11,18 @@ categories: [Pipelines, CLI]
1111
support-reviewed:2023-04-18 LG
1212
---
1313

14-
##Overview
1514

16-
Currently, there is no way to gather this information via the Codefresh Web Interface. This information can be acquired via the CLI / API call to get the pipeline spec.
1715

18-
##Details
16+
This article describes how to get webhook information for a Git trigger through the Codefresh CLI or API.
17+
Currently, you cannot get webhook information through the user interface.
1918

20-
1.`codefresh get pipeline Project/Pipeline -o yaml`
21-
2. Under spec.triggers you can see the information about each git trigger.
22-
3. Information you will need is the**endpoint** and**secret** fields
19+
##How to
20+
21+
* Run:
22+
`codefresh get pipeline Project/Pipeline -o yaml`
23+
24+
The`spec.triggers` displays information about each Git trigger.
25+
Look at the`endpoint` and`secret` fields.
26+
27+
##Related articles
28+
[Git triggers in pipelines]({{site.baseurl}}/docs/pipelines/triggers/git-triggers/)

‎_docs/kb/articles/adding-eks-cluster-programmatically.md‎

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title:"How To:Adding a new AWS EKS cluster to Codefresh programmatically"
2+
title:"How To:Add a new AWS EKS cluster to Codefresh programmatically"
33
description:
44
group:kb
55
sub-group:articles
@@ -11,14 +11,14 @@ categories: [Pipelines, API]
1111
support-reviewed:2023-04-18 LG
1212
---
1313

14-
##Overview
1514

16-
As part of your pipeline, you create a new cluster and want to add it to Codefresh
1715

18-
##Details
16+
This article describes how to add a new cluster created in a pipeline to Codefresh programmatically.
1917

20-
1. Note the name of the cluster in a variable, such as`$K8S_NAME`.
21-
2. After the cluster is created, run the following API call, replacing all with your values or variables:
18+
##How to
19+
20+
1. Create a variable for the cluster name, such as`$K8S_NAME`.
21+
2. After the cluster is created, run the following API call, replacing all placeholders with your values or variables:
2222

2323
{% raw %}
2424

@@ -45,9 +45,9 @@ add_new_cluster:
4545

4646
{% endraw %}
4747

48-
>_**Note**:_ A more detailed[EKS workflow can be foundhere](https://github.com/codefresh-io/eks-installer).
49-
50-
##Related Items
48+
{{site.data.callout.callout_tip}}
49+
See the detailed[EKS workflow](https://github.com/codefresh-io/eks-installer).
50+
{{site.data.callout.end}}
5151

52-
*[EKS Installer](https://github.com/codefresh-io/eks-installer)
53-
*[API documentation - clusters](https://g.codefresh.io/api/#tag/Clusters)
52+
##Related articles
53+
[API documentation - clusters](https://g.codefresh.io/api/#tag/Clusters)

‎_docs/kb/articles/automating-shared-secrets-creation.md‎

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title:"How To: Automate creation of Shared Secrets"
2+
title:"How To: Automate creation of Shared Secrets for pipelines"
33
description:
44
group:kb
55
sub-group:articles
@@ -11,18 +11,18 @@ categories: [Pipelines, CLI]
1111
support-reviewed:2024-01-17 MB
1212
---
1313

14-
##Overview
14+
This articles describes how to manage secrets across different pipelines in an efficient manner.
1515

16-
You have numerous secrets to manage across different pipelines and want to make the process more efficient.
1716

18-
##Details
17+
##Script for create secret context
1918

20-
The script reads each line from the provided file and appends it to the Codefresh`create context secret` command. This results in a single command that creates a secret context with all the specified secrets.
19+
The script reads each line from the provided file and appends it to the Codefresh`create context secret` command.
20+
This results in a single command that creates a secret context with all the specified secrets.
2121

2222
>**NOTE**
2323
Ensure you have the necessary permissions to create contexts in Codefresh.
2424

25-
**Script**
25+
#####Script
2626

2727
```bash
2828
#!/bin/bash
@@ -38,22 +38,22 @@ done < "$1"
3838
echo"$CMD"
3939
```
4040

41-
**How to use the script**
41+
##How to use the script
4242

43-
1. Prepare your secrets list
44-
Start by preparing a file containing your secrets. Each line in the file should contain one secret in the format KEY=VALUE.
43+
1. Prepare the list of your secrets.
44+
Start by preparing a file containing your secrets.
45+
Each line in the file should contain one secret in the format KEY=VALUE.
4546

46-
2. Set execution permissions
47+
2. Set execution permissions.
4748
Make the script executable by running:
4849
`chmod +x script_name.sh`
4950

50-
3. Run the script
51-
Execute the script with the command:
51+
3. Run the script with the command:
5252
`./script_name.sh secret_list.txt`
5353
where:
5454
`secret_list.txt` is the file containing your secrets
5555

56-
4. Verify creation
56+
4. Verify creation.
5757
After executing the script, verify that the secret context has been created in Codefresh with the specified secrets.
5858

5959

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
title:"How To: Checkagainstpotentially unstable service"
2+
title:"How To: Check potentially unstable service for pipelines"
33
description:
44
group:kb
55
sub-group:articles
@@ -11,18 +11,15 @@ categories: [Pipelines]
1111
support-reviewed:2023-04-18 LG
1212
---
1313

14-
##Overview
15-
16-
You are trying to check against a service that may be inaccessible for a number of reasons, including:
17-
14+
This article describes how to check for a service that may be inaccessible for a number of reasons, including:
1815
* Connectivity issues
1916
* Connection limits
2017
* Rate limits
2118
* Unstable service
2219

23-
##Details
20+
##How to
2421

25-
Inyourstep, add the`retry`feature. An example follows:
22+
*Inthe piplinestep, add the`retry`attribute, as in the following example:
2623

2724
```yaml
2825
steps:
@@ -36,10 +33,10 @@ steps:
3633
exponentialFactor:2
3734
```
3835
39-
>_**Note**:_
40-
>
41-
>During the retry stages, the build will still use up one of your concurrent builds. For that reason, we suggest limiting the amount of retries.
42-
43-
## Related Items
36+
>**NOTE**
37+
Every retry attempt uses up one of your concurrent builds. For this reason, we suggest limiting the amount of retries.
4438
45-
[Retrying a step]({{site.baseurl}}/docs/pipelines/what-is-the-codefresh-yaml/#retrying-a-step)
39+
## Related articles
40+
[Retrying a step]({{site.baseurl}}/docs/pipelines/what-is-the-codefresh-yaml/#retrying-a-step)
41+
[Pipeline policy settings]({{site.baseurl}}/docs/pipelines/pipelines/#policies)
42+
[Pipeline concurrency]({{site.baseurl}}/docs/pipelines/pipelines/#pipeline-concurrency)

‎_docs/kb/articles/docker-daemon-access.md‎

Lines changed: 42 additions & 37 deletions
Original file line numberDiff line numberDiff line change
@@ -11,38 +11,35 @@ categories: [Pipelines]
1111
support-reviewed:2023-04-18 LG
1212
---
1313

14-
##Overview
1514

16-
The general and most common uses-cases that require access to the Docker Daemon are covered by[Codefresh-provided native steps]({{site.baseurl}}/docs/pipelines/steps/):
1715

18-
* To build a Docker image:[Build step]({{site.baseurl}}/docs/pipelines/steps/build/)
19-
* To push a Docker image:[Push step]({{site.baseurl}}/docs/pipelines/steps/push/)
20-
* To run a Docker Composition:[Composition step]({{site.baseurl}}/docs/pipelines/steps/composition/) and[Service Containers]({{site.baseurl}}/docs/pipelines/service-containers/)
16+
This article describes how to access the Docker Daemon within a pipeline step for custom use cases.
2117

22-
But there are still cases when you need direct access to the Docker Daemon in
23-
your steps, for example:
18+
##Docker Daemon access support
19+
Codefresh's built-in steps cover the most common uses-cases for access to the Docker Daemon:
20+
* Build a Docker image:[Build step]({{site.baseurl}}/docs/pipelines/steps/build/)
21+
* Push a Docker image:[Push step]({{site.baseurl}}/docs/pipelines/steps/push/)
22+
* Run a Docker Composition:[Composition step]({{site.baseurl}}/docs/pipelines/steps/composition/) and[Service Containers]({{site.baseurl}}/docs/pipelines/service-containers/)
2423

25-
* As part of your test-step you need to dynamically create new containers (e.g.:[Testcontainers](https://www.testcontainers.org/) library)
24+
You may have custom use-cases when you need direct access to the Docker Daemon in your steps.
25+
For example:
26+
* As part of your test-step you need to dynamically create new containers ([Testcontainers](https://www.testcontainers.org/) library)
2627
* You need to run a composition and dynamically add to that composition a new container you'll create
2728
* You need to send specific flags to your docker-build process
2829

29-
For all those cases (and any others), you're still able to access the Docker
30-
Daemon on a step of your build, by providing the correct configuration (and
31-
under certain circumstances).
30+
For all custom cases, you can access the Docker Daemon in your pipeline step by providing the correct configuration in`freestyle` and`composition` steps.<!--- and under certain circumstances-->.
3231

33-
##Details
32+
##Direct access to Docker Daemon options
3433

3534
There are two main options to access the Docker Daemon in a pipeline step:
35+
***In a[`freestyle`]({{site.baseurl}}/docs/pipelines/steps/freestyle/) step**: By using an image with Docker installed, and mounting the required volumes (the Docker socket). In Hybrid Runtime Environments, these volumes are already mounted. You don't need to specify anything else.
36+
***In a[`composition`]({{site.baseurl}}/docs/pipelines/steps/composition/) step**: Similar to the`freestyle` step option, you'll need to use an image with Docker installed in one of the composition-services. And mount the corresponding volumes to that composition-service.
3637

37-
***In a[freestyle]({{site.baseurl}}/docs/pipelines/steps/freestyle/) step**: using an image with Docker installed, and mounting the required volumes (the Docker socket). In Hybrid REs, these volumes are already mounted. You don't need to specify anything else.
38-
***In a[composition]({{site.baseurl}}/docs/pipelines/steps/composition/) step**: same as with the freestyle option, you'll need to use an image with Docker installed in one of the composition-services. Also, you'll need to mount the corresponding volumes to that composition-service
38+
The following sections provide details on how to use each of the options.
3939

40-
In the following sections, we'll provide details on how to use each of the
41-
options described above.
40+
###Accessing the Docker Daemon in a`freestyle` step
4241

43-
###Accessing the Docker Daemon in a freestyle step
44-
45-
The following snippet shows a step using this approach:
42+
The following snippet shows an example of how to access the Docker Daemon in a`freestyle` step:
4643

4744
```yaml
4845
docker_daemon_access:
@@ -54,15 +51,18 @@ docker_daemon_access:
5451
-docker build -t your/image -f yourDockerfile .
5552
```
5653
57-
> **Note 1** : By default, and for security reasons, the Docker Daemon is not exposed to freestyle steps running on our SaaS environments. In other words, this approach **cannot** be used in our SaaS Runtime Environments.
58-
>
59-
> **Note 2** : There's still a way to use this approach in a RE **hosted by Codefresh**. For this option, you'll need a **dedicated Runtime Environment**.
60-
>
61-
> **Note 3** : This approach is **usable by default in Hybrid REs** (i.e.: Codefresh Runner REs). Since the REs is running in your infrastructure, access to the Docker Daemon in a freestyle step is enabled by default
54+
* Hybrid Runtime Environments (REs)
55+
In Hybrid REs with the Codefresh Runner, this is the default approach to access the Docker Daemon.
56+
Since the REs run in your infrastructure, access to the Docker Daemon in a`freestyle` step is enabled by default.
57+
* SaaS REs
58+
SaaS REs do not support this approach as the Docker Daemon is not exposed to `freestyle` steps by default for security reasons.
59+
You can still use the RE **hosted by Codefresh**. For this option, you'll need a **dedicated Runtime Environment**.
60+
61+
6262

6363
### Accessing the Docker Daemon in a composition step
6464

65-
The following snippet showsa step using this approach:
65+
The following snippet showsan example of how to access the Docker Daemon in a `composition` step:
6666

6767
{% raw %}
6868

@@ -92,9 +92,13 @@ docker_daemon_access:
9292

9393
{% endraw %}
9494

95-
> **Note 1** : This approach can be used in On-Prem out-of-the-box
96-
>
97-
> **Note 2** : Docker socket mapping in composition can only be provided to customers that have **all** concurrency in **Hybrid REs** , or, in a **dedicated cluster** (provided by Codefresh)
95+
* On-premises
96+
This approach is supported out-of-the-box in on-premises environments.
97+
98+
99+
* Hybrid REs
100+
Docker socket mapping in `composition` is supported only when the concurrency is set to **all**, or in a **dedicated cluster** provided by Codefresh.
101+
98102

99103
A similar implementation can be achieved using **[Service Containers]({{site.baseurl}}/docs/pipelines/service-containers/)**:
100104

@@ -118,15 +122,16 @@ docker_daemon_access_serv_cont:
118122

119123
{% endraw %}
120124

121-
> **_Note:_**
122-
>
123-
> As mentioned at the beginning of this article, Codefresh covers the general cases where access to the Docker Daemon is required (building a Docker image, pushing a Docker image, etc). For all these common cases **we encourage you to keep using our native steps**. Since they'll provide different levels of optimization (e.g.: Codefresh-cache mechanism), also their usage is directly related to the level of traceability you will get (e.g.: the images you build in Codefresh using our docker-build step will be reflected in the images view and other dashboards we provide).
124-
>
125-
> This way of directly accessing the Docker Dameon should be **exclusively used for very specific use-cases.**
125+
{{site.data.callout.callout_tip}}
126+
We encourage you to keep using our built-in steps as they cover almost all common use cases for access to the Docker Daemon.
127+
128+
Because the built-in steps support different levels of optimization, such as the Codefresh caching mechanism, their usage is directly related to the level of traceability. For example, the images you build in Codefresh using the `build` step are reflected in the images view and other dashboards we provide.
129+
130+
Reserve directly accessing the Docker Dameon **for very specific use-cases.**
131+
132+
126133

127134
## Related Items
135+
[Steps in pipelines]({{site.baseurl}}/docs/pipelines/steps/)
136+
[Caching in pipelines]({{site.baseurl}}/docs/pipelines/pipeline-caching/)
128137

129-
* [Build step]({{site.baseurl}}/docs/pipelines/steps/build/)
130-
* [Composition step]({{site.baseurl}}/docs/pipelines/steps/composition/)
131-
* [Push step]({{site.baseurl}}/docs/pipelines/steps/push/)
132-
* [Service Containers]({{site.baseurl}}/docs/pipelines/service-containers/)

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp