Skip to content

Commit

Permalink
Merge branch 'main' of https://github.com/microsoft/AzureTRE into mar…
Browse files Browse the repository at this point in the history
…robi/issue3992
  • Loading branch information
marrobi committed Oct 10, 2024
2 parents e269f86 + 400766b commit 4c42733
Show file tree
Hide file tree
Showing 191 changed files with 4,075 additions and 2,496 deletions.
24 changes: 12 additions & 12 deletions .github/scripts/yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -774,12 +774,12 @@ brace-expansion@^1.1.7:
balanced-match "^1.0.0"
concat-map "0.0.1"

braces@^3.0.2:
version "3.0.2"
resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.2.tgz#3454e1a462ee8d599e236df336cd9ea4f8afe107"
integrity sha512-b8um+L1RzM3WDSzvhm6gIz1yfTbBt6YTlcEKAvsmqCZZFw46z626lVj9j1yEPW33H5H+lBQpZMP1k8l+78Ha0A==
braces@^3.0.3:
version "3.0.3"
resolved "https://registry.yarnpkg.com/braces/-/braces-3.0.3.tgz#490332f40919452272d55a8480adc0c441358789"
integrity sha512-yQbXgO/OSZVD2IsiLlro+7Hf6Q18EJrKSEsdoMzKePKXct3gvD8oLcOQdIzGupr5Fj+EDe8gO/lxc1BzfMpxvA==
dependencies:
fill-range "^7.0.1"
fill-range "^7.1.1"

browser-process-hrtime@^1.0.0:
version "1.0.0"
Expand Down Expand Up @@ -1109,10 +1109,10 @@ fb-watchman@^2.0.0:
dependencies:
bser "2.1.1"

fill-range@^7.0.1:
version "7.0.1"
resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.0.1.tgz#1919a6a7c75fe38b2c7c77e5198535da9acdda40"
integrity sha512-qOo9F+dMUmC2Lcb4BbVvnKJxTPjCm+RRpe4gDuGrzkL7mEVl/djYSu2OdQ2Pa302N4oqkSg9ir6jaLWJ2USVpQ==
fill-range@^7.1.1:
version "7.1.1"
resolved "https://registry.yarnpkg.com/fill-range/-/fill-range-7.1.1.tgz#44265d3cac07e3ea7dc247516380643754a05292"
integrity sha512-YsGpe3WHLK8ZYi4tWDg2Jy3ebRz2rXowDxnld4bkQB00cc/1Zw9AWnC0i9ztDJitivtQvaI9KaLyKrc+hBW0yg==
dependencies:
to-regex-range "^5.0.1"

Expand Down Expand Up @@ -2479,9 +2479,9 @@ write-file-atomic@^3.0.0:
typedarray-to-buffer "^3.1.5"

ws@^7.4.6:
version "7.5.9"
resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591"
integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q==
version "7.5.10"
resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.10.tgz#58b5c20dc281633f6c19113f39b349bd8bd558d9"
integrity sha512-+dbF1tHwZpXcbOJdVOkzLDxZP1ailvSxM6ZweXTegylPny803bFhA+vqBYw4s31NSAk4S2Qz+AKXK9a4wkdjcQ==

