Frontend pipeline deployment breaks the website

This article describes a solution to the issue where frontend pipelines are not successfully applied to websites, even when deployment finishes successfully. Add ServerAlias to an enabled vhost to fix it.

Description description


AEM as a Cloud Service


Frontend pipelines are not successfully applied to websites. Although the deployment finishes successfully, the js/css files are not applied to the website.

Steps to reproduce

  1. Create a new site using the aem-site-template-standard version 2.2.0.
  2. Download sources from that site.
  3. Make some changes to the website theme.
  4. Push sources into the repo/branch.
  5. Run FE pipeline from that repo/branch.

After the FE pipeline is deployed, the new site breaks and no js/css is loaded.

In addition, you will see that at:

"/conf/fe-pipeline-test/sling:configs/com.adobe.cq.wcm.core.components.config.HtmlPageItemsConfig/jcr:content", the property "prefixPath" is set to:

"", which looks good.

But whatever resource we try to load from this server (like the css:, we always get “It works”.

Resolution resolution

Based on the fact that when styling loads from the static domain, it only returns “It works”, we need to verify whether the static domain is not blocked at the dispatcher level.

For FE pipelines to work, the deployed frontend artifacts need to be served correctly by CDN/dispatcher.

If the static domain is blocked by the dispatcher configuration, the css/js cannot be loaded.

For this, at least one of the enabled vhosts has either:

ServerAlias *
ServerAlias "static-p<progId>-e<envId>"

On checking the customer’s dispatcher configuration, it could be seen that only the deault.vhost has ServerAlias "*". However, the default.vhost was not enabled.

Adding ServerAlias to an enabled vhost fixed the issue.