Skip to content

Commit 3f16cb9

Browse files
authored
Merge branch 'master' into q2-s3-side-by-side-install
2 parents ff1564d + 42b24fb commit 3f16cb9

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+957
-533
lines changed

_data/home-content.yml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,8 +252,10 @@
252252
localurl: /docs/administration/account-user-management/add-users/
253253
- title: Set up OAuth2 for GitOps
254254
localurl: /docs/administration/account-user-management/oauth-setup/
255-
- title: Access control
255+
- title: Access control for pipelines
256256
localurl: /docs/administration/account-user-management/access-control/
257+
- title: Access control for GitOps
258+
localurl: /docs/administration/account-user-management/gitops-abac/
257259
- title: Audit
258260
localurl: /docs/administration/account-user-management/audit/
259261
- title: User settings

_data/nav.yml

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -35,11 +35,11 @@
3535
- title: GitOps quick starts
3636
url: "/gitops-quick-start"
3737
sub-pages:
38-
- title: Provision a hosted runtime
38+
- title: Provision a Hosted GitOps Runtime
3939
url: "/install-hosted"
40-
- title: Prepare for hybrid runtime installation
40+
- title: Prepare for Hybrid GitOps Runtime installation
4141
url: "/verify-requirements"
42-
- title: Install a hybrid runtime
42+
- title: Install a Hybrid GitOps Runtime
4343
url: "/runtime"
4444
- title: Create an application
4545
url: "/create-app-ui"
@@ -528,7 +528,7 @@
528528
url: "/shared-configuration"
529529
- title: Add external clusters to GitOps Runtimes
530530
url: "/managed-cluster"
531-
- title: Add Git Sources to to GitOps Runtimes
531+
- title: Add Git Sources to GitOps Runtimes
532532
url: "/git-sources"
533533
- title: Download/upgrade GitOps CLI
534534
url: "/upgrade-gitops-cli"
@@ -544,8 +544,10 @@
544544
url: "/create-codefresh-account"
545545
- title: Adding users and teams
546546
url: "/add-users"
547-
- title: Configuring access control
547+
- title: Configuring access control for pipelines
548548
url: "/access-control"
549+
- title: Configuring access control for GitOps
550+
url: "/gitops-abac"
549551
- title: Setting up OAuth2 for GitOps
550552
url: "/oauth-setup"
551553
- title: Authorize access to organizations/projects

_docs/administration/account-user-management/access-control.md

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
---
2-
title: "Configuring access control"
3-
description: "Restrict resources in a company environment"
2+
title: "Configuring access control for pipelines"
3+
description: "Restrict resources to pipelines in a company environment"
44
group: administration
55
sub_group: account-user-management
66
redirect_from:
@@ -458,5 +458,7 @@ By default, if configured for the account, users can also load pipeline definiti
458458

459459

