Skip to content

Commit 3d8fdb2

Browse files
authored
Merge pull request #8548 from ovh/feat-rancher-iam
Fea(rancher): create guide about iam auth
2 parents 252907d + 0ddd900 commit 3d8fdb2

File tree

9 files changed

+210
-0
lines changed

9 files changed

+210
-0
lines changed

pages/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1122,6 +1122,7 @@
11221122
+ [Managing users and projects in Managed Rancher Service](public_cloud/containers_orchestration/managed_rancher_service/managing-users-and-projects)
11231123
+ [Tutorial - How to use Rancher CLI](public_cloud/containers_orchestration/managed_rancher_service/using-rancher-cli)
11241124
+ [Orchestration product reversibility policy](account_and_service_management/reversibility/12-reversibility-orchestration)
1125+
+ [Configure access control using OVHcloud IAM on an OVHcloud Managed Rancher Service](public_cloud/containers_orchestration/managed_rancher_service/managing-iam-authentication)
11251126
+ [Resources](public-cloud-containers-orchestration-managed-rancher-service-resources)
11261127
+ [Managed Rancher Service supported versions and lifecycle policy](public_cloud/containers_orchestration/managed_rancher_service/lifecycle-policy)
11271128
+ [Creating or importing a Kubernetes cluster](public-cloud-containers-orchestration-managed-rancher-service-creating-importing-kubernetes)
Lines changed: 207 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,207 @@
1+
---
2+
title: 'Configure access control using OVHcloud IAM on an OVHcloud Managed Rancher Service'
3+
excerpt: 'Learn how to enable and manage OVHcloud IAM authentication to control access to your Managed Rancher Service (MRS) using centralized identities and roles'
4+
updated: 2025-11-04
5+
---
6+
7+
<style>
8+
details>summary {
9+
color:rgb(33, 153, 232) !important;
10+
cursor: pointer;
11+
}
12+
details>summary::before {
13+
content:'\25B6';
14+
padding-right:1ch;
15+
}
16+
details[open]>summary::before {
17+
content:'\25BC';
18+
}
19+
</style>
20+
21+
## Objective
22+
23+
OVHcloud Managed Rancher Service (MRS) supports authentication through OVHcloud IAM, allowing you to manage access using centralized user identities and roles.
24+
25+
This guide explains how to enable IAM authentication and control user access to your Rancher service using OVHcloud IAM users and roles.
26+
27+
## Requirements
28+
29+
- An OVHcloud Managed Rancher Service (see the [Creating, updating and accessing a Managed Rancher Service](/pages/public_cloud/containers_orchestration/managed_rancher_service/create-update-rancher) guide for more information).
30+
31+
## Instructions
32+
33+
### Introduction to OVHcloud IAM
34+
35+
OVHcloud IAM (Identity and Access Management) is a centralized system that lets you control who can access your OVHcloud services and what actions they can perform. It provides fine-grained access management through users, groups, and roles.
36+
37+
When integrated with the Managed Rancher Service (MRS), OVHcloud IAM replaces Rancher’s local authentication system. This allows you to:
38+
39+
- Use Single Sign-On (SSO) with your OVHcloud credentials to access Rancher.
40+
- Assign predefined IAM roles (such as base, ovhRestrictedAdmin, standard) to define access levels.
41+
- Manage permissions efficiently at scale using IAM groups and projects.
42+
43+
Integrating IAM with your Rancher service ensures consistent access control across all your OVHcloud resources, reducing manual management and improving overall security.
44+
45+
### Activate/disable authentication via OVHcloud IAM
46+
47+
> [!warning]
48+
>
49+
> When you enable OVHcloud IAM authentication on your Managed Rancher Service:
50+
>
51+
> - Local users will remain functional, so you can continue logging in with your usual Rancher accounts.
52+
> - If the "admin" password is regenerated while IAM authentication is enabled, or if no user has ever logged in locally, the ability to log in with the IAM root user will be impossible. To restore access with the IAM root user, log in first with a local admin account.
53+
>
54+
> From this point on, IAM roles and policies control access for users authenticated via OVHcloud IAM.
55+
>
56+
57+
> [!tabs]
58+
> Via the OVHcloud Control Panel (coming soon)
59+
>> > [!primary]
60+
>> >
61+
>> > Managing IAM from the OVHcloud Control Panel is not yet available and will be added in a future release.
62+
>> >
63+
>>
64+
> Via the OVHcloud API
65+
>>
66+
>> > [!api]
67+
>> >
68+
>> > @api {v2} /publicCloud PUT /publicCloud/project/{projectId}/rancher/{rancherId}
69+
>> >
70+
>>
71+
>> With the request body:
72+
>>
73+
>> ```json
74+
>> {
75+
>> "targetSpec": {
76+
>> "iamAuthEnabled": true, // true to enable IAM, false to disable
77+
>> "name": "my_rancher", // Name of the Managed Rancher Service
78+
>> "plan": "STANDARD", // Plan of the Managed Rancher Service
79+
>> "version": "1.0.0" // Version of the Managed Rancher Service
80+
>> }
81+
>> }
82+
>> ```
83+
>>
84+
>> > [!primary]
85+
>> >
86+
>> > Make sure all the information in the JSON (service name, plan, version) is correct. Using incorrect values will result in an error when activating or disabling IAM.
87+
>> >
88+
>>
89+
>> Replace:
90+
>>
91+
>> - `projectId` with the ID of your Public Cloud project.
92+
>> - `rancherId` with the ID of the Managed Rancher Service.
93+
>>
94+
>> You can retrieve the `rancherId` in two ways:
95+
>>
96+
>> - **Via API:**
97+
>>
98+
>> > [!api]
99+
>> >
100+
>> > @api {v2} /publicCloud GET /publicCloud/project/{projectId}/rancher
101+
>> >
102+
>>
103+
>> - **Via the OVHcloud Control Panel:**
104+
>>
105+
>> Log in to the [OVHcloud Control Panel](/links/manager), navigate to the `Public Cloud`{.action} section, and select the relevant project. Then, in the left-hand menu under **Containers & Orchestration**, click on `Managed Rancher Service`{.action}.
106+
>>
107+
108+
### Authentication using SSO with OVHcloud IAM users
109+
110+
Once IAM authentication is enabled on your Managed Rancher Service, access to the Rancher UI is managed via OVHcloud Single Sign-On (SSO). Users no longer log in with local Rancher credentials but authenticate directly using their OVHcloud IAM identity.
111+
112+
> [!primary]
113+
>
114+
> Local Rancher users remain functional even after enabling OVHcloud IAM, but their use is not recommended. Access and permissions should be managed through OVHcloud IAM roles and policies for consistency and security.
115+
>
116+
117+
To log in via SSO:
118+
119+
- Open the `Rancher user interface`{.action} from the Control Panel.
120+
121+
![rancher user interface](images/rancher_interface.png){.thumbnail}
122+
123+
- You will be redirected to the Managed Rancher Service authentication page.
124+
125+
/// details | No user has ever logged in locally
126+
127+
Click on `Use a local user`{.action} to go to the local login page.
128+
129+
To recover the admin password required for authentication, use the following API call:
130+
131+
> [!api]
132+
>
133+
> @api {v2} /publicCloud POST /publicCloud/project/{projectId}/rancher/{rancherId}/adminCredentials
134+
>
135+
136+
Replace:
137+
138+
- `projectId` with the ID of your Public Cloud project.
139+
- `rancherId` with the ID of the Managed Rancher Service.
140+
141+
Copy the returned password, then paste it on the authentication page.
142+
143+
Make sure to check the box to accept the `End User License Agreement & Terms & Conditions`{.action}, then click `Continue`{.action}.
144+
145+
You can now log out and proceed with your normal workflow.
146+
147+
///
148+
149+
Click on `Log in with OIDC`, which will take you to the OVHcloud authentication page. There, log in using your OVHcloud IAM credentials.
150+
151+
![login with SSO](images/iam_authentication.png){.thumbnail}
152+
153+
- Access to Rancher is granted based on the IAM role associated with your user account.
154+
155+
> [!primary]
156+
>
157+
> Only users with the appropriate IAM role (base, standard and ovhRestrictedAdmin) can access the registry after IAM authentication is enabled.
158+
>
159+
160+
### Managing access rights with OVHcloud IAM
161+
162+
OVHcloud IAM provides three predefined roles for managing access to your Managed Rancher Service (MRS):
163+
164+
- base
165+
- standard
166+
- ovhRestrictedAdmin
167+
168+
> [!primary]
169+
>
170+
> **base** role: Base users can only log in and do not have any additional permissions.
171+
>
172+
> **standard** role: Standard users can create new clusters and manage clusters and projects they have been granted access to.
173+
>
174+
> **ovhRestrictedAdmin** role: OVHcloud Restricted Admins have full control over all resources in downstream clusters but do not have access to the local cluster.
175+
>
176+
177+
These roles are assigned through IAM policies. To create and configure a policy, log in to the [OVHcloud Control Panel](/links/manager) and navigate to the `Identity, Security & Operations`{.action} section. Then, in the left-hand menu under **Identity and Access management**, click on `Policies`{.action} and click the `Create a policy`{.action} button.
178+
179+
![Create policy](images/managing_iam.png){.thumbnail}
180+
181+
Define users and groups, name your policy, add the users you want to include and optionally, add user groups if they have already been created.
182+
183+
![Create policy users](images/create_policy.png){.thumbnail width="700"}
184+
185+
Set permissions for MRS:
186+
187+
- In the `Product types`{.action} section, select `Public Cloud / Managed Rancher Service (MRS) project`{.action}.
188+
- In the `Resources`{.action} section, choose the specific MRS service to which the policy will apply.
189+
190+
![Create policy product types](images/create_policy_product_types.png){.thumbnail}
191+
192+
Expand `Public Cloud / Managed Rancher Service (MRS) project`{.action} and select the desired role for the users defined in the policy.
193+
194+
![Create policy roles](images/create_policy_action.png){.thumbnail width="700"}
195+
196+
### Go further
197+
198+
To go further you can look at our guides on:
199+
200+
- [Managing users and projects](/pages/public_cloud/containers_orchestration/managed_private_registry/managing-users-and-projects).
201+
- [Creating and using a private image](/pages/public_cloud/containers_orchestration/managed_private_registry/creating-and-using-a-private-image).
202+
203+
If you need training or technical assistance to implement our solutions, contact your sales representative or click on [this link](/links/professional-services) to get a quote and ask our Professional Services experts for assisting you on your specific use case of your project.
204+
205+
Our team remains available on our dedicated Discord Channel, do not hesitate to join and reach us : <https://discord.gg/ovhcloud>. Ask questions, provide feedback and interact directly with the team that builds our Container and Orchestration services.
206+
207+
Join our [community of users](/links/community).
68.4 KB
Loading
120 KB
Loading
Loading
57 KB
Loading
90.5 KB
Loading
115 KB
Loading
Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
id: ff1f372d-0656-46b5-ac8e-31dcef6e4076
2+
full_slug: public-cloud-managed-rancher-service-iam-authentication

0 commit comments

Comments
 (0)