Skip to content

Honor publisher origin Host header override in Fastly backends #786

@ChristianPavilonis

Description

@ChristianPavilonis

Problem

A test deployment that proxies to a publisher origin returns 404 Not Found even when publisher.origin_host_header_override is configured.

Direct origin checks show the upstream origin serves the page when the required Host header is present, but returns the same 404 shape when the backend host is used as Host. This indicates the configured override is not being applied at the Fastly backend layer.

Root cause

The publisher proxy computes and inserts the configured Host header on the outbound request, but the platform backend abstraction does not carry a host-header override into Fastly dynamic backend registration.

BackendConfig already supports host_header_override and uses it to call Fastly override_host, but the newer PlatformBackendSpec path does not expose or pass this value.

Expected behavior

When publisher.origin_host_header_override is configured:

  • publisher-origin dynamic backend registration uses the override Host value
  • Fastly sends the configured Host header to the origin
  • origins that route by Host return the expected content instead of backend-host 404s

Acceptance criteria

  • Add host-header override support to PlatformBackendSpec.
  • Pass publisher.origin_host_header_override when registering the publisher origin backend.
  • Wire the override into the Fastly platform backend implementation.
  • Keep non-publisher backend registrations unchanged by using no override.
  • Add/adjust tests covering override-aware backend naming.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions