commit | 8ab2f455b8486300ab736bf9870767dc7e72ce31 | [log] [tgz] |
---|---|---|
author | Alex Fandrianto <alexfandrianto@google.com> | Thu Jan 29 15:30:30 2015 -0800 |
committer | Alex Fandrianto <alexfandrianto@google.com> | Thu Jan 29 15:31:11 2015 -0800 |
tree | 88a8d3741ae7de50aeb19d8aebe8f18abf8bbc4b | |
parent | 49bedfd65d5f0c03b4ad740756c233fffe2808d0 [diff] |
playground: guessJSValue, associated changes JS now requires that we describe the types being sent to and from the service if speaking to a non-JS client/server. Before, it was simply guessing what types it needed to send/receive. No server description is required for JS to JS communication. More types can be sent between JS servers and clients now, including ES6 Set/Map and structs with capitalized field names. NOTE: This CL is meant to show what's needed for the tests to pass. - I find the changes in this CL somewhat unsatisfactory. - I will need some help generating the JS vdl files. vom: https://vanadium-review.googlesource.com/#/c/2461/ veyron.js: https://vanadium-review.googlesource.com/#/c/2462/ viz: https://vanadium-review.googlesource.com/#/c/2511/ wsprd: https://vanadium-review.googlesource.com/2595 playground: https://vanadium-review.googlesource.com/#/c/2714/ MultiPart: 5/5 Change-Id: Iff996907600457b940cac91bfb235a5014bb596b
Install Docker:
On Goobuntu, we recommend overriding the default graph dir (/var/lib/docker
) to avoid filling up the root filesystem partition, which is quite small. To do so, add the following line to your /etc/default/docker
:
DOCKER_OPTS="${DOCKER_OPTS} -g /usr/local/google/docker"
Start (or restart) the Docker daemon:
$ sudo service docker restart
Build the playground Docker image (this will take a while...):
$ cp ~/.gitcookies $VANADIUM_ROOT/release/go/src/v.io/playground/builder/gitcookies $ cp ~/.hgrc $VANADIUM_ROOT/release/go/src/v.io/playground/builder/hgrc $ sudo docker build -t playground $VANADIUM_ROOT/release/go/src/v.io/playground/.
Note: If you want to ensure an up-to-date version of Vanadium is installed in the Docker image, run the above command with the “--no-cache” flag.
The ‘docker build’ command above will compile builder from the main Vanadium repository. If you want to use local code instead, open Dockerfile and uncomment marked lines before running the command.
Test your image (without running compilerd):
$ sudo docker run -i playground < /usr/local/google/home/sadovsky/dev/veyron-www/content/playgrounds/code/fortune/ex0-go/bundle.json
Install the playground binaries:
$ v23 go install v.io/playground/...
Run the compiler binary as root:
$ sudo $VANADIUM_ROOT/release/go/bin/compilerd --shutdown=false --address=localhost:8181
Or, run it without Docker (for faster iterations during development):
$ cd $(mktemp -d "/tmp/XXXXXXXX") $ PATH=$VANADIUM_ROOT/release/go/bin:$PATH compilerd --shutdown=false --address=localhost:8181 --use-docker=false
The server should now be running at http://localhost:8181 and responding to compile requests at http://localhost:8181/compile.
Add ?pgaddr=//localhost:8181
to any veyron-www page to make its embedded playgrounds talk to your server. Add ?debug=1
to see debug info from the builder.