Skip to content

Conversation

pamelafox
Copy link
Collaborator

Purpose

Fixes #2325 and related issues.

At least a few developers have gotten themselves into situations where they've set some auth-related parameters but not others, so I've added checks to the auth_init scripts.

Now developers will see errors like these two:

Screenshot 2025-02-26 at 1 04 11 PM

Screenshot 2025-02-26 at 1 03 07 PM

I also improved the docs, based on o3-mini suggested formatting.

Does this introduce a breaking change?

When developers merge from main and run the server, azd up, or azd deploy, will this produce an error?
If you're not sure, try it out on an old environment.

[ ] Yes
[X] No

Does this require changes to learn.microsoft.com docs?

This repository is referenced by this tutorial
which includes deployment, settings and usage instructions. If text or screenshot need to change in the tutorial,
check the box below and notify the tutorial author. A Microsoft employee can do this for you if you're an external contributor.

[ ] Yes
[X] No

Type of change

[ ] Bugfix
[ ] Feature
[ ] Code style update (formatting, local variables)
[ ] Refactoring (no functional changes, no api changes)
[X] Documentation content changes
[X] Other... Please describe: Developer experience

Code quality checklist

See CONTRIBUTING.md for more details.

N/A, we don't have Bicep tests

Copy link
Contributor

@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR Overview

This pull request improves the authentication and access control documentation and introduces environment variable checks for auth-related configuration. The changes include reformatting of the login and access control instructions, grouping related CLI commands into clearly marked steps, and updating the command descriptions for better clarity and consistency.

Reviewed Changes

File Description
docs/login_and_acl.md Reorganized and reformatted authentication and ACL setup instructions for improved readability and consistency.

Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.

1. Run `azd env set AZURE_AUTH_TENANT_ID <YOUR-TENANT-ID>` to set the tenant ID associated with authentication.
1. If your auth tenant ID is different from your currently logged in tenant ID, run `azd auth login --tenant-id <YOUR-TENANT-ID>` to login to the authentication tenant simultaneously.
1. Run `azd up` to deploy the app.
1. **Enable authentication for the app**
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks - this looks a lot clearer

$AZURE_ENFORCE_ACCESS_CONTROL = (azd env get-value AZURE_ENFORCE_ACCESS_CONTROL)
$USE_CHAT_HISTORY_COSMOS = (azd env get-value USE_CHAT_HISTORY_COSMOS)

if ($AZURE_ENABLE_GLOBAL_DOCUMENT_ACCESS -eq "true") {
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems like the right scenario to check

@pamelafox pamelafox marked this pull request as ready for review February 26, 2025 21:31
@pamelafox pamelafox merged commit 193962d into Azure-Samples:main Feb 26, 2025
15 checks passed
@pamelafox pamelafox deleted the authissues branch February 26, 2025 22:24
hasithb pushed a commit to hasithb/azure-search-openai-demo that referenced this pull request Oct 19, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

How do I upload documents with user/group access

2 participants