Skip to content
This repository has been archived by the owner on Jan 30, 2024. It is now read-only.

Commit

Permalink
Remove static/a paths
Browse files Browse the repository at this point in the history
This analytics path has been removed from static [1] and is therefore no
longer used. The configuration for it can now be removed.

I'm a bit baffled by the modules/govuk/templates/node/s_backend_lb/assets-carrenza.conf.erb
file and whether it's still relevant, but it seems a big tangent to
investigate this over something so small.

[1]: alphagov/static#2152
  • Loading branch information
kevindew committed Jun 17, 2020
1 parent 13c4d9d commit c7fa82a
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 23 deletions.
14 changes: 3 additions & 11 deletions modules/govuk/templates/node/s_backend_lb/assets-carrenza.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -95,21 +95,13 @@ server {
}
<%- end -%>

<%- if scope.lookupvar('::aws_migration') %>
set $upstream_static <%= @upstream_ssl ? 'https' : 'http' %>://static.<%= @app_domain %>;
<%- end %>
location = /static/a {
<%- if scope.lookupvar('::aws_migration') %>
proxy_pass $upstream_static;
<%- else %>
proxy_pass <%= @upstream_ssl ? 'https' : 'http' %>://static.<%= @app_domain %>;
<%- end %>
}

location /__canary__ {
return 200;
}

<%- if scope.lookupvar('::aws_migration') %>
set $upstream_static <%= @upstream_ssl ? 'https' : 'http' %>://static.<%= @app_domain %>;
<%- end %>
location / {
<%- if scope.lookupvar('::aws_migration') %>
proxy_pass $upstream_static;
Expand Down
8 changes: 0 additions & 8 deletions modules/govuk/templates/static_extra_nginx_config.conf.erb
Original file line number Diff line number Diff line change
@@ -1,11 +1,3 @@
location = /static/a {
expires -1;
add_header Last-Modified "";

default_type text/plain;
return 200 '';
}

# 1stline use this URL in their zendesk template
location = /static/gov.uk_logotype_crown.png {
absolute_redirect off;
Expand Down
4 changes: 0 additions & 4 deletions modules/router/templates/assets_origin.conf.erb
Original file line number Diff line number Diff line change
Expand Up @@ -78,10 +78,6 @@ server {
<%- end -%>

set $upstream_static <%= @upstream_ssl ? 'https' : 'http' %>://static.<%= @app_domain %>;
location = /static/a {
proxy_pass $upstream_static;
}

location /__canary__ {
proxy_pass $upstream_static;
}
Expand Down

0 comments on commit c7fa82a

Please sign in to comment.