{"id":20003294,"url":"https://github.com/tompaana/blob-copy-test","last_synced_at":"2026-06-10T17:31:15.587Z","repository":{"id":190967570,"uuid":"614435322","full_name":"tompaana/blob-copy-test","owner":"tompaana","description":"Test project to identify possible problems with cross-region data copying, and to find solutions/workarounds.","archived":false,"fork":false,"pushed_at":"2024-02-07T08:33:57.000Z","size":42,"stargazers_count":2,"open_issues_count":0,"forks_count":1,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-11-28T20:43:42.546Z","etag":null,"topics":["azure-storage","blob-storage","containerization","github-actions","github-workflows","private-endpoint","virtual-network","virtual-network-peering"],"latest_commit_sha":null,"homepage":"","language":"Bicep","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/tompaana.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2023-03-15T15:21:49.000Z","updated_at":"2024-02-07T09:30:34.000Z","dependencies_parsed_at":"2024-01-11T12:41:49.389Z","dependency_job_id":"3c084f34-36a3-4ce0-96aa-b074f0d3be6f","html_url":"https://github.com/tompaana/blob-copy-test","commit_stats":null,"previous_names":["tompaana/blob-copy-test"],"tags_count":3,"template":false,"template_full_name":null,"purl":"pkg:github/tompaana/blob-copy-test","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tompaana%2Fblob-copy-test","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tompaana%2Fblob-copy-test/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tompaana%2Fblob-copy-test/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tompaana%2Fblob-copy-test/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/tompaana","download_url":"https://codeload.github.com/tompaana/blob-copy-test/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/tompaana%2Fblob-copy-test/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":34163253,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-06-10T02:00:07.152Z","response_time":89,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["azure-storage","blob-storage","containerization","github-actions","github-workflows","private-endpoint","virtual-network","virtual-network-peering"],"created_at":"2024-11-13T05:25:02.377Z","updated_at":"2026-06-10T17:31:15.570Z","avatar_url":"https://github.com/tompaana.png","language":"Bicep","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Blob copy test\n\n\u003e **Warning**\n\u003e\n\u003e This is a test project to identify possible problems with cross-region data copying, and to find solutions/workarounds. This is not secure piece of software and running it exposes sensitive information deliberately for troubleshooting purposes.\n\u003e\n\u003e *Viewer discretion is advised.*\n\nThe solution will deploy two, peered virtual networks in different locations (`westeurope` and `swedencentral`) both containing a blob storage and a file share storage; 4 storage accounts in total. None of the storages allow public internet access, but use private endpoints instead. A very simple app service with a Swagger UI is provided to test copying blobs from different accounts to different file shares.\n\n## Prerequisites\n\n* Azure subscription\n* [Azure CLI](https://learn.microsoft.com/cli/azure/install-azure-cli) with [Bicep support](https://learn.microsoft.com/azure/azure-resource-manager/bicep/install#azure-cli)\n* [PowerShell](https://learn.microsoft.com/powershell/scripting/install/installing-powershell)\n* [.NET 6](https://dotnet.microsoft.com/download/dotnet/6.0)\n\nTested in Windows with Azure CLI version 2.56.0.\n\n## Scripts to install/deploy\n\nPowerShell scripts provided to install/deploy the project:\n\n| Script | Description |\n| ------ | ----------- |\n| `DeployToAzure.ps1` | Full install/deployment. Runs all the scripts below in the specified order. |\n| `New-BicepDeployment.ps1` | Creates a resource group and provisions Azure resources specified in the main Bicep template (`/bicep/main.bicep`). |\n| `New-Blobs.ps1` | Uploads the test blobs (to copy later) to storage accounts. |\n| `New-CodeDeployment.ps1` | Deploys the app code (with Swagger) to the app service. |\n\nAll the scripts are (more or less) idempotent. Note that in most cases the scripts will not stop executing when an error occurs. The \"sub\" scripts can be run independently to save time if any of the phases should fail.\n\n## Deploying the solution\n\n1. Login with Azure CLI:\n\n    ```powershell\n    az login\n    ```\n\n    \u003e Verify that you have the right subscription selected with command `az account show`. Change the subscription with command `az account set --subscription \u003csubscription ID\u003e` if necessary.\n\n1. Run the main script:\n\n    ```powershell\n    .\\DeployToAzure.ps1 -ResourceNameMeronym \u003ctwo alphanumeric, lowercase characters\u003e\n    ```\n\n    \u003e The resource name meronym is required for unique resource names should this solution ever be deployed by more than one person.\n\n    \u003e **Note**\n    \u003e\n    \u003e Errors can happen and if they do, rather than starting all over, you can continue from a point closer to the failure point by running the \"sub\" scripts separately:\n    \u003e\n    \u003e ```powershell\n    \u003e .\\New-BicepDeployment.ps1 -ResourceNameMeronym \u003ctwo alphanumeric, lowercase characters\u003e\n    \u003e ```\n    \u003e\n    \u003e ```powershell\n    \u003e .\\New-Blobs.ps1 -ResourceNameMeronym \u003ctwo alphanumeric, lowercase characters\u003e\n    \u003e ```\n    \u003e\n    \u003e ```powershell\n    \u003e .\\New-CodeDeployment.ps1 -ResourceNameMeronym \u003ctwo alphanumeric, lowercase characters\u003e\n    \u003e ```\n    \u003e\n    \u003e If you deleted a previous deployment, due to the soft delete enabled for the Key Vault, you may need to recover it with command:\n    \u003e\n    \u003e ```powershell\n    \u003e az keyvault recover `\n    \u003e     --location westeurope `\n    \u003e     --name kv-copytest\u003cmeronym\u003e-dev `\n    \u003e     --resource-group rg-copytest\u003cmeronym\u003e-dev\n    \u003e ```\n\n1. If all goes well, head to the [Azure portal](https://portal.azure.com) and find the app service and launch it in the browser\n\n1. Copy some blobs using the Swagger UI (or a tool that can do POST calls of your choice)!\n\n1. Clean up by deleting the resource group:\n\n    ```bash\n    az group delete --name rg-copytest\u003cmeronym\u003e-dev\n    ```\n\n## Observed copy results\n\n| App service location | Source blob location | Destination file share location | Copy result |\n| -- | -- | -- | -- |\n| `westeurope` | `westeurope` | `westeurope` | OK |\n| `westeurope` | `westeurope` | `swedencentral` | OK |\n| `westeurope` | `swedencentral` | `westeurope` | FAILS with error `CannotVerifyCopySource` (* |\n| `westeurope` | `swedencentral` | `swedencentral` | OK |\n\n\u003e **Note** *) Workaround\n\u003e\n\u003e Add IP ranges of Azure storage accounts in `westeurope` to the firewall rules of the copy-source blob storage account in `swedencentral` (\"`stctb\u003cmeronym\u003edevswedencentral`\") to allow access.\n\u003e\n\u003e You can find the ranges at [Azure IP Ranges site](https://azureipranges.azurewebsites.net/). Enter \"`Storage.WestEurope`\" to the search box.\n\u003e\n\u003e `/scripts/New-StorageIpRules.ps1` script is provided to automate this workaround. See the documentation in the script file to understand the required parameters.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftompaana%2Fblob-copy-test","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Ftompaana%2Fblob-copy-test","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Ftompaana%2Fblob-copy-test/lists"}