简体   繁体   中英

How to generate azure storage secret credentials?

In Kuberentes secret, required format is:

apiVersion: v1
kind: Secret
metadata:
  name: azcreds
type: Opaque
stringData: # use `stringData` for raw credential string or `data` for base64 encoded string
  AZ_CLIENT_ID: xxxxx
  AZ_CLIENT_SECRET: xxxxx
  AZ_SUBSCRIPTION_ID: xxxxx
  AZ_TENANT_ID: xxxxx

How do i get these credentials? I have a Storage account, and when I go to Access keys I only see Key and ConnectionString

Your secret template seems to refer to Azure AD Application Registrations.

You need to create a new App Registration and assign the required permissions on the storage account (eg Blob Storage Contributor)

https://docs.microsoft.com/en-us/azure/active-directory/develop/quickstart-register-app

https://docs.microsoft.com/en-us/azure/role-based-access-control/role-assignments-portal?tabs=current

  • Firstly, you need to Login to Azure Portal
  • Then open Azure Active Directory
  • Then Click on App Registrations
  • Then Click on your owned application

在此处输入图像描述

Then Click on your application, You will find the credentials as below:

在此处输入图像描述

To find the Client secret you need to Click on App registrations the click on Certificates and Secrets then you will find your Secret as below:

在此处输入图像描述

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM