From c33d381e56c2fc9f8d9243d2d0de22d0cd1dca34 Mon Sep 17 00:00:00 2001 From: Alex Young Date: Mon, 18 Sep 2017 21:29:51 +0100 Subject: [PATCH] Update HACK.md Signed-off-by: Alex Young --- contrib/HACK.md | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) diff --git a/contrib/HACK.md b/contrib/HACK.md index 00fdb51b..de5fc5ec 100644 --- a/contrib/HACK.md +++ b/contrib/HACK.md @@ -9,7 +9,7 @@ $ ./build.sh Now edit the gateway service in your `docker-compose.yml` file and deploy the stack. -If you want to use an overriden name then pass in the tag to the `./build.sh` script such as `./build.sh test-1`. +If you want to use an overridden name then pass in the tag to the `./build.sh` script such as `./build.sh test-1`. ## Hack on the UI for the API Gateway @@ -22,14 +22,20 @@ $ docker stack rm func $ docker network create func_functions --driver=overlay --attachable=true ``` -Now edit the `docker-compose.yml` file and add an attribute to the `functions` network of `attachable`. +Now edit the `docker-compose.yml` file and replace the existing networks block with: + +``` +networks: + functions: + external: + name: func_functions +``` Now you can run the gateway as its own container and bind-mount in the HTML assets. ``` -$ cd faas $ docker run -v `pwd`/gateway/assets:/root/assets -v "/var/run/docker.sock:/var/run/docker.sock" \ --p 8080:8080 --network=func_functions -ti functions/gateway:latest-dev +-p 8080:8080 --network=func_functions -itd functions/gateway:latest-dev ``` -Now deploy the rest of the stack with: `./deploy_stack.sh`. +Now deploy the rest of the stack with: `./deploy_stack.sh`.