Website: wrong content-type for some blogs at k8s.io/blog/

Created on 22 Oct 2019  ·  4Comments  ·  Source: kubernetes/website

This is a Bug Report

Problem:

Kubernetes 1.2 and simplifying advanced networking with Ingress
Kubernetes 1.2: Even more performance upgrades, plus easier application deployment and management
Kubernetes 1.3: Bridging Cloud Native and Enterprise Workloads
Kubernetes 1.4: Making it easy to run on Kubernetes anywhere
Kubernetes 1.5: Supporting Production Workloads
Kubernetes 1.6: Multi-user, Multi-workloads at Scale
Kubernetes 1.7: Security Hardening, Stateful Application Updates and Extensibility

At least these blogs have wrong content-type 'application/octet-stream', for example:

$ curl -I -s https://kubernetes.io/blog/2016/03/kubernetes-1.2-even-more-performance-upgrades-plus-easier-application-deployment-and-management
HTTP/2 200 
accept-ranges: bytes
cache-control: public, max-age=0, must-revalidate
content-length: 82588
content-type: application/octet-stream
date: Tue, 22 Oct 2019 07:05:56 GMT
etag: "144be287c274dd3239fb5b59e6b1176d-ssl"
strict-transport-security: max-age=31536000
age: 1285
server: Netlify
x-nf-request-id: 17f57fd9-7088-4efc-abad-6fd6482f16cb-16811818

Proposed Solution:

Local hugo serve works, so I guess it's a misconfiguration on the server side.

Page to Update:

At lease these pages:

https://kubernetes.io/blog/2016/03/kubernetes-1.2-and-simplifying-advanced-networking-with-ingress/
https://kubernetes.io/blog/2016/03/kubernetes-1.2-even-more-performance-upgrades-plus-easier-application-deployment-and-management/
https://kubernetes.io/blog/2016/07/kubernetes-1.3-bridging-cloud-native-and-enterprise-workloads/
https://kubernetes.io/blog/2016/09/kubernetes-1.4-making-it-easy-to-run-on-kuberentes-anywhere/
https://kubernetes.io/blog/2016/12/kubernetes-1.5-supporting-production-workloads/
https://kubernetes.io/blog/2017/03/kubernetes-1.6-multi-user-multi-workloads-at-scale/
https://kubernetes.io/blog/2017/06/kubernetes-1.7-security-hardening-stateful-application-extensibility-updates/

good first issue help wanted kinbug prioritimportant-soon

All 4 comments

/kind bug
/priority important-soon
(I think)

I figured this one out after some poking around.

If the blog's front matter url: contains a period (usually from a k8s version), Netlify treats it as a file extension.

Example (broken): source

url: /blog/2016/03/Kubernetes-1.2-Even-More-Performance-Upgrades-Plus-Easier-Application-Deployment-And-Management

Will render as /blog/2016/03/Kubernetes-1.2-Even-More-Performance-Upgrades-Plus-Easier-Application-Deployment-And-Management making your browser think the page has a strange extension.

Example (working): source

url: /blog/2016/03/Kubernetes-In-Enterprise-With-Fujitsus

Will render as: /blog/2016/03/Kubernetes-In-Enterprise-With-Fujitsus/ (which loads the auto-generated blog index.html shortcode).

Solution:

  • Find all blog posts where the front matter contains a url with a period
  • Swap periods for dashes
  • Profit

/good-first-issue

@jimangel:
This request has been marked as suitable for new contributors.

Please ensure the request meets the requirements listed here.

If this request no longer meets these requirements, the label can be removed
by commenting with the /remove-good-first-issue command.

In response to this:

I figured this one out after some poking around.

If the blog's front matter url: contains a period (usually from a k8s version), Netlify treats it as a file extension.

Example (broken): source

url: /blog/2016/03/Kubernetes-1.2-Even-More-Performance-Upgrades-Plus-Easier-Application-Deployment-And-Management

Will render as /blog/2016/03/Kubernetes-1.2-Even-More-Performance-Upgrades-Plus-Easier-Application-Deployment-And-Management making your browser think the page has a strange extension.

Example (working): source

url: /blog/2016/03/Kubernetes-In-Enterprise-With-Fujitsus

Will render as: /blog/2016/03/Kubernetes-In-Enterprise-With-Fujitsus/ (which loads the auto-generated blog index.html shortcode).

Solution:

  • Find all blog posts where the front matter contains a url with a period
  • Swap periods for dashes
  • Profit

/good-first-issue

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

/assign @gocho1

Was this page helpful?
0 / 5 - 0 ratings