Skip to content

FEAT: Support editing config from GUI - #2486

Open
Behnam (behnam-o) wants to merge 28 commits into
microsoft:mainfrom
behnam-o:custom-initializers
Open

FEAT: Support editing config from GUI#2486
Behnam (behnam-o) wants to merge 28 commits into
microsoft:mainfrom
behnam-o:custom-initializers

Conversation

@behnam-o

@behnam-o Behnam (behnam-o) commented Aug 25, 2026

Copy link
Copy Markdown
Contributor

Problem

Previously, changing configuration, environment values, or initializer code in a deployed CoPyRIT instance required direct access to its filesystem, container, or deployment configuration. Changes could also be lost when the container restarted.

This change provides a persistent, browser-based workflow for managing those resources and applying changes without redeploying the application.

Summary

Adds GUI-based management of PyRIT backend configuration, enabling deployed CoPyRIT instances to be configured without direct filesystem or container access.

  • Adds support for using a .pyrit_conf Azure Blob Storage in addition to local files.
  • Adds backend APIs and a GUI editor for .pyrit_conf (regardless of whether it's a local file or blob)
  • Adds backend APIs and a GUI editor for dotenv and Azure Key Vault environment sources.
  • Adds support for persisting custom initializer scripts in Azure Blob Storage in addition to the default local path
  • Adds GUI for creating and removing custom initializers (backend already exists - just missed a "list" API)
  • Updates Docker and Bicep deployment configuration to let us use a custom conf file (to take advantage of the new feature that supports pointing to a blob)
  • Updates the docker and deployment configuration to better handle AKV-referenced env vars (instead of letting ARM read the AKV, set its content to an env var, which is then read in start.sh and written to a local file in the container, just let start.sh pass the AKV reference directly in the generate conf file)
  • Introduce an admin group, and requires the user be a member of that to access the conf management APIs.

Comment thread pyrit/memory/memory_interface.py Outdated
Comment thread pyrit/backend/main.py Outdated
Comment thread pyrit/backend/services/initializer_service.py Outdated
Comment thread frontend/src/components/Initializers/CustomInitializers.tsx Outdated
@behnam-o Behnam (behnam-o) changed the title FEAT: Support creating custom initializers and applying them via GUI FEAT: Support editing config from GUI Aug 26, 2026
@behnam-o
Behnam (behnam-o) marked this pull request as draft August 26, 2026 21:50
@behnam-o
Behnam (behnam-o) marked this pull request as ready for review August 27, 2026 17:28
Comment thread pyrit/backend/routes/initializers.py
Comment thread pyrit/backend/routes/configuration.py
Comment thread pyrit/registry/components/initializer_registry.py
Comment thread pyrit/backend/main.py Outdated
Comment thread frontend/src/components/Sidebar/Navigation.tsx Outdated
Comment thread docker/start.sh Outdated
Comment thread infra/README.md Outdated
Comment thread pyrit/registry/components/initializer_registry.py
Comment thread tests/unit/backend/test_initializer_service.py
Comment thread pyrit/backend/services/configuration_file_service.py
Comment thread infra/main.bicep
@varunj-msft

Copy link
Copy Markdown
Contributor

Left a few notes — the video made this much easier to follow! Only two I'd actually give weight on: gui-deploy.yml doesn't pass the new required adminGroupObjectId (param files and deploy_instance.py all got it, just not the pipeline), and a quoted "false" on allow_custom_initializers reads truthy. The rest are minor/follow-up material and non-blocking!

Comment thread doc/getting_started/pyrit_conf.md Outdated
Comment thread frontend/src/components/BackendConfiguration/BackendConfiguration.tsx Outdated
Comment thread frontend/src/components/BackendConfiguration/BackendConfiguration.tsx Outdated
Comment thread frontend/src/components/Configuration/YamlEditor.tsx
Comment thread frontend/src/components/Initializers/CustomInitializers.tsx Outdated
Comment thread frontend/src/types/index.ts
Comment thread frontend/src/App.tsx Outdated
Comment thread pyrit/backend/middleware/auth.py
Comment thread pyrit/backend/routes/configuration.py
Comment thread pyrit/backend/services/environment_file_service.py Outdated
Comment thread pyrit/registry/components/initializer_registry.py
@hannahwestra25

Copy link
Copy Markdown
Contributor

some of the docs need to be updated including gui.md (being the main one)

Comment thread pyrit/backend/middleware/auth.py Outdated
Comment thread pyrit/backend/routes/configuration.py
Comment thread pyrit/backend/services/configuration_file_service.py
Comment thread infra/main.bicep
Comment thread pyrit/backend/routes/initializers.py
Comment thread pyrit/backend/services/environment_file_service.py Outdated
Comment thread pyrit/backend/services/environment_file_service.py Outdated
Comment thread docker/start.sh
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.

5 participants