[ARVADOS] updated: 089aa29a1b16b833a30e8384900e6b6ccc55fb4f

Git user git at public.curoverse.com
Fri Sep 16 13:11:13 EDT 2016


Summary of changes:
 .../keep-web.service}                                      |  4 ++--
 services/keep-web/main.go                                  | 14 ++++++++++++--
 2 files changed, 14 insertions(+), 4 deletions(-)
 copy services/{crunch-dispatch-slurm/crunch-dispatch-slurm.service => keep-web/keep-web.service} (61%)

       via  089aa29a1b16b833a30e8384900e6b6ccc55fb4f (commit)
      from  3f19bd3d240272fb0c9e7e207df926fc659335ac (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 089aa29a1b16b833a30e8384900e6b6ccc55fb4f
Author: Tom Clegg <tom at curoverse.com>
Date:   Fri Sep 16 13:10:17 2016 -0400

    9957: Add systemd unit file for keep-web.

diff --git a/services/keep-web/keep-web.service b/services/keep-web/keep-web.service
new file mode 100644
index 0000000..da56212
--- /dev/null
+++ b/services/keep-web/keep-web.service
@@ -0,0 +1,12 @@
+[Unit]
+Description=Arvados Keep web gateway
+Documentation=https://doc.arvados.org/
+After=network.target
+
+[Service]
+Type=notify
+ExecStart=/usr/bin/keep-web
+Restart=always
+
+[Install]
+WantedBy=multi-user.target
diff --git a/services/keep-web/main.go b/services/keep-web/main.go
index 3bb6a85..dd949d8 100644
--- a/services/keep-web/main.go
+++ b/services/keep-web/main.go
@@ -7,6 +7,7 @@ import (
 
 	"git.curoverse.com/arvados.git/sdk/go/arvados"
 	"git.curoverse.com/arvados.git/sdk/go/configfile"
+	"github.com/coreos/go-systemd/daemon"
 )
 
 var (
@@ -52,12 +53,18 @@ func main() {
 	cfg := &Config{}
 
 	var configPath string
+	deprecated := " (DEPRECATED -- use config file instead)"
 	flag.StringVar(&configPath, "config", defaultConfigPath,
 		"`path` to json configuration file")
 	flag.StringVar(&cfg.Listen, "listen", "",
-		"address:port or :port to listen on (DEPRECATED -- use config file instead)")
+		"address:port or :port to listen on"+deprecated)
 	flag.BoolVar(&cfg.deprecatedAllowAnonymous, "allow-anonymous", false,
-		"DEPRECATED (use config file instead). Serve public data to anonymous clients. Try the token supplied in the ARVADOS_API_TOKEN environment variable when none of the tokens provided in an HTTP request succeed in reading the desired collection.")
+		"Load an anonymous token from the ARVADOS_API_TOKEN environment variable"+deprecated)
+	flag.StringVar(&cfg.AttachmentOnlyHost, "attachment-only-host", "",
+		"Only serve attachments at the given `host:port`"+deprecated)
+	flag.BoolVar(&cfg.TrustAllContent, "trust-all-content", false,
+		"Serve non-public content from a single origin. Dangerous: read docs before using!"+deprecated)
+	flag.Usage = usage
 	flag.Parse()
 
 	if err := configfile.LoadFile(cfg, configPath); err != nil {
@@ -75,6 +82,9 @@ func main() {
 	if err := srv.Start(); err != nil {
 		log.Fatal(err)
 	}
+	if _, err := daemon.SdNotify("READY=1"); err != nil {
+		log.Printf("Error notifying init daemon: %v", err)
+	}
 	log.Println("Listening at", srv.Addr)
 	if err := srv.Wait(); err != nil {
 		log.Fatal(err)

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list