460460
## Related articles
461+
[Codefresh Provider for Terraform](https://registry.terraform.io/providers/codefresh-io/codefresh/latest/docs){:target="\_blank"}
461462
[Codefresh installation options]({{site.baseurl}}/docs/installation/installation-options/)
462463
[Managing your Kubernetes cluster]({{site.baseurl}}/docs/deployments/kubernetes/manage-kubernetes/)
464+

_docs/administration/account-user-management/create-codefresh-account.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ redirect_from:
99
- /docs/create-an-account/
1010
- /docs/getting-started/
1111
- /docs/getting-started/introduction/
12+
toc: true
1213
---
1314
Before you can do create pipelines, build, and deploy applications in Codefresh, you need to create a Codefresh account.
1415

Lines changed: 106 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,106 @@
1+
---
2+
title: "Access control for GitOps"
3+
description: "Restrict access to GitOps entities through ABAC"
4+
toc: true
5+
---
6+
7+
>This feature is currently in Beta.
8+
9+
Control access to entities in GitOps through ABAC (Attribute-Based Access Control). ABAC allows fine-grained access to application entities through the use of rules.
10+
For GitOps, you can currently define ABAC for application entities in the Codefresh UI or programmatically via Terraform.
11+
For more information on ABAC, see [ABAC on Wikipedia](https://en.wikipedia.org/wiki/Attribute-based_access_control){:target="\_blank"}.
12+
13+
14+
Rules define the *who*, *what*, and *where* control access to GitOps applications, through the following elements:
15+
* Teams
16+
Teams control the _who_ part of the rule.
17+
18+
* Actions
19+
Actions control the _what_ part of the rule. You need to select at least one action.
20+
21+
* Attributes
22+
Attributes control the _where_ part of the rule.
23+
Attributes are a combination of standard Kubernetes and Codefresh-specific attributes. You have Kubernetes attributes such as clusters, namespaces, and labels, and attributes unique to Codefresh such as Runtimes and Git Sources.
24+
25+
26+
## Creating a rule in Codefresh UI
27+
For each rule, you must select or define:
28+
* The team or teams the rule applies to, with at least one team being mandatory
29+
* The action or actions permitted for the entity, with at least one action being mandatory
30+
* The attribute or attributes determining where access is permitted
31+
32+
**How to**
33+
34+
1. In the Codefresh UI, on the toolbar, click the **Settings** icon.
35+
1. On the sidebar, from Access & Collaboration, select [**GitOps Permissions**](https://g.codefresh.io/account-admin/permissions/teams){:target="\_blank"}.
36+
1. To create a rule, click **Add** and define the **Teams**, **Actions**, and **Attributes** for the rule.
37+
1. To confirm, click **Add** once again.
38+
39+
{% include
40+
image.html
41+
lightbox="true"
42+
file="/images/administration/access-control/gitops/gitops-add-rule.png"
43+
url="/images/administration/access-control/gitops/gitops-add-rule.png"
44+
alt="Add rule for GitOps applications"
45+
caption="Add rule for GitOps applications"
46+
max-width="50%"
47+
%}
48+
49+
The rule you added for the entity is displayed in the GitOps Permissions page. Edit or delete the rule by clicking the respective icons.
50+
51+
## Creating a rule programmatically via Terraform
52+
You can also create rules enforcing ABAC for GitOps via Terraform.
53+
See the documentation for [codefresh_abac_rules](https://registry.terraform.io/providers/codefresh-io/codefresh/latest/docs/resources/abac_rules){:target="\_blank"}.
54+
55+
56+
57+
## GitOps Applications rule elements
58+
59+
{: .table .table-bordered .table-hover}
60+
| Rule Element | Description |
61+
| -------------- | -------------- |
62+
|Teams | The team or teams to which to give access to the Application Entity. See [Adding users and teams]({{site.baseurl}}/docs/administration/account-user-management/add-users/).|
63+
|Actions | The actions permitted for the application entity, and can be any or all of the following: {::nomarkdown} <ul><li><b>Refresh</b>: Allow users to manually regular refresh or hard refresh. The Refresh action is automatically disabled on selecting the Sync action which takes precedence. See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#refreshhard-refresh-applications">Refresh/Hard Refresh applications</a>.</li><li><b>Sync</b>: Allow users to manually sync an application on-demand, and define the options for manual sync.<br>Selecting Sync automatically disables the Refresh action as Sync takes precedence over it. <br> See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#manually-synchronize-an-application">Manually synchronize an application</a>.</li><li><b>Terminate Sync</b>: Allow users to manually stop an ongoing sync for an application. See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#terminate-on-going-application-sync">Terminate on-going application sync</a></li><li><b>Rollback application</b>: Allow users to rollback the current release of an application to a previous deployment version or release in Codefresh. See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#rollback-gitops-applications">Rollback GitOps applications</a>.</li><li><b>Pause rollout</b> and <b>Resume rollout</b>: Allow users to pause an ongoing rollout and resume a paused rollout either directly from the Timeline tab of the application, or through the controls in the Rollout Player. <br>See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#pauseresume-ongoing-rollouts">Pause/resume ongoing rollouts</a> and <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#manage-an-ongoing-rollout-with-the-rollout-player">Managing an ongoing rollout with the Rollout Player</a>.</li><li><b>Promote full rollout</b>: Allow users to use the Promote Full button in the Rollout Player to skip the remaining steps in the rollout and promote to deployment. See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#manage-an-ongoing-rollout-with-the-rollout-player">Managing an ongoing rollout with the Rollout Player</a>.</li><li><b>Skip current step in rollout</b>: Allow users to use the Skip Step button in the Rollout Player to skip executing the current step in the rollout. <br>See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#manage-an-ongoing-rollout-with-the-rollout-player">Managing an ongoing rollout with the Rollout Player</a>.</li><b>Delete resource</b>: Allow users to delete an application resource from the Current State tab. See <a href="https://codefresh.io/docs/docs/deployments/gitops/manage-application/#delete-an-application">Delete an application</a>.</li></ul>{:/} |
64+
|Attributes |Adding attributes, either individually or in combination, allow more fine-grained access control to enforce the _where_ policies for teams and actions. <br>Single attributes are useful to grant or deny access based on a specific property. For example, allow access to application entities on a cluster or within a namespace. <br>Combinations of attributes help enforce more complex access control. For example, require both a Runtime and a Label attribute to grant access to an application entity.<br>You can also add multiple instances of the same attribute with different values. For example, multiple Label attibutes with different values to sync application entities.{::nomarkdown} <ul><li><b>Cluster</b>: Allow access to all application entities in the cluster, regardless of the namespace, Runtime, and Git Sources of specific applications.</li><li><b>Namespace</b>: Allow access to application entities only within the namespace. If users have multiple accounts on different clusters with the same namespace, they can access applications in all those namespaces.</li><li><b>Runtime</b>: Allow access to application entities associated with the defined Runtime.</li><li><b>Git Source</b>: Allow access to application entities only in the defined Git Source. A Git Source is always associated with a Runtime.</li><li><b>Label</b>: Allow access only to application entities that share the same label.</li></ul>{:/} |
65+
66+
67+
68+
69+
70+
## Examples of rules for application entities
71+
72+
### Rule: Cluster-based access to all actions
73+
This rule grants the DevOps team permission to perform all actions for application entities on the production cluster, regardless of namespaces, Runtimes, Git Sources and labels.
74+
75+
**Rule elements**
76+
* Team: `DevOps`
77+
* Actions: `All`
78+
* Attributes: `Cluster: production-cluster`
79+
80+
81+
82+
### Rule: Cluster- and namespace-based access to all actions
83+
This rule grants two different teams permissions to perform all actions for application entities deployed on a specific cluster but within a specific namespace.
84+
85+
**Rule elements**
86+
* Teams: `Product`, `Docs`
87+
* Actions: `All`
88+
* Attributes:
89+
* `Cluster: development`
90+
* `Namespace: product-sandbox`
91+
92+
93+
### Rule: Namespace- and label-based access to specific actions
94+
This rule grants the Support team permission to manually sync application entities or manually terminate on-going syncs for application entities deployed in a specific namespace, but only for those entities that share the same label.
95+
96+
**Rule elements**
97+
* Team: `Customer Support`
98+
* Actions: `Sync`, `Terminate Sync`
99+
* Attributes:
100+
* `Namespace: poc`
101+
* `Label: customer=AcmePoc`
102+
103+
104+
## Related articles
105+
[Codefresh Provider for Terraform](https://registry.terraform.io/providers/codefresh-io/codefresh/latest/docs){:target="\_blank"}
106+
[Access control for pipelines]({{site.baseurl}}/docs/administration/account-user-management/access-control/)

_docs/administration/single-sign-on/oidc/oidc-azure.md

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,7 +144,7 @@ Configure SSO for Azure in the Codefresh UI.
144144
**Before you begin**
145145
* From Azure AD:
146146
* Have your client secret handy
147-
* Go to the application you created, and note down these **Properties: Application ID and Object ID**
147+
* Go to t**Azure Active Directory > Enterprise Applications** and select the app you created, and note down these **Properties: Application ID and Object ID**
148148

149149
{% include image.html
150150
lightbox="true"
@@ -238,9 +238,27 @@ caption="Web configuration settings"
238238
max-width="70%"
239239
%}
240240

241-
You have now completed the SSO setup for Azure using OIDC.
241+
## Step 6: (Optional) Configure for Azure Initiated Login.
242+
243+
1. Go to **Azure Active Directory > Apps registrations**, and select the application you registered for SSO.
244+
1. From the sidebar, select **Branding & properties**
245+
1. In the **Home page URL** field, insert the following `https://g.codefresh.io/api/auth/<your_codefresh_sso_client_name>`
246+
247+
{% include image.html
248+
lightbox="true"
249+
file="/images/sso/azure/homePageURL.png"
250+
url="/images/sso/azure/homePageURL.png"
251+
alt="Web configuration settings"
252+
caption="Web configuration settings"
253+
max-width="70%"
254+
%}
242255

256+
{:start="4"}
257+
1. Go to **Azure Active Directory > Enterprise Applications**, and select the application you registered for SSO.
258+
1. Under Properties, toggle **Visible to users** to yes.
259+
1. Now the app can be added to a Collection for My Apps page for Azure Initiated Login.
243260

261+
You have now completed the SSO setup for Azure using OIDC.
244262

245263
## Related articles
246264
[Federated Single Sign-On (SSO) overview]({{site.baseurl}}/docs/administration/single-sign-on/)

0 commit comments

Comments
 (0)