Hi everyone,
On my static site, when I run “hugo server” locally, my main CSS stylesheet file (domain.com/scss/style.min.css) is well available with the right MIME Type (text/css).
When I publish this Website on Google AppEngine, with exactly the same code, my file is still available but the MIME Type is modified to “application/octet-stream”, which causes the CSS not loading at all…
Here is the code on my “head.html” file where the Main Stylesheet is defined:
{{ "<!-- Main Stylesheet -->" | safeHTML }}
{{ $styles := resources.Get "scss/style.scss" | toCSS | minify }}
<link rel="stylesheet" href="{{ $styles.Permalink }}" media="screen">
Here is the code of the “app.yaml” file to make the site available (nothing really special here):
runtime: python37
instance_class: F1
handlers:
## static content routing
- url: /
static_files: src/public/index.html
upload: src/public/*
secure: always
# hugo generates pages in directories so check for index.html first
- url: /(.*)/
static_files: src/public/\1/index.html
upload: src/public/*
secure: always
- url: /
static_dir: src/public/
secure: always
error_handlers:
- file: default_error.html
Is someone can help me, I’m stuck for many hours now and I don’t find any way to solve my problem…
Thanks