Skip to content

Commit a181c41

Browse files
authored
Cf quick start app refactor (#228)
* Update quick start app topics Initial restructure acc to new reqs * Update quick start app modules Added install argo rollouts step to hosted runtime; updated create app and app resources * Update app quick start topics Content edits to align with new structure * Update app modules Content updates * Update titles * Update images
1 parent 9dcdc8c commit a181c41

File tree

10 files changed

+84
-106
lines changed

10 files changed

+84
-106
lines changed

_data/nav.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,11 +12,11 @@
1212
url: "/verify-requirements"
1313
- title: Install a hybrid runtime
1414
url: "/runtime"
15-
- title: Create resources for the codefresh-guestbook application
15+
- title: Create an application
16+
url: "/create-app-ui"
17+
- title: Create and commit resources for application
1618
url: "/create-app-specs"
17-
- title: Create the codefresh-guestbook application
18-
url: "/create-app-ui"
19-
- title: Update the image tag for the codefresh-guestbook application
19+
- title: Update the image tag for application
2020
url: "/create-rollout"
2121
- title: Trigger the Hello World example pipeline
2222
url: "/hello-world"

_docs/getting-started/quick-start.md

Lines changed: 8 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,14 +17,10 @@ Each section indicates the runtime environment it is relevant to.
1717
### Provision runtimes
1818
Based on your deployment model, start by provisioning the hosted or hybrid runtime. Hosted and hybrid runtimes can co-exist with each other.
1919

20-
* Hosted runtimes: Hosted on a Codefresh cluster and managed by Codefresh. You need to provision your hosted runtime once for your account.
21-
* Hybrid runtimes: Hosted on a customer cluster and managed by the customer. You can provision multiple hybrid runtimes in the same account.
22-
23-
{::nomarkdown}
24-
<br>
25-
{:/}
2620

2721
#### Hosted
22+
Hosted runtimes are hosted on a Codefresh cluster and managed by Codefresh. You need to provision your hosted runtime once for your account.
23+
2824
1. [Provision a hosted runtime]({{site.baseurl}}/docs/getting-started/quick-start/install-hosted)
2925
Provision the hosted runtime with a single click, and complete the setup for your hosted environment.
3026

@@ -33,18 +29,20 @@ Based on your deployment model, start by provisioning the hosted or hybrid runti
3329
{:/}
3430

3531
#### Hybrid
32+
Hybrid runtimes: Hosted on a customer cluster and managed by the customer. You can provision multiple hybrid runtimes in the same account.
33+
3634
1. [Prepare for hosted runtime installation]({{site.baseurl}}/docs/getting-started/quick-start/verify-requirements)
3735
Verify your environment matches the requirements for installing Codefresh runtime.
3836
1. [Install hybrid runtime]({{site.baseurl}}/docs/getting-started/quick-start/runtime)
3937
Install the Codefresh runtime by downloading the CLI, installing the runtime, and validate successful installation in the UI
4038

4139
### Deploy an application
4240

43-
1. [Create resources for codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-specs)
44-
Create rollout, service, and analysis template resources prior to creating the `codefresh-guestbook` application.
45-
1. [Create the codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-ui)
41+
1. [Create an application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-ui)
4642
Create the `codefresh-guestbook` application in the Codefresh UI.
47-
1. [Update the image tag for codefresh-guestbook]({{site.baseurl}}/docs/getting-started/quick-start/create-rollout)
43+
1. [Create and commit resources for application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-specs)
44+
Create rollout and service resources, and commit these resources to deploy the `codefresh-guestbook` application.
45+
1. [Update the image tag for application]({{site.baseurl}}/docs/getting-started/quick-start/create-rollout)
4846
Update the image for the `codefresh-guestbook` application to trigger a rollout.
4947

5048
### Trigger/create a Delivery Pipeline
Lines changed: 26 additions & 70 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,33 @@
11
---
2-
title: "Create resources for codefresh-guestbook"
2+
title: "Create and commit resources for application"
33
description: ""
44
group: getting-started
55
sub-group: quick-start
66
toc: true
77
---
88

9-
Before you can create an application in Codefresh, you need to create the resources used by the application:
10-
11-
1. Install Argo Rollouts on the target cluster to which you will deploy the application
9+
Now that you have created an application, you need to deploy the application. Let's deploy the `codefresh-guestbook` application by creating and commiting resources.
10+
You will create and commit the following resources:
11+
1. A folder in Git to save resources for the application
1212
1. `Rollout` resource defining the deployment strategy
13-
1. Service resource to expose the application to external traffic
14-
1. Analysis Template resource defining the validation requirements before deployment
15-
16-
### Install Argo Rollouts on the target cluster
17-
To apply the `Rollout` resource for the application, you must have Argo Rollouts installed on the target cluster. If not installed, follow the steps to install Argo Rollouts.
18-
19-
1. In the Codefresh UI, go to [Runtimes](https://g.codefresh.io/2.0/account-settings/runtimes){:target="\_blank"}.
20-
1. Select **Topology View**.
21-
1. Select the target cluster, and then select **+ Install Argo Rollouts**.
13+
1. `Service` resource to expose the application to external traffic
2214

23-
{% include
24-
image.html
25-
lightbox="true"
26-
file="/images/getting-started/quick-start/cdops-app-install-rollout.png"
27-
url="/images/getting-started/quick-start/cdops-app-install-rollout.png"
28-
alt="Install Argo Rollouts on target cluster"
29-
caption="Install Argo Rollouts on target cluster"
30-
max-width="50%"
31-
%}
15+
### Before you begin
16+
* [Create an application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-ui)
17+
* Make sure [Argo Rollouts is installed]({{site.baseurl}}/docs/deployment/install-argo-rollouts) on the target cluster
3218

3319
### Create folder in Git for application resources
34-
Create a folder in the Git repo in which to save all the resources.
20+
Create a folder in the Git repo in which to save all the resources for the `codefresh-guestbook` application.
3521

3622
* In your Git repo, create a folder to store the resources needed to deploy the application.
37-
3823
For example, `/quick-start/`
3924

4025
### Create rollout.yaml
4126

4227
Create a rollout resource for the application you want to deploy.
4328

4429

45-
To leverage Argo Rollout's deployment capabilities, we are using the Argo's Rollout resource instead of the native Kubernetes Deployment object.
30+
To leverage Argo Rollouts' deployment capabilities, we are using the Argo's `rollout` resource instead of the native Kubernetes Deployment object.
4631
For detailed information on the fields you can define, see [Argo Rollout specification](https://argoproj.github.io/argo-rollouts/features/specification/){:target="\_blank"}.
4732

4833

@@ -75,10 +60,6 @@ spec:
7560
minReadySeconds: 30
7661
strategy:
7762
canary:
78-
analysis:
79-
templates:
80-
- templateName: background-analysis
81-
startingStep: 1
8263
steps:
8364
- setWeight: 25
8465
- pause: {duration: 20s}
@@ -128,48 +109,23 @@ spec:
128109
| `spec.ports` | The internal `port`, 8080 in our example, and external `targetPort`, 80 in our example.|
129110
| `selector.app` | The pods to select, and MUST be identical to that defined in `rollouts.yaml`, `codefresh-guestbook` in our example.|
130111

131-
### Create an AnalysisTemplate for rollout validation
132-
Create an `AnalysisTemplate` resource to validate that your changes conform to the requirements before deployment. This is the final resource you need before you can create the application.
133-
134-
The name of the `AnalysisTemplate` in the quick start example is `background-analysis`. The template interfaces with Prometheus as the third-party metric provider to validate metrics.
135-
136-
You can use any third-party metric provider supported by Argo Rollouts, such as Prometheus, Datadog, Wavefront, and more. Read the official documentation on [Analysis section in Argo Rollouts](https://argoproj.github.io/argo-rollouts/){:target="\_blank"}.
137-
138-
139-
* In the Git repository create the `analysisTemplate.yaml` file, as in the example below.
140-
112+
### View application resources in Codefresh
113+
Once you create and commit the `rollout` and `service` resources, return to the Applications dashboard. The Current State to see these resources.
141114

142-
```yaml
143-
apiVersion: argoproj.io/v1alpha1
144-
kind: AnalysisTemplate
145-
metadata:
146-
name: background-analysis
147-
spec:
148-
metrics:
149-
- name: prometheus-metric
150-
count: 4
151-
interval: 5s
152-
successCondition: result[0] >= 100
153-
failureLimit: 1
154-
provider:
155-
prometheus:
156-
address: http://a95910c83807a4089a2458554bf5c21e-1864259807.us-east-1.elb.amazonaws.com:9090
157-
query: |
158-
sum(argocd_app_reconcile_sum)
159-
```
160-
161-
#### Fields in `analysisTemplate.yaml`
115+
1. In the Codefresh UI, go to the [Applications dashboard](https://g.codefresh.io/2.0/applications-dashboard?sort=desc-lastUpdated){:target="\_blank"}.
116+
1. Select the application.
117+
The Current State tab is now populated with the `rollout` and `service` resources you added.
162118

163-
{: .table .table-bordered .table-hover}
164-
| Analysis Template field | Notes |
165-
| -------------- | -------------- |
166-
| `count` | The total number of measurements taken, `4` in our example.|
167-
| `interval` | The interval between measurement samplings, `5s` in our example.|
168-
| `successCondition` | The requirement for the rollout to be considered a success. In our example, the resulting metric value must be equal to or greater than 100.|
169-
| `failureLimit` | The maximum number of failures permitted, `1` in our example. If the metric value is below 100 more than once, the rollout is aborted.|
170-
| `query` | The query submitted to the Prometheus server.|
171-
172-
You are now ready to create the application in Codefresh.
119+
{% include
120+
image.html
121+
lightbox="true"
122+
file="/images/getting-started/quick-start/cdops-app-current-state.png"
123+
url="/images/getting-started/quick-start/cdops-app-current-state.png"
124+
alt="Current State with resources for application"
125+
caption="Current State with resources for application"
126+
max-width="70%"
127+
%}
173128

174129
### What to do next
175-
[Create the codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-ui)
130+
<!---[Create Jira and Docker Hub integrations ]({{site.baseurl}}/docs/getting-started/quick-start/create-app-ui)--->
131+
[(Optional) Update image tag for application]({{site.baseurl}}/docs/getting-started/quick-start/create-rollout)

_docs/getting-started/quick-start/create-app-ui.md

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,17 @@
11
---
2-
title: "Create the codefresh-guestbook application"
2+
title: "Create an application"
33
description: ""
44
group: getting-started
55
sub-group: quick-start
66
toc: true
77
---
88

9-
Now that you have created all the resources for the application, you can create the application in Codefresh.
10-
For the quick start, you will create the `codefresh-guestbook` application.
9+
Let's start by creating a simple application, the `codefresh-guestbook` application in the Codefresh UI.
10+
We'll create the application without resources and then define/add resources in the next step.
1111

12-
For detailed information, see [Create an application]({{site.baseurl}}/docs/deployment/create-application).
1312

14-
**Before you begin**
13+
For detailed information, see [Create an application]({{site.baseurl}}/docs/deployment/create-application).
1514

16-
[Create resources for codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-specs)
1715

1816
**How to**
1917

@@ -23,9 +21,10 @@ For detailed information, see [Create an application]({{site.baseurl}}/docs/depl
2321
1. In the Add Application panel, add definitions for the application:
2422
* **Application name**: `codefresh-guestbook` for the quick start.
2523
* **Runtime**: The runtime to associate with the application, `hosted-runtime` for the quick start.
26-
* **YAML filename**: The name of the application's configuration manifest, assigned on commit to Git. By default, the manifest is assigned the application name.
24+
* **Name for YAML file**: The name of the application's configuration manifest, assigned on commit to Git. By default, the manifest is assigned the application name.
25+
You can click the Edit icon and change the name, if needed.
2726

28-
>The application definitions cannot be changed after you continue to the Configuration settings.
27+
>You cannot change the application definitions once you continue to the Configuration settings.
2928
3029
{% include
3130
image.html
@@ -44,7 +43,7 @@ For detailed information, see [Create an application]({{site.baseurl}}/docs/depl
4443
* **Repository URL**: The URL to the repo in Git where you created the YAML resource files for the application.
4544
* **Revision**: The branch in Git with the resource files.
4645
* **Path**: The folder in Git with the resource files.
47-
* **Namespace**: Optional. For the quick start, we'll create a namespace for the application, `quick-start`.
46+
* **Namespace**: Optional. For the quick start, we'll create a namespace for the application, entitled `quick-start`.
4847
* **Sync Policy**: Change to **Automatic**, and select **Prune resources** to automatically remove unused resources.
4948
* **Sync Options**: If you defined a namespace, select **Auto-create namespace** to ensure that the namespace is created if it doesn't exist.
5049

@@ -62,7 +61,7 @@ For detailed information, see [Create an application]({{site.baseurl}}/docs/depl
6261
{:start="6"}
6362
1. Retain the default **Advanced Settings**.
6463
1. To commit all your changes, select **Commit**.
65-
The Commit form is displayed with the application's definition on the left, and the read-only version of the manifest with the configuration settings you defined on the right.
64+
The Commit form is displayed with the application's definitions on the left, and the read-only version of the manifest with the configuration settings you defined on the right.
6665
1. Select the **Git Source** to which to commit.
6766

6867
{% include
@@ -91,20 +90,21 @@ For detailed information, see [Create an application]({{site.baseurl}}/docs/depl
9190
%}
9291

9392
{:start="10"}
94-
1. Select the application, and then click the **Current State** tab to see all the resources created for the application.
93+
1. Select the application. The Current State tab does not display any resources as we have not created any resources for the application.
9594

9695
{% include
9796
image.html
9897
lightbox="true"
99-
file="/images/getting-started/quick-start/cdops-app-current-state.png"
100-
url="/images/getting-started/quick-start/cdops-app-current-state.png"
101-
alt="Current State for codefresh-guestbook application"
102-
caption="Current State for codefresh-guestbook application"
98+
file="/images/getting-started/quick-start/cdops-app-empty-current-state.png"
99+
url="/images/getting-started/quick-start/cdops-app-empty-current-state.png"
100+
alt="Empty Current State for new application"
101+
caption="Empty Current State for new application"
103102
max-width="70%"
104-
%}
103+
%}
104+
105105

106+
In the next task, you will create and commit resources for the `codefresh-guestbook` application and deploy the application.
106107

107-
The final step is to make a change in the application manifest to enforce a rollout.
108108

109109
### What to do next
110-
[Update image tag for codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-rollout)
110+
[Create and commit resources for application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-specs/)
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
---
2+
title: "Connect a GitHub Action CI to enrich image"
3+
description: ""
4+
group: getting-started
5+
sub-group: quick-start
6+
toc: true
7+
---

_docs/getting-started/quick-start/create-rollout.md

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,17 @@
11
---
2-
title: "Update image tag for the codefresh-guestbook application"
2+
title: "Update image tag for application"
33
description: ""
44
group: getting-started
55
sub-group: quick-start
66
toc: true
77
---
88

9-
You will now make a change in the application manifest, and update the image tag. Because we selected auto-sync in the application settings, Argo CD detects that the live state in the cluster is out of sync with the desired state in Git, and initiates the new rollout. The rollout runs the analysis template you defined (`background-analysis` in the quick start).
9+
You will now make a change in the application manifest, and update the image tag. Because we selected auto-sync in the application settings, Argo CD detects that the live state in the cluster is out of sync with the desired state in Git, and triggers the new rollout. <!---The rollout runs the analysis template you defined (`background-analysis` in the quick start).--->
1010

1111
### Before you begin
1212

13-
[Create the codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-ui)
13+
* [Create resources for application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-specs/)
14+
1415

1516
### Update image tag in rollout.yaml
1617
Update the image tag in the `codefresh-guestbook` application.

_docs/getting-started/quick-start/install-hosted.md

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@ If you have Hosted GitOps, set up your hosted runtime environment:
1010

1111
1. Provision the hosted runtime with a single click
1212
1. Authorize access through your OAuth token to the organization where Codefresh creates the Git runtime repo and the shared configuration repo
13-
1. Connect to an external K8s cluster with access to the internet, to which you can deploy applications
13+
1. Connect to an external K8s cluster with access to the internet, to which you can deploy applications
14+
1. Install Argo Rollouts on the cluster
1415

1516
Read our [blog on Hosted GitOps](https://codefresh.io/blog/codefresh-upends-continuous-delivery-with-hosted-gitops-platform-featuring-dora-dashboards-and-first-class-integrations-for-ci/).
1617
For detailed information on each of the steps below, see [Set up a hosted runtime environment]({{site.baseurl}}/docs/runtime/hosted-runtime/).
@@ -88,6 +89,21 @@ caption="Connect a K8s cluster for hosted runtime"
8889
max-width="70%"
8990
%}
9091

92+
1. Install Argo Rollouts on the cluster you added. You'll need this to apply the `rollout` resource we will create for the application in the next task.
93+
* Go to [Runtimes](https://g.codefresh.io/2.0/account-settings/runtimes){:target="\_blank"}.
94+
* Select **Topology View**.
95+
* Select the target cluster, and then select **+ Install Argo Rollouts**.
96+
97+
{% include
98+
image.html
99+
lightbox="true"
100+
file="/images/getting-started/quick-start/cdops-app-install-rollout.png"
101+
url="/images/getting-started/quick-start/cdops-app-install-rollout.png"
102+
alt="Install Argo Rollouts on managed cluster"
103+
caption="Install Argo Rollouts on managed cluster"
104+
max-width="50%"
105+
%}
106+
91107
### What to do next
92108
[Create resources for codefresh-guestbook application]({{site.baseurl}}/docs/getting-started/quick-start/create-app-specs)
93109

2.3 KB
Loading
88.8 KB
Loading
64.7 KB
Loading

0 commit comments

Comments
 (0)