xml-name-validator@^3.0.0:
version "3.0.0"
Expand Down
2 changes: 2 additions & 0 deletions .github/workflows/deploy_tre_reusable.yml
Original file line number Diff line number Diff line change
Expand Up @@ -401,6 +401,8 @@ jobs:
BUNDLE_DIR: "./templates/workspace_services/ohdsi"}
- {BUNDLE_TYPE: "workspace_service",
BUNDLE_DIR: "./templates/workspace_services/azuresql"}
- {BUNDLE_TYPE: "workspace_service",
BUNDLE_DIR: "./templates/workspace_services/openai"}
- {BUNDLE_TYPE: "user_resource",
BUNDLE_DIR: "./templates/workspace_services/guacamole/user_resources/guacamole-azure-windowsvm"}
- {BUNDLE_TYPE: "user_resource",
Expand Down
99 changes: 98 additions & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,22 +1,119 @@
<!-- markdownlint-disable MD041 -->
## 0.19.0 (Unreleased)
## 0.20.0 (Unreleased)

**BREAKING CHANGES & MIGRATIONS**:

FEATURES:

ENHANCEMENTS:

BUG FIXES:

COMPONENTS:

## 0.19.1

**BREAKING CHANGES & MIGRATIONS**:
* Workspace creation blocked due to Azure API depreciation ([#4095](https://github.com/microsoft/AzureTRE/issues/4095))

ENHANCEMENTS:
* Update Unrestricted and Airlock Import Review workspaces to be built off the Base workspace 0.19.0 ([#4087](https://github.com/microsoft/AzureTRE/pull/4087))
* Update Release Docs (part of [#2727](https://github.com/microsoft/AzureTRE/issues/2727))
* Add info regarding workspace limit into docs ([#3920](https://github.com/microsoft/AzureTRE/issues/3920))

BUG FIXES:
* Workspace creation blocked due to Azure API depreciation ([#4095](https://github.com/microsoft/AzureTRE/issues/4095))

COMPONENTS:
| name | version |
| ----- | ----- |
| devops | 0.5.2 |
| core | 0.10.8 |
| ui | 0.5.28 |
| tre-service-guacamole-linuxvm | 1.0.3 |
| tre-service-guacamole-import-reviewvm | 0.2.9 |
| tre-service-guacamole-export-reviewvm | 0.1.9 |
| tre-service-guacamole-windowsvm | 1.0.1 |
| tre-service-guacamole | 0.10.9 |
| tre-service-databricks | 1.0.4 |
| tre-service-mlflow | 0.7.9 |
| tre-service-innereye | 0.6.5 |
| tre-workspace-service-ohdsi | 0.2.5 |
| tre-workspace-service-gitea | 1.0.5 |
| tre-workspace-service-mysql | 1.0.4 |
| tre-workspace-service-azuresql | 1.0.10 |
| tre-user-resource-aml-compute-instance | 0.5.7 |
| tre-service-azureml | 0.8.11 |
| tre-workspace-service-health | 0.2.6 |
| tre-workspace-service-openai | 1.0.1 |
| tre-workspace-airlock-import-review | 0.13.1 |
| tre-workspace-unrestricted | 0.12.1 |
| tre-workspace-base | 1.5.7 |
| tre-shared-service-cyclecloud | 0.6.3 |
| tre-shared-service-databricks-private-auth | 0.1.6 |
| tre-shared-service-sonatype-nexus | 3.0.1 |
| tre-shared-service-admin-vm | 0.4.4 |
| tre-shared-service-firewall | 1.2.1 |
| tre-shared-service-gitea | 1.0.3 |
| tre-shared-service-certs | 0.5.2 |
| tre-shared-service-airlock-notifier | 1.0.2 |

## 0.19.0

FEATURES:
* Azure SQL Workspace Service ([#3969](https://github.com/microsoft/AzureTRE/issues/3969))
* OpenAI Workspace Service ([#3810](https://github.com/microsoft/AzureTRE/issues/3810))

ENHANCEMENTS:
* Add Case Study Docs ([#1366](https://github.com/microsoft/AzureTRE/issues/1366))
* Ability to host TRE on a custom domain ([#4014](https://github.com/microsoft/AzureTRE/pull/4014))
* Remove AppServiceFileAuditLogs diagnostic setting ([#4033](https://github.com/microsoft/AzureTRE/issues/4033))
* Update to the Airlock Notifier Shared Service ([#3909](https://github.com/microsoft/AzureTRE/issues/3909))

BUG FIXES:
* Removed 429 Error (Costs API) form presenting in UI ([#3929](https://github.com/microsoft/AzureTRE/issues/3929))
* Fix numbering issue within `bug_report.md` template ([#4028](https://github.com/microsoft/AzureTRE/pull/4028))
* Disable public network access to the API App Service ([#3986](https://github.com/microsoft/AzureTRE/issues/3986))
* Fix Guacamole shared drive always enabled ([#3885](https://github.com/microsoft/AzureTRE/issues/3885))
* Add Dependabot Security updates for July
* Update Docs to format emojis properly ([#4027](https://github.com/microsoft/AzureTRE/issues/4027))
* Update API and Resource Processor opentelemetry versions ([#4052](https://github.com/microsoft/AzureTRE/issues/4052))
* Fix broken links in new Case Study Docs
* Update Linux VM to stop screensaver locking out the user ([#4065](https://github.com/microsoft/AzureTRE/issues/4065))
* Update .NET version on Linux VMs ([#4067](https://github.com/microsoft/AzureTRE/issues/4067))

COMPONENTS:
| name | version |
| ----- | ----- |
| devops | 0.5.1 |
| core | 0.10.6 |
| ui | 0.5.28 |
| tre-service-guacamole-linuxvm | 1.0.2 |
| tre-service-guacamole-import-reviewvm | 0.2.8 |
| tre-service-guacamole-export-reviewvm | 0.1.8 |
| tre-service-guacamole-windowsvm | 1.0.0 |
| tre-service-guacamole | 0.10.8 |
| tre-service-databricks | 1.0.3 |
| tre-service-mlflow | 0.7.8 |
| tre-service-innereye | 0.6.4 |
| tre-workspace-service-ohdsi | 0.2.4 |
| tre-workspace-service-gitea | 1.0.3 |
| tre-workspace-service-mysql | 1.0.2 |
| tre-workspace-service-azuresql | 1.0.9 |
| tre-user-resource-aml-compute-instance | 0.5.7 |
| tre-service-azureml | 0.8.10 |
| tre-workspace-service-health | 0.2.5 |
| tre-workspace-airlock-import-review | 0.12.16 |
| tre-workspace-unrestricted | 0.11.4 |
| tre-workspace-base | 1.5.4 |
| tre-shared-service-cyclecloud | 0.5.5 |
| tre-shared-service-databricks-private-auth | 0.1.5 |
| tre-shared-service-sonatype-nexus | 3.0.0 |
| tre-shared-service-admin-vm | 0.4.3 |
| tre-shared-service-firewall | 1.2.0 |
| tre-shared-service-gitea | 1.0.2 |
| tre-shared-service-certs | 0.5.1 |
| tre-shared-service-airlock-notifier | 1.0.1 |

## 0.18.0

Expand Down
7 changes: 7 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,13 @@ terraform-deploy:
&& . ${MAKEFILE_DIR}/devops/scripts/load_env.sh ${DIR}/.env \
&& cd ${DIR}/terraform/ && ./deploy.sh

terraform-upgrade:
$(call target_title, "Upgrading ${DIR} with Terraform") \
&& . ${MAKEFILE_DIR}/devops/scripts/check_dependencies.sh env \
&& . ${MAKEFILE_DIR}/devops/scripts/load_and_validate_env.sh \
&& . ${MAKEFILE_DIR}/devops/scripts/load_env.sh ${DIR}/.env \
&& cd ${DIR}/terraform/ && ./upgrade.sh

terraform-import:
$(call target_title, "Importing ${DIR} with Terraform") \
&& . ${MAKEFILE_DIR}/devops/scripts/check_dependencies.sh env \
Expand Down
2 changes: 1 addition & 1 deletion airlock_processor/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.7.1"
__version__ = "0.7.2"
2 changes: 1 addition & 1 deletion airlock_processor/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
azure-core==1.30.0
azure-functions==1.17.0
azure-storage-blob==12.19.0
azure-identity==1.14.1
azure-identity==1.16.1
azure-mgmt-storage==21.1.0
azure-mgmt-resource==23.0.1
pydantic==1.10.13
2 changes: 1 addition & 1 deletion api_app/_version.py
Original file line number Diff line number Diff line change
@@ -1 +1 @@
__version__ = "0.18.9"
__version__ = "0.19.2"
2 changes: 1 addition & 1 deletion api_app/api/routes/api.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
{"name": "workspaces", "description": " **Workspace Owners and Researchers** can view their own workspaces"},
{"name": "workspace services", "description": "**Workspace Owners** administer workspace services, **Workspace Owners and Researchers** can view services in the workspaces they belong to"},
{"name": "user resources", "description": "**Researchers** administer and can view their own researchers, **Workspace Owners** can view/update/delete all user resources in their workspaces"},
{"name": "shared services", "description": "**TRE administratiors** administer shared services"},
{"name": "shared services", "description": "**TRE administratiors** administer shared services"}
]

# Root
Expand Down
8 changes: 8 additions & 0 deletions api_app/api/routes/workspaces.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@
from models.schemas.workspace_service import WorkspaceServiceInCreate, WorkspaceServicesInList, WorkspaceServiceInResponse
from models.schemas.resource import ResourceHistoryInList, ResourcePatch
from models.schemas.resource_template import ResourceTemplateInformationInList
from models.schemas.users import UsersInResponse
from resources import strings
from services.access_service import AuthConfigValidationError
from services.authentication import get_current_admin_user, \
Expand Down Expand Up @@ -187,6 +188,13 @@ async def invoke_action_on_workspace(response: Response, action: str, user=Depen
return OperationInResponse(operation=operation)


@workspaces_shared_router.get("/workspaces/{workspace_id}/users", response_model=UsersInResponse, name=strings.API_GET_WORKSPACE_USERS)
async def get_workspace_users(workspace=Depends(get_workspace_by_id_from_path)) -> UsersInResponse:
access_service = get_access_service()
users = access_service.get_workspace_users(workspace)
return UsersInResponse(users=users)


# workspace operations
# This method only returns templates that the authenticated user is authorized to use
@workspaces_shared_router.get("/workspaces/{workspace_id}/workspace-service-templates", response_model=ResourceTemplateInformationInList, name=strings.API_GET_WORKSPACE_SERVICE_TEMPLATES_IN_WORKSPACE)
Expand Down
2 changes: 1 addition & 1 deletion api_app/models/domain/authentication.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@
class User(BaseModel):
id: str
name: str
email: str
email: str = Field(None)
roles: List[str] = Field([])
roleAssignments: List[RoleAssignment] = Field([])
28 changes: 28 additions & 0 deletions api_app/models/schemas/users.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
from pydantic import BaseModel, Field
from typing import List

from models.domain.authentication import User


class UsersInResponse(BaseModel):
users: List[User] = Field(..., title="Users", description="List of users assigned to the workspace")

class Config:
schema_extra = {
"example": {
"users": [
{
"id": 1,
"name": "John Doe",
"email": "[email protected]",
"roles": ["WorkspaceOwner", "WorkspaceResearcher"]
},
{
"id": 2,
"name": "Jane Smith",
"email": "[email protected]",
"roles": ["WorkspaceResearcher"]
}
]
}
}
6 changes: 3 additions & 3 deletions api_app/requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -2,21 +2,21 @@ aiohttp==3.9.4
azure-core==1.30.0
azure-cosmos==4.5.1
azure-eventgrid==4.15.0
azure-identity==1.14.1
azure-identity==1.16.1
azure-mgmt-compute==30.3.0
azure-mgmt-cosmosdb==9.3.0
azure-mgmt-costmanagement==4.0.1
azure-mgmt-resource==23.0.1
azure-mgmt-storage==21.1.0
azure-monitor-opentelemetry==1.2.0
azure-monitor-opentelemetry~=1.6
azure-servicebus==7.11.3
azure-storage-blob==12.19.0
fastapi==0.110.0
fastapi-utils==0.2.1
gunicorn==22.0.0
jsonschema[format_nongpl]==4.19.1
msal==1.26.0
opentelemetry.instrumentation.logging==0.44b0
opentelemetry.instrumentation.logging>=0.44b0
pandas==2.0.3
PyJWT==2.8.0
pytz==2022.7
Expand Down
2 changes: 2 additions & 0 deletions api_app/resources/strings.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,8 @@
API_UPDATE_WORKSPACE = "Update an existing workspace"
API_INVOKE_ACTION_ON_WORKSPACE = "Invoke action on a workspace"

API_GET_WORKSPACE_USERS = "Get all users for a workspace"

API_GET_ALL_WORKSPACE_SERVICES = "Get all workspace services for workspace"
API_GET_WORKSPACE_SERVICE_BY_ID = "Get workspace service by Id"
API_CREATE_WORKSPACE_SERVICE = "Create a workspace service"
Expand Down
Loading

0 comments on commit 4c42733

Please sign in to comment.