Embed bootstrap, jquery and other external dependencies to allow cAdvisor to function without a connection to the Internet per issue #304.
This commit is contained in:
parent
a4e25f056b
commit
b4e1dbb4f9
@ -19,17 +19,17 @@ const containersHtmlTemplate = `
|
|||||||
<head>
|
<head>
|
||||||
<title>cAdvisor - {{.DisplayName}}</title>
|
<title>cAdvisor - {{.DisplayName}}</title>
|
||||||
<!-- Latest compiled and minified CSS -->
|
<!-- Latest compiled and minified CSS -->
|
||||||
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap.min.css">
|
<link rel="stylesheet" href="/static/bootstrap.min.css">
|
||||||
|
|
||||||
<!-- Optional theme -->
|
<!-- Optional theme -->
|
||||||
<link rel="stylesheet" href="//netdna.bootstrapcdn.com/bootstrap/3.1.1/css/bootstrap-theme.min.css">
|
<link rel="stylesheet" href="/static/bootstrap-theme.min.css">
|
||||||
|
|
||||||
<link rel="stylesheet" href="/static/containers.css">
|
<link rel="stylesheet" href="/static/containers.css">
|
||||||
|
|
||||||
<!-- Latest compiled and minified JavaScript -->
|
<!-- Latest compiled and minified JavaScript -->
|
||||||
<script src="//ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js"></script>
|
<script src="/static/jquery.min.js"></script>
|
||||||
<script src="//netdna.bootstrapcdn.com/bootstrap/3.1.1/js/bootstrap.min.js"></script>
|
<script src="/static/bootstrap.min.js"></script>
|
||||||
<script type="text/javascript" src="https://www.google.com/jsapi"></script>
|
<script type="text/javascript" src="/static/google-jsapi.js"></script>
|
||||||
|
|
||||||
<script type="text/javascript" src="/static/containers.js"></script>
|
<script type="text/javascript" src="/static/containers.js"></script>
|
||||||
</head>
|
</head>
|
||||||
|
25
pages/static/bootstrap_min_css.go
Normal file
25
pages/static/bootstrap_min_css.go
Normal file
File diff suppressed because one or more lines are too long
24
pages/static/bootstrap_min_js.go
Normal file
24
pages/static/bootstrap_min_js.go
Normal file
File diff suppressed because one or more lines are too long
25
pages/static/bootstrap_theme_min_css.go
Normal file
25
pages/static/bootstrap_theme_min_css.go
Normal file
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because it is too large
Load Diff
57
pages/static/google_jsapi_js.go
Normal file
57
pages/static/google_jsapi_js.go
Normal file
File diff suppressed because one or more lines are too long
24
pages/static/jquery_min_js.go
Normal file
24
pages/static/jquery_min_js.go
Normal file
File diff suppressed because one or more lines are too long
@ -27,6 +27,11 @@ const StaticResource = "/static/"
|
|||||||
var staticFiles = map[string]string{
|
var staticFiles = map[string]string{
|
||||||
"containers.css": containersCss,
|
"containers.css": containersCss,
|
||||||
"containers.js": containersJs,
|
"containers.js": containersJs,
|
||||||
|
"bootstrap.min.css": bootstrapCss,
|
||||||
|
"bootstrap-theme.min.css": bootstrapThemeCss,
|
||||||
|
"jquery.min.js": jqueryJs,
|
||||||
|
"bootstrap.min.js": bootstrapJs,
|
||||||
|
"google-jsapi.js": googleJsapiJs,
|
||||||
}
|
}
|
||||||
|
|
||||||
func HandleRequest(w http.ResponseWriter, u *url.URL) error {
|
func HandleRequest(w http.ResponseWriter, u *url.URL) error {
|
||||||
|
Loading…
Reference in New Issue
Block a user