mirror of
https://github.com/google/nomulus.git
synced 2025-05-13 07:57:13 +02:00
Remove most HTML/CSS/JS assets from the backend service WAR
It only needs the error page HTML files; everything else isn't used by endpoints served by the backend service and only serves to increase build times (especially compiling all that JS). ------------- Created by MOE: https://github.com/google/moe MOE_MIGRATED_REVID=202229514
This commit is contained in:
parent
892c1fc707
commit
fb9d876bff
7 changed files with 17 additions and 22 deletions
|
@ -133,7 +133,7 @@ zip_file(
|
||||||
},
|
},
|
||||||
deps = [
|
deps = [
|
||||||
":common_war",
|
":common_war",
|
||||||
"//java/google/registry/ui:war",
|
"//java/google/registry/ui:minimal_war",
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -22,8 +22,5 @@
|
||||||
|
|
||||||
<static-files>
|
<static-files>
|
||||||
<include path="/*.html" expiration="1m"/>
|
<include path="/*.html" expiration="1m"/>
|
||||||
<include path="/assets/js/**" expiration="1m"/>
|
|
||||||
<include path="/assets/css/**" expiration="1m"/>
|
|
||||||
<include path="/assets/images/**" expiration="1m"/>
|
|
||||||
</static-files>
|
</static-files>
|
||||||
</appengine-web-app>
|
</appengine-web-app>
|
||||||
|
|
|
@ -22,8 +22,5 @@
|
||||||
|
|
||||||
<static-files>
|
<static-files>
|
||||||
<include path="/*.html" expiration="1m"/>
|
<include path="/*.html" expiration="1m"/>
|
||||||
<include path="/assets/js/**" expiration="1m"/>
|
|
||||||
<include path="/assets/css/**" expiration="1m"/>
|
|
||||||
<include path="/assets/images/**" expiration="1m"/>
|
|
||||||
</static-files>
|
</static-files>
|
||||||
</appengine-web-app>
|
</appengine-web-app>
|
||||||
|
|
|
@ -26,14 +26,5 @@
|
||||||
<include path="/*.html">
|
<include path="/*.html">
|
||||||
<http-header name="Cache-Control" value="max-age=0,must-revalidate" />
|
<http-header name="Cache-Control" value="max-age=0,must-revalidate" />
|
||||||
</include>
|
</include>
|
||||||
<include path="/assets/js/**">
|
|
||||||
<http-header name="Cache-Control" value="max-age=0,must-revalidate" />
|
|
||||||
</include>
|
|
||||||
<include path="/assets/css/**">
|
|
||||||
<http-header name="Cache-Control" value="max-age=0,must-revalidate" />
|
|
||||||
</include>
|
|
||||||
<include path="/assets/images/**">
|
|
||||||
<http-header name="Cache-Control" value="max-age=0,must-revalidate" />
|
|
||||||
</include>
|
|
||||||
</static-files>
|
</static-files>
|
||||||
</appengine-web-app>
|
</appengine-web-app>
|
||||||
|
|
|
@ -22,9 +22,6 @@
|
||||||
|
|
||||||
<static-files>
|
<static-files>
|
||||||
<include path="/*.html" expiration="1d"/>
|
<include path="/*.html" expiration="1d"/>
|
||||||
<include path="/assets/js/**" expiration="1d"/>
|
|
||||||
<include path="/assets/css/**" expiration="1d"/>
|
|
||||||
<include path="/assets/images/**" expiration="1d"/>
|
|
||||||
</static-files>
|
</static-files>
|
||||||
|
|
||||||
<!-- Prevent uncaught servlet errors from leaking a stack trace. -->
|
<!-- Prevent uncaught servlet errors from leaking a stack trace. -->
|
||||||
|
|
|
@ -22,9 +22,6 @@
|
||||||
|
|
||||||
<static-files>
|
<static-files>
|
||||||
<include path="/*.html" expiration="1d"/>
|
<include path="/*.html" expiration="1d"/>
|
||||||
<include path="/assets/js/**" expiration="1d"/>
|
|
||||||
<include path="/assets/css/**" expiration="1d"/>
|
|
||||||
<include path="/assets/images/**" expiration="1d"/>
|
|
||||||
</static-files>
|
</static-files>
|
||||||
|
|
||||||
<!-- Prevent uncaught servlet errors from leaking a stack trace. -->
|
<!-- Prevent uncaught servlet errors from leaking a stack trace. -->
|
||||||
|
|
|
@ -17,6 +17,13 @@ filegroup(
|
||||||
],
|
],
|
||||||
)
|
)
|
||||||
|
|
||||||
|
filegroup(
|
||||||
|
name = "minimal_runfiles",
|
||||||
|
srcs = [
|
||||||
|
"//java/google/registry/ui/html:html_files",
|
||||||
|
],
|
||||||
|
)
|
||||||
|
|
||||||
filegroup(
|
filegroup(
|
||||||
name = "runfiles_debug",
|
name = "runfiles_debug",
|
||||||
srcs = [
|
srcs = [
|
||||||
|
@ -41,6 +48,15 @@ zip_file(
|
||||||
},
|
},
|
||||||
)
|
)
|
||||||
|
|
||||||
|
zip_file(
|
||||||
|
name = "minimal_war",
|
||||||
|
srcs = [":minimal_runfiles"],
|
||||||
|
out = "minimal_ui.war",
|
||||||
|
mappings = {
|
||||||
|
"domain_registry/java/google/registry/ui/html": "",
|
||||||
|
},
|
||||||
|
)
|
||||||
|
|
||||||
zip_file(
|
zip_file(
|
||||||
name = "war_debug",
|
name = "war_debug",
|
||||||
srcs = [":runfiles_debug"],
|
srcs = [":runfiles_debug"],
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue