From 17c4fb81f41ba1412866c26781e3ac936f220848 Mon Sep 17 00:00:00 2001 From: Brad Fitzpatrick Date: Tue, 18 Oct 2011 11:12:53 -0700 Subject: [PATCH] Get the UI starting to work in App Engine. Change-Id: I6fc3420bb6e4d41595c3ef511bbdafa82ff51cf3 --- server/go/appengine/camli/appengine/main.go | 5 +++-- server/go/appengine/camli/client | 1 + server/go/appengine/camli/jsonsign | 1 + server/go/appengine/camli/misc/gpgagent | 1 + server/go/appengine/camli/misc/pinentry | 1 + server/go/appengine/camli/misc/resize | 1 + server/go/appengine/camli/rollsum | 1 + server/go/appengine/camli/schema | 1 + server/go/appengine/camli/search | 1 + server/go/appengine/camli/server | 1 + .../camlistore.org/server/uistatic/fileembed.go | 16 ++++++++++++++++ server/go/appengine/config.json | 1 - server/go/appengine/uistatic | 1 + 13 files changed, 29 insertions(+), 3 deletions(-) create mode 120000 server/go/appengine/camli/client create mode 120000 server/go/appengine/camli/jsonsign create mode 120000 server/go/appengine/camli/misc/gpgagent create mode 120000 server/go/appengine/camli/misc/pinentry create mode 120000 server/go/appengine/camli/misc/resize create mode 120000 server/go/appengine/camli/rollsum create mode 120000 server/go/appengine/camli/schema create mode 120000 server/go/appengine/camli/search create mode 120000 server/go/appengine/camli/server create mode 100644 server/go/appengine/camlistore.org/server/uistatic/fileembed.go create mode 120000 server/go/appengine/uistatic diff --git a/server/go/appengine/camli/appengine/main.go b/server/go/appengine/camli/appengine/main.go index 0e4b680ef..df957a65b 100644 --- a/server/go/appengine/camli/appengine/main.go +++ b/server/go/appengine/camli/appengine/main.go @@ -23,8 +23,9 @@ import ( "appengine" - "camli/blobserver" - "camli/serverconfig" + "camli/blobserver" // storage interface definition + "camli/serverconfig" // wiring up the world from a JSON description + _ "camli/server" // handlers: UI, publish, thumbnailing, etc ) // lazyInit is our root handler for App Engine. We don't have an App Engine diff --git a/server/go/appengine/camli/client b/server/go/appengine/camli/client new file mode 120000 index 000000000..fdb547eaa --- /dev/null +++ b/server/go/appengine/camli/client @@ -0,0 +1 @@ +../../../../lib/go/camli/client \ No newline at end of file diff --git a/server/go/appengine/camli/jsonsign b/server/go/appengine/camli/jsonsign new file mode 120000 index 000000000..b52bbdae2 --- /dev/null +++ b/server/go/appengine/camli/jsonsign @@ -0,0 +1 @@ +../../../../lib/go/camli/jsonsign/ \ No newline at end of file diff --git a/server/go/appengine/camli/misc/gpgagent b/server/go/appengine/camli/misc/gpgagent new file mode 120000 index 000000000..64c5ac675 --- /dev/null +++ b/server/go/appengine/camli/misc/gpgagent @@ -0,0 +1 @@ +../../../../../lib/go/camli/misc/gpgagent \ No newline at end of file diff --git a/server/go/appengine/camli/misc/pinentry b/server/go/appengine/camli/misc/pinentry new file mode 120000 index 000000000..1cb556b73 --- /dev/null +++ b/server/go/appengine/camli/misc/pinentry @@ -0,0 +1 @@ +../../../../../lib/go/camli/misc/pinentry \ No newline at end of file diff --git a/server/go/appengine/camli/misc/resize b/server/go/appengine/camli/misc/resize new file mode 120000 index 000000000..d1372ab32 --- /dev/null +++ b/server/go/appengine/camli/misc/resize @@ -0,0 +1 @@ +../../../../../lib/go/camli/misc/resize \ No newline at end of file diff --git a/server/go/appengine/camli/rollsum b/server/go/appengine/camli/rollsum new file mode 120000 index 000000000..006009be5 --- /dev/null +++ b/server/go/appengine/camli/rollsum @@ -0,0 +1 @@ +../../../../lib/go/camli/rollsum \ No newline at end of file diff --git a/server/go/appengine/camli/schema b/server/go/appengine/camli/schema new file mode 120000 index 000000000..277f76278 --- /dev/null +++ b/server/go/appengine/camli/schema @@ -0,0 +1 @@ +../../../../lib/go/camli/schema \ No newline at end of file diff --git a/server/go/appengine/camli/search b/server/go/appengine/camli/search new file mode 120000 index 000000000..d5371ed2f --- /dev/null +++ b/server/go/appengine/camli/search @@ -0,0 +1 @@ +../../../../lib/go/camli/search \ No newline at end of file diff --git a/server/go/appengine/camli/server b/server/go/appengine/camli/server new file mode 120000 index 000000000..a534ffe2e --- /dev/null +++ b/server/go/appengine/camli/server @@ -0,0 +1 @@ +../../../../lib/go/camli/server \ No newline at end of file diff --git a/server/go/appengine/camlistore.org/server/uistatic/fileembed.go b/server/go/appengine/camlistore.org/server/uistatic/fileembed.go new file mode 100644 index 000000000..e4c35a235 --- /dev/null +++ b/server/go/appengine/camlistore.org/server/uistatic/fileembed.go @@ -0,0 +1,16 @@ +package uistatic + +import ( + "camli/misc/fileembed" + + "appengine" +) + +var Files = &fileembed.Files{ + DirFallback: "uistatic", + + // In dev_appserver, allow edit-and-reload without + // restarting. In production, though, it's faster to just + // slurp it in. + SlurpToMemory: !appengine.IsDevAppServer(), +} diff --git a/server/go/appengine/config.json b/server/go/appengine/config.json index 56f56f682..b5ccad1ce 100644 --- a/server/go/appengine/config.json +++ b/server/go/appengine/config.json @@ -4,7 +4,6 @@ "prefixes": { "/ui/": { - "enabled": false, "_comment": "The UI handler isn't yet in its own package.", "handler": "ui", "handlerArgs": { "blobRoot": "/bs/" diff --git a/server/go/appengine/uistatic b/server/go/appengine/uistatic new file mode 120000 index 000000000..deb446734 --- /dev/null +++ b/server/go/appengine/uistatic @@ -0,0 +1 @@ +../../../server/go/camlistored/ui/ \ No newline at end of file