Pavan
Pavan

Reputation: 1083

Adding Users to SQL Azure Database with ARM template

I am trying to create users inside DB and grant some specific permission each user; with the help of ARM template. But I do not find a way to do it using ARM.

Can someone tell me is it supported by the ARM templates to

  1. Create Users for DB and grant permissions?
  2. does it support to deploy a Dacpac to DB?

Upvotes: 8

Views: 3615

Answers (1)

Rob Reagan
Rob Reagan

Reputation: 7696

You can't insert users into a database using an ARM template to my knowledge. I've looked pretty closely - someone correct me if I'm wrong.

As for the ability to get data into the system, you have some options with VSTS Build.

  1. You can use a Powershell task to call invoke_sqlcmd, which you can insert users using your own script.

  2. My personal favorite is the Azure SQL Database deployment task, which will deploy a DACPAC. In the DACPAC you can set up users as needed.

Upvotes: 8

Related Questions