From a1ed698fa8a313535b34c4322b0d2f13f8955453 Mon Sep 17 00:00:00 2001 From: Soam Vasani Date: Thu, 15 Feb 2018 20:39:25 -0800 Subject: [PATCH] Go: Set image to right version, update example readme (#497) --- environments/go/README.md | 4 ++-- examples/go/README.md | 18 ++++++++++++------ examples/go/specs/env.yaml | 5 +++-- 3 files changed, 17 insertions(+), 10 deletions(-) diff --git a/environments/go/README.md b/environments/go/README.md index 42dbf939..e1c1069e 100644 --- a/environments/go/README.md +++ b/environments/go/README.md @@ -23,13 +23,13 @@ You can add this customized image to fission with "fission env create": ``` -fission env create --name go-runtime --image USER/go-runtime +fission env create --name go --image USER/go-runtime --builder USER/go-builder --version 2 ``` Or, if you already have an environment, you can update its image: ``` -fission env update --name go-runtime --image USER/go-runtime +fission env update --name go --image USER/go-runtime --builder USER/go-builder ``` After this, fission functions that have the env parameter set to the diff --git a/examples/go/README.md b/examples/go/README.md index 17bb1634..adcd3a51 100644 --- a/examples/go/README.md +++ b/examples/go/README.md @@ -1,17 +1,23 @@ # Hello World in Go on Fission -`hello.go` is an very simple fission function that says "Hello, World!". +`hello.go` contains a very simple fission function that says "Hello, World!". + +## Deploying this function on your cluster ```bash -# This command creates the environment and function, and waits for the -# function build. Look at the YAML files in specs/ for details about -# how those are specified. + +# Create the Fission Go environment and function, and wait for the +# function to build. (Take a look at the YAML files in the specs +# directory for details about how the environment and function are +# specified.) + $ fission spec apply --wait 1 environment created 1 package created 1 function created -# This run the function and prints its output -$ fission function test --name hello +# Now, run the function with the "fission function test" command: + +$ fission function test --name hello-go Hello, World! ``` diff --git a/examples/go/specs/env.yaml b/examples/go/specs/env.yaml index c2716724..19b46667 100644 --- a/examples/go/specs/env.yaml +++ b/examples/go/specs/env.yaml @@ -7,6 +7,7 @@ spec: version: 2 builder: command: build - image: fission/go-build-env:20171206-2 + image: fission/go-build-env:latest runtime: - image: fission/go-env:20171206 + image: fission/go-env:latest +