-
Notifications
You must be signed in to change notification settings - Fork 907
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
HUGO_ENV production prevents site from being indexed by Google on AWS #217
Comments
This might be a good issue to raise on the Hugo forums too, as it'll affect sites that use other themes too. I'll see if I can figure anything out in the meantime but I haven't deployed to AWS myself. |
(do let us know if the Hugo people have any ideas as we can add any workarounds to the docs) |
Hi, I raised this on the Hugo forums. See https://discourse.gohugo.io/t/checking-env-variable-prevents-site-from-being-indexed-by-google-on-aws/23707 |
1 similar comment
Hi, I raised this on the Hugo forums. See https://discourse.gohugo.io/t/checking-env-variable-prevents-site-from-being-indexed-by-google-on-aws/23707 |
Oh great, can you try the solution that bep suggests and if it works we can see about updating the theme. |
Hi, tested it and it seems to work. Now onto figuring out why Google refuses to fetch Hugo's sitemap :). |
Closing this issue. |
Hi, I just got bitten by this today on Graphviz and some of our pages are might be unindexed by Google till I redeploy :-( https://gitlab.com/graphviz/graphviz.gitlab.io/-/issues/99 Above, @LisaFC mentions "if it works we can see about updating the theme", could we reopen this issue (I don't have access) to track updating the theme so that others aren't bitten by this? |
The following code in the header partial will prevent Google from indexing a Docsy based site unless the HUGO_ENV env variable is set to PRODUCTION.
I'm deploying my site an AWS bucket and so far as I know the env variable cannot be read (https://stackoverflow.com/questions/36226645/configuring-environment-variables-for-static-web-site-on-aws-s3). So I ended up commenting out those lines of code.
Does anyone have experience deploying to AWS and handling the above?
The text was updated successfully, but these errors were encountered: