Azure / Azure-Governance-Visualizer

Azure Governance Visualizer aka AzGovViz is a PowerShell script that captures Azure Governance related information such as Azure Policy, RBAC (a lot more) by polling Azure ARM, Storage and Microsoft Graph APIs.
MIT License
92 stars 24 forks source link

SyncAzGovViz - 403 Forbidden Downloading Repo Archive #19

Closed SShooks-Azamara closed 1 year ago

SShooks-Azamara commented 1 year ago

AzGovViz version "AzGovVizVersion": "0.0.0", "AcceleratorVersion": "0.0.1"

CodeRunPlatform GitHub Action

Describe the bug The 'UpdateAzGovVizAutomatically' job within the 'SyncAzGovViz' workflows fails to download the repo archive, reporting an HTTP 403 response. This is especially problematic for a first-time install, as the workflow reports a successful run but the 'DeployAzGovViz' workflow will fail.

--2023-08-28 19:57:40-- https://github.com/Azure/Azure-Governance-Visualizer/archive/refs/heads/master.zip Resolving github.com (github.com)... 140.82.112.4 Connecting to github.com (github.com)|140.82.112.4|:443... connected. HTTP request sent, awaiting response... 302 Found Location: https://codeload.github.com/Azure/Azure-Governance-Visualizer/zip/refs/heads/master [following] --2023-08-28 19:57:41-- https://codeload.github.com/Azure/Azure-Governance-Visualizer/zip/refs/heads/master Resolving codeload.github.com (codeload.github.com)... 140.82.114.10 Connecting to codeload.github.com (codeload.github.com)|140.82.114.10|:443... connected. HTTP request sent, awaiting response... 403 Forbidden 2023-08-28 19:57:41 ERROR 403: Forbidden.

Error: Process completed with exit code 8.

sebassem commented 1 year ago

AzGovViz version "AzGovVizVersion": "0.0.0", "AcceleratorVersion": "0.0.1"

CodeRunPlatform GitHub Action

Describe the bug The 'UpdateAzGovVizAutomatically' job within the 'SyncAzGovViz' workflows fails to download the repo archive, reporting an HTTP 403 response. This is especially problematic for a first-time install, as the workflow reports a successful run but the 'DeployAzGovViz' workflow will fail.

--2023-08-28 19:57:40-- https://github.com/Azure/Azure-Governance-Visualizer/archive/refs/heads/master.zip Resolving github.com (github.com)... 140.82.112.4 Connecting to github.com (github.com)|140.82.112.4|:443... connected. HTTP request sent, awaiting response... 302 Found Location: https://codeload.github.com/Azure/Azure-Governance-Visualizer/zip/refs/heads/master [following] --2023-08-28 19:57:41-- https://codeload.github.com/Azure/Azure-Governance-Visualizer/zip/refs/heads/master Resolving codeload.github.com (codeload.github.com)... 140.82.114.10 Connecting to codeload.github.com (codeload.github.com)|140.82.114.10|:443... connected. HTTP request sent, awaiting response... 403 Forbidden 2023-08-28 19:57:41 ERROR 403: Forbidden.

Error: Process completed with exit code 8.

Thanks for submitting this issue. Did you see this error when you initially ran the "DeployAzGovVizAccelerator" workflow as it automatically triggers the "SyncAzGovViz" workflow ?

SShooks-Azamara commented 1 year ago

@sebassem, I didn't notice it initially, but the error was present on the first, and every subsequent, run.

sebassem commented 1 year ago

@sebassem, I didn't notice it initially, but the error was present on the first, and every subsequent, run.

I would ask you to try again as this is simply a download of a public file, so there shouldn't be any access restrictions. I saw there were issues with GitHub yesterday.

SShooks-Azamara commented 1 year ago

@sebassem Well, I picked a fine day for my first foray into using GitHub. I just retried and the download was successful. There was a subsequent error, below, but I will troubleshoot that separately. Thank you for your assistance and work on this project.

unzip: cannot find or open master.zip, master.zip.zip or master.zip.ZIP. Error: Process completed with exit code 9.

sebassem commented 1 year ago

@sebassem Well, I picked a fine day for my first foray into using GitHub. I just retried and the download was successful. There was a subsequent error, below, but I will troubleshoot that separately. Thank you for your assistance and work on this project.

unzip: cannot find or open master.zip, master.zip.zip or master.zip.ZIP. Error: Process completed with exit code 9.

Thanks for the confirmation, can I ask you if you are using this repo or the accelerator's ?

SShooks-Azamara commented 1 year ago

@sebassem, I started with the accelerator, so perhaps my issue should have been opened there instead and I have found the source of the unzip issue (downloading main.zip and trying to unzip master.zip), one I almost certainly created in the course of troubleshooting the initial download issue.

With the inability to download the repo via the workflow, my solution to this thread's issue was to manually download 'Azure-Governance-Visualizer' and unzip it into my private repository that was generated from 'https://github.com/Azure/Azure-Governance-Visualizer-Accelerator'

sebassem commented 1 year ago

@sebassem, I started with the accelerator, so perhaps my issue should have been opened there instead and I have found the source of the unzip issue (downloading main.zip and trying to unzip master.zip), one I almost certainly created in the course of troubleshooting the initial download issue.

With the inability to download the repo via the workflow, my solution to this thread's issue was to manually download 'Azure-Governance-Visualizer' and unzip it into my private repository that was generated from 'https://github.com/Azure/Azure-Governance-Visualizer-Accelerator'

Thanks for the clarification, I would do another fresh fork/deployment from the accelerator repo to make sure that everything is up-to-date