Redis - Manage Redis ACLs via API
Update Redis users ACLs with the OVHcloud API
Update Redis users ACLs with the OVHcloud API
Last updated March 8th, 2022
This page shows you how to update your Redis user ACLs with the OVHcloud API.
As explained on this page: Redis Capabilities, Users & roles, the users' ACLs can not be updated via the OVHcloud Control Panel.
You must therefore use the OVHcloud API.
If you have never used the OVHcloud API before, then follow this tutorial: First Steps with the OVHcloud APIs.
For this tutorial, we consider that your are logged on the relevant API (Europe: https://api.ovh.com, Canada/Asia: https://ca.api.ovh.com). We will use Europe API for this tutorial.
You first need to identify the service, the Redis cluster and the user you want to apply the changes to.
Execute the following API call:
From the resulting list, select and copy the service identifier corresponding to the desired service, also known as serviceName.
Open the following API call, paste your service ID into the serviceName input field and click Execute
:
From the resulting list, select and copy the Redis cluster ID, also known as clusterId.
Open the following API call and do the following steps:
Execute
From the resulting list, find and select the desired user.
To get more details on a user, open the following API call and do the following steps:
Execute
Example:
The result shows four string arrays, which represent the ACLs defined for the given user.
You can follow the official Redis documentation about users and ACL: https://redis.io/topics/acl.
Open the following API call and paste the corresponding inputs (serviceName, clusterId, user).
Now, according the strategy you choosed, set the different values into the string arrays, such as in the example below:
When ready, click Execute
to update the ACL.
The result should be displayed similarly to the example below.
We would love to help answer questions and appreciate any feedback you may have.
Are you on Discord? Connect to our channel at https://discord.gg/PwPqWUpN8G and interact directly with the team that builds our databases service!
Zachęcamy do przesyłania sugestii, które pomogą nam ulepszyć naszą dokumentację.
Obrazy, zawartość, struktura - podziel się swoim pomysłem, my dołożymy wszelkich starań, aby wprowadzić ulepszenia.
Zgłoszenie przesłane za pomocą tego formularza nie zostanie obsłużone. Skorzystaj z formularza "Utwórz zgłoszenie" .
Dziękujemy. Twoja opinia jest dla nas bardzo cenna.
Dostęp do OVHcloud Community Przesyłaj pytania, zdobywaj informacje, publikuj treści i kontaktuj się z innymi użytkownikami OVHcloud Community.
Porozmawiaj ze społecznością OVHcloud