Reputation: 31
I'm hosting a Hugo generated static site in blob storage and the root path displays the site just fine. However, when I click on a link to any other page I receive the below error. I've verified that the actual blob exists so I'm thinking it's a problem with my proxies.json file.
Here is the error
<Error>
<Code>BlobNotFound</Code>
<Message>
The specified blob does not exist. RequestId:304b66fb-401e-00a0-2763-
d2f5b4000000 Time:2018-04-12T13:37:06.9267123Z
</Message>
</Error>
And here is my original proxies.json file. I've gone through some variations of it, and nothing seems to work.
{
"$schema": "http://json.schemastore.org/proxies",
"proxies": {
"root": {
"matchCondition": {
"route": "/"
},
"backendUri": "https://e.blob.core.windows.net/site-content-jrb-fyi/index.html"
},
"firstlevel": {
"matchCondition": {
"route": "/{level1}/{item}"
},
"backendUri": "https://e.blob.core.windows.net/site-content-jrb-fyi/{level1}/{item}"
},
"secondlevel": {
"matchCondition": {
"route": "/{level1}/{level2}/{item}"
},
"backendUri": "https://e.blob.core.windows.net/site-content-jrb-fyi/{level1}/{level2}/{item}"
},
"thirdlevel": {
"matchCondition": {
"route": "/{level1}/{level2}/{level3}/{item}"
},
"backendUri": "https://e.blob.core.windows.net/site-content-jrb-fyi/{level1}/{level2}/{level3}/{item}"
},
"fourthlevel": {
"matchCondition": {
"route": "/{level1}/{level2}/{level3}/{level4}/{item}"
},
"backendUri": "https://e.blob.core.windows.net/site-content-jrb-fyi/{level1}/{level2}/{level3}/{level4}/{item}"
},
"rest": {
"matchCondition": {
"route": "{*restOfPath}"
},
"backendUri": "https://e.blob.core.windows.net/site-content-jrb-fyi/{restOfPath}"
}
}
}
Here is the file structure in the container
├───about
├───blog
│ ├───ghost-is-not-my-blog-engine
│ ├───hugo-with-azure-function-proxies
│ └───page
│ └───1
├───categories
│ ├───azure
│ │ └───page
│ │ └───1
│ ├───azure-function-proxies
│ │ └───page
│ │ └───1
│ ├───cms
│ │ └───page
│ │ └───1
│ ├───ghost
│ │ └───page
│ │ └───1
│ └───hugo
│ └───page
│ └───1
├───css
├───fonts
├───img
│ └───main
├───js
└───tag
Any help would be greatly appreciated.
Thanks,
John
Upvotes: 1
Views: 721
Reputation: 323
I know this is old, but this error comes up when your blob container is not setup to allow anonymous read only access.
From the Azure portal, you can update the public access level for one or more containers:
Navigate to your storage account overview in the Azure portal.
Under Blob service on the menu blade, select Blobs.
Select the containers for which you want to set the public access level.
Use the Change access level button to display the public access settings.
Select the desired public access level from the Public access level dropdown and click the OK button to apply the change to the selected containers.
Upvotes: 1