diff options
Diffstat (limited to 'website/cmd')
-rw-r--r-- | website/cmd/generate-syscall-docs/BUILD | 9 | ||||
-rw-r--r-- | website/cmd/generate-syscall-docs/main.go | 3 | ||||
-rw-r--r-- | website/cmd/server/BUILD | 10 | ||||
-rw-r--r-- | website/cmd/server/main.go (renamed from website/cmd/gvisor-website/main.go) | 10 |
4 files changed, 25 insertions, 7 deletions
diff --git a/website/cmd/generate-syscall-docs/BUILD b/website/cmd/generate-syscall-docs/BUILD new file mode 100644 index 000000000..40d13e5c8 --- /dev/null +++ b/website/cmd/generate-syscall-docs/BUILD @@ -0,0 +1,9 @@ +load("//tools:defs.bzl", "go_binary") + +package(licenses = ["notice"]) + +go_binary( + name = "generate-syscall-docs", + srcs = ["main.go"], + visibility = ["//website:__pkg__"], +) diff --git a/website/cmd/generate-syscall-docs/main.go b/website/cmd/generate-syscall-docs/main.go index d0faed128..9ca1b9730 100644 --- a/website/cmd/generate-syscall-docs/main.go +++ b/website/cmd/generate-syscall-docs/main.go @@ -1,4 +1,4 @@ -// Copyright 2019 Google LLC +// Copyright 2019 The gVisor Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -50,7 +50,6 @@ layout: docs category: Compatibility weight: 50 permalink: /docs/user_guide/compatibility/{{.OS}}/{{.Arch}}/ -noedit: true --- This table is a reference of {{.OS}} syscalls for the {{.Arch}} architecture and diff --git a/website/cmd/server/BUILD b/website/cmd/server/BUILD new file mode 100644 index 000000000..6b5a08f0d --- /dev/null +++ b/website/cmd/server/BUILD @@ -0,0 +1,10 @@ +load("//tools:defs.bzl", "go_binary") + +package(licenses = ["notice"]) + +go_binary( + name = "server", + srcs = ["main.go"], + pure = True, + visibility = ["//website:__pkg__"], +) diff --git a/website/cmd/gvisor-website/main.go b/website/cmd/server/main.go index d86d7c735..18cd525d2 100644 --- a/website/cmd/gvisor-website/main.go +++ b/website/cmd/server/main.go @@ -1,4 +1,4 @@ -// Copyright 2019 Google LLC +// Copyright 2019 The gVisor Authors // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. @@ -25,20 +25,20 @@ import ( ) var redirects = map[string]string{ - // Github redirects + // GitHub redirects. "/change": "https://github.com/google/gvisor", "/issue": "https://github.com/google/gvisor/issues", "/issue/new": "https://github.com/google/gvisor/issues/new", "/pr": "https://github.com/google/gvisor/pulls", - // For links + // For links. "/faq": "/docs/user_guide/faq/", // Redirects to compatibility docs. "/c": "/docs/user_guide/compatibility/", "/c/linux/amd64": "/docs/user_guide/compatibility/linux/amd64/", - // Redirect for old urls + // Redirect for old URLs. "/docs/user_guide/compatibility/amd64/": "/docs/user_guide/compatibility/linux/amd64/", "/docs/user_guide/compatibility/amd64": "/docs/user_guide/compatibility/linux/amd64/", "/docs/user_guide/kubernetes/": "/docs/user_guide/quick_start/kubernetes/", @@ -191,7 +191,7 @@ func envFlagString(name, def string) string { } var ( - addr = flag.String("http", envFlagString("HTTP", ":8080"), "HTTP service address") + addr = flag.String("http", envFlagString("HTTP", ":"+envFlagString("PORT", "8080")), "HTTP service address") staticDir = flag.String("static-dir", envFlagString("STATIC_DIR", "_site"), "static files directory") // Uses the standard GOOGLE_CLOUD_PROJECT environment variable set by App Engine. |