Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Automatically download data onto review VM #2513

Closed
Tracked by #2245
tanya-borisova opened this issue Aug 26, 2022 · 2 comments · Fixed by #2726
Closed
Tracked by #2245

Automatically download data onto review VM #2513

tanya-borisova opened this issue Aug 26, 2022 · 2 comments · Fixed by #2726
Assignees
Labels
airlock story Stories are the smallest unit of work to be done for a project.

Comments

@tanya-borisova
Copy link
Contributor

tanya-borisova commented Aug 26, 2022

In order to simplify the task of the Airlock Manager to review incoming requests, it would be great if the data that they need to review would be pre-populated on the review VM that they are going to use.

To achieve this, we can accept a SAS URL for downloading request data as a template parameter for exportreview and importreview user resource templates, and have a cloudinit script that on startup downloads the data using the URL passed in.

@tanya-borisova tanya-borisova added airlock story Stories are the smallest unit of work to be done for a project. labels Aug 26, 2022
@anatbal
Copy link
Contributor

anatbal commented Sep 15, 2022

After investigating, came around with these steps:

  1. Create a new user resource template, airlock request id (aka container name) should be passed as a parameter.
  2. Give the VM's managed identity a Storage Blob Data Reader role assignment on the container.
  3. Add a firewall role under network rule collection (can be added inside the one that is created for guacamole/in a similar way) that allows the review vm subnet access the service tag AzureResourceManageron port 443
  4. Implement a cloud-init script with these two commands:
 az login --identity --allow-no-subscriptions
 az storage blob download-batch --account-name <import_storage_account> --source <container_name> --destination <target_folder> --auth-mode login

@tanya-borisova
Copy link
Contributor Author

Updated the description to describe the option we have settled on.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
airlock story Stories are the smallest unit of work to be done for a project.
Projects
None yet
2 participants