Skip to content
This repository has been archived by the owner on Feb 5, 2021. It is now read-only.

Commit

Permalink
Update artifact versions for release v0.4.0
Browse files Browse the repository at this point in the history
  • Loading branch information
wso2-jenkins-bot committed Oct 5, 2019
1 parent 6818225 commit 91e3e52
Show file tree
Hide file tree
Showing 24 changed files with 290 additions and 290 deletions.
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,9 @@
PROJECT_ROOT := $(realpath $(dir $(abspath $(lastword $(MAKEFILE_LIST)))))
GIT_REVISION := $(shell git rev-parse --verify HEAD)
DOCKER_REPO ?= wso2cellery
DOCKER_IMAGE_TAG ?= latest-dev
DOCKER_IMAGE_TAG ?= 0.4.0
CELLERY_ORG ?= wso2cellery
CELLERY_VERSION ?= latest-dev
CELLERY_VERSION ?= 0.4.0

SRC_DIR := src
CELLS_DIR := cells
Expand Down
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,16 +1,16 @@
Cellery Samples
===============

[![Travis CI](https://travis-ci.org/wso2-cellery/samples.svg?branch=master)](https://travis-ci.org/wso2-cellery/samples)
[![Travis CI](https://travis-ci.org/wso2-cellery/samples.svg?branch=v0.4.0)](https://travis-ci.org/wso2-cellery/samples)
[![GitHub (pre-)release](https://img.shields.io/github/release/wso2-cellery/samples/all.svg)](https://github.com/wso2-cellery/samples/releases)
[![GitHub (Pre-)Release Date](https://img.shields.io/github/release-date-pre/wso2-cellery/samples.svg)](https://github.com/wso2-cellery/samples/releases)
[![GitHub last commit](https://img.shields.io/github/last-commit/wso2-cellery/samples.svg)](https://github.com/wso2-cellery/samples/commits/master)
[![GitHub last commit](https://img.shields.io/github/last-commit/wso2-cellery/samples.svg)](https://github.com/wso2-cellery/samples/commits/v0.4.0)
[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)

Cellery Samples contains various samples that can be deployed in a Cellery Runtime.

- To quick start on cellery, please go through the [Quick Start Guide](https://github.com/wso2-cellery/sdk/tree/master#quickstart-guide)
- For installation options, please visit the [Installation Guide](https://github.com/wso2-cellery/sdk/blob/master/docs/installation-options.md)
- To quick start on cellery, please go through the [Quick Start Guide](https://github.com/wso2-cellery/sdk/tree/v0.4.0#quickstart-guide)
- For installation options, please visit the [Installation Guide](https://github.com/wso2-cellery/sdk/blob/v0.4.0/docs/installation-options.md)
- For more information about Cellery, please visit [https://wso2-cellery.github.io/](https://wso2-cellery.github.io/)

Once you have completed cellery setup, you can proceed with deploying the samples provided below. You can find the following samples in this repository.
Expand Down
2 changes: 1 addition & 1 deletion cells/hello-world-api/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
PROJECT_ROOT := $(realpath $(dir $(abspath $(lastword $(MAKEFILE_LIST)))))
GIT_REVISION := $(shell git rev-parse --verify HEAD)
CELLERY_ORG ?= wso2cellery
CELLERY_VERSION ?= latest
CELLERY_VERSION ?= 0.4.0

SAMPLE := hello-world-api
CELL := hello-world-api
Expand Down
24 changes: 12 additions & 12 deletions cells/hello-world-api/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public function build(cellery:ImageName iName) returns error? {
cellery:Component helloComponent = {
name: "hello-api",
source: {
image: "docker.io/wso2cellery/samples-hello-world-api-hello-service:latest"
image: "docker.io/wso2cellery/samples-hello-world-api-hello-service:0.4.0"
},
ingresses: {
ingress: <cellery:HttpApiIngress>{ port: 9090,
Expand Down Expand Up @@ -63,37 +63,37 @@ public function build(cellery:ImageName iName) returns error? {

1. Build the cellery image for hello world project by executing the cellery build command as shown below. Note `CELLERY_HUB_ORG` is your organization name in [cellery hub](https://hub.cellery.io/).
```
$ cellery build hello-world-api.bal <CELLERY_HUB_ORG>/hello-world-api-cell:latest
$ cellery build hello-world-api.bal <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0
✔ Building image <CELLERY_HUB_ORG>/hello-world-api-cell:latest
✔ Building image <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0
✔ Saving new Image to the Local Repository
✔ Successfully built cell image: <CELLERY_HUB_ORG>/hello-world-api-cell:latest
✔ Successfully built cell image: <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0
What's next?
--------------------------------------------------------
Execute the following command to run the image:
$ cellery run <CELLERY_HUB_ORG>/helloworld:latest
$ cellery run <CELLERY_HUB_ORG>/helloworld:0.4.0
--------------------------------------------------------
```

2. Run the cell image by executing `cellery run` command as shown below.
```
$ cellery run <CELLERY_HUB_ORG>/hello-world-api-cell:latest -n hello-world-api-cell
✔ Extracting Cell Image <CELLERY_HUB_ORG/hello-world-api-cell:latest
$ cellery run <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0 -n hello-world-api-cell
✔ Extracting Cell Image <CELLERY_HUB_ORG/hello-world-api-cell:0.4.0
Main Instance: my-hello-world
✔ Reading Cell Image <CELLERY_HUB_ORG/hello-world-api-cell:latest
✔ Reading Cell Image <CELLERY_HUB_ORG/hello-world-api-cell:0.4.0
✔ Validating environment variables
✔ Validating dependencies
Instances to be Used:
INSTANCE NAME CELL IMAGE USED INSTANCE SHARED
---------------------- --------------------------------------------- --------------- --------
hello-world-api-cell <CELLERY_HUB_ORG>/hello-world-api-cell:latest To be Created -
hello-world-api-cell <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0 To be Created -
Dependency Tree to be Used:
Expand All @@ -104,7 +104,7 @@ public function build(cellery:ImageName iName) returns error? {
✔ Starting main instance my-hello-world
✔ Successfully deployed cell image: <CELLERY_HUB_ORG>/hello-world-api-cell:latest
✔ Successfully deployed cell image: <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0
What's next?
--------------------------------------------------------
Expand All @@ -118,11 +118,11 @@ public function build(cellery:ImageName iName) returns error? {
$ cellery list instances
INSTANCE CELL IMAGE STATUS GATEWAY COMPONENTS AGE
------------------------------------------ -------------------------------------------- -------- ----------------------------------------------------------------- ------------ ----------------------
hello-world-api-cell sinthuja/hello-world-api-cell:latest Ready sinthuja-hello-world-api-cell-latest-676b2131--gateway-service 1 10 minutes 1 seconds
hello-world-api-cell sinthuja/hello-world-api-cell:0.4.0 Ready sinthuja-hello-world-api-cell-0.4.0-676b2131--gateway-service 1 10 minutes 1 seconds
```
4. Execute `cellery view` to see the components of your cell. This will open a HTML page in a browser and you can visualize the components and dependent cells of the cell image.
```
$ cellery view <CELLERY_HUB_ORG>/hello-world-api-cell:latest
$ cellery view <CELLERY_HUB_ORG>/hello-world-api-cell:0.4.0
```
![hello world api cell view](../../docs/images/hello-world-api/hello-world-cell-api-docs-view.png)

Expand Down
2 changes: 1 addition & 1 deletion cells/hello-world/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
PROJECT_ROOT := $(realpath $(dir $(abspath $(lastword $(MAKEFILE_LIST)))))
GIT_REVISION := $(shell git rev-parse --verify HEAD)
CELLERY_ORG ?= wso2cellery
CELLERY_VERSION ?= latest
CELLERY_VERSION ?= 0.4.0

SAMPLE := hello-world
CELL := hello-world
Expand Down
38 changes: 19 additions & 19 deletions cells/hello-world/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ Now let's look at the steps required to try this hello-world cell.
### 2. Build, run and push hello world cell
In this section let's focus on build, run and push a [hello-world cell](hello-world.bal).

The `helloCell` contains one component `hello`. The hello component is defined by a container image `wso2cellery/samples-hello-world-webapp:latest`
The `helloCell` contains one component `hello`. The hello component is defined by a container image `wso2cellery/samples-hello-world-webapp:0.4.0`
which is written in Node.js and it is a simple webapp. This component has a web ingress with default vhost `hello-world.com`.
An input variable `HELLO_NAME` is expected by the hello component with default value `Cellery` to render the webpage.
These input parameters can be supplied when starting up the cell to modify the runtime behaviour.
Expand All @@ -35,7 +35,7 @@ public function build(cellery:ImageName iName) returns error? {
cellery:Component helloComponent = {
name: "hello",
source: {
image: "wso2cellery/samples-hello-world-webapp:latest-dev"
image: "wso2cellery/samples-hello-world-webapp:0.4.0"
},
ingresses: {
webUI: <cellery:WebIngress>{ // Web ingress will be always exposed globally.
Expand Down Expand Up @@ -81,40 +81,40 @@ Follow below instructions to build, run and push the hello world cell.

1. Build the cell image for hello-world project by executing the `cellery build` command as shown below. Note `CELLERY_HUB_ORG` is your organization name in [cellery hub](https://hub.cellery.io/).
```
$ cellery build hello-world.bal <CELLERY_HUB_ORG>/hello-world-cell:latest
$ cellery build hello-world.bal <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
Hello World Cell Built successfully.
✔ Building image <CELLERY_HUB_ORG>/hello-world-cell:latest
✔ Building image <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
✔ Saving new Image to the Local Repository
✔ Successfully built cell image: <CELLERY_HUB_ORG>/hello-world-cell:latest
✔ Successfully built cell image: <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
What's next?
--------------------------------------------------------
Execute the following command to run the image:
$ cellery run <CELLERY_HUB_ORG>/helloworld:latest
$ cellery run <CELLERY_HUB_ORG>/helloworld:0.4.0
--------------------------------------------------------
```

2. As mentioned above in the [hello-world.bal](hello-world.bal), `VHOST_NAME` and `HELLO_NAME` are used as input parameters to the `hello` component.
Therefore, run the hello-world cell image with ‘cellery run’ command with input parameters `my-hello-world.com` for `VHOST_NAME`, and your name for `HELLO_NAME`
as shown below to change the hello-world cell's default behaviour.
```
$ cellery run <CELLERY_HUB_ORG/hello-world-cell:latest -e VHOST_NAME=my-hello-world.com -e HELLO_NAME=WSO2 -n my-hello-world
✔ Extracting Cell Image <CELLERY_HUB_ORG/hello-world-cell:latest
$ cellery run <CELLERY_HUB_ORG/hello-world-cell:0.4.0 -e VHOST_NAME=my-hello-world.com -e HELLO_NAME=WSO2 -n my-hello-world
✔ Extracting Cell Image <CELLERY_HUB_ORG/hello-world-cell:0.4.0

Main Instance: my-hello-world

✔ Reading Cell Image <CELLERY_HUB_ORG/hello-world-cell:latest
✔ Reading Cell Image <CELLERY_HUB_ORG/hello-world-cell:0.4.0
✔ Validating environment variables
✔ Validating dependencies

Instances to be Used:

INSTANCE NAME CELL IMAGE USED INSTANCE SHARED
---------------- ------------------------------------------- --------------- --------
my-hello-world <CELLERY_HUB_ORG>/hello-world-cell:latest To be Created -
my-hello-world <CELLERY_HUB_ORG>/hello-world-cell:0.4.0 To be Created -

Dependency Tree to be Used:

Expand All @@ -125,7 +125,7 @@ as shown below to change the hello-world cell's default behaviour.
✔ Starting main instance my-hello-world


✔ Successfully deployed cell image: <CELLERY_HUB_ORG>/hello-world-cell:latest
✔ Successfully deployed cell image: <CELLERY_HUB_ORG>/hello-world-cell:0.4.0

What's next?
--------------------------------------------------------
Expand All @@ -139,11 +139,11 @@ as shown below to change the hello-world cell's default behaviour.
$ cellery list instances
INSTANCE CELL IMAGE STATUS GATEWAY COMPONENTS AGE
------------------------------------------ -------------------------------------------- -------- ----------------------------------------------------------- ------------ ----------------------
hello-world-cell-1-0-0-676b2131 <CELLERY_HUB_ORG>/hello-world-cell:latest Ready hello-world-cell-1-0-0-676b2131--gateway-service 1 10 minutes 1 seconds
hello-world-cell-1-0-0-676b2131 <CELLERY_HUB_ORG>/hello-world-cell:0.4.0 Ready hello-world-cell-1-0-0-676b2131--gateway-service 1 10 minutes 1 seconds
```
4. Execute `cellery view` to see the components of the cell. This will open a webpage in a browser that allows to visualize the components and dependent cells of the cell image.
```
$ cellery view <CELLERY_HUB_ORG>/hello-world-cell:latest
$ cellery view <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
```
![hello world cell view](../../docs/images/hello-world/hello-web-cell.png)

Expand All @@ -153,20 +153,20 @@ Make sure you have configured the host entries correctly as mentioned in [local]

6. As a final step, let's push your first cell project to your [cellery hub](https://hub.cellery.io/) account as shown below.
```
$ cellery push <CELLERY_HUB_ORG>/hello-world-cell:latest
$ cellery push <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
✔ Connecting to registry-1.docker.io
✔ Reading image <CELLERY_HUB_ORG>/hello-world-cell:latest from the Local Repository
✔ Checking if the image <CELLERY_HUB_ORG>/hello-world-cell:latest already exists in the Registry
✔ Pushing image <CELLERY_HUB_ORG>/hello-world-cell:latest
✔ Reading image <CELLERY_HUB_ORG>/hello-world-cell:0.4.0 from the Local Repository
✔ Checking if the image <CELLERY_HUB_ORG>/hello-world-cell:0.4.0 already exists in the Registry
✔ Pushing image <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
Image Digest : sha256:8935b3495a6c1cbc466ac28f4120c3836894e8ea1563fb5da7ecbd17e4b80df5
✔ Successfully pushed cell image: <CELLERY_HUB_ORG>/hello-world-cell:latest
✔ Successfully pushed cell image: <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
What's next?
--------------------------------------------------------
Execute the following command to pull the image:
$ cellery pull <CELLERY_HUB_ORG>/hello-world-cell:latest
$ cellery pull <CELLERY_HUB_ORG>/hello-world-cell:0.4.0
--------------------------------------------------------
```
Congratulations! You have successfully created your own cell!
Expand Down
2 changes: 1 addition & 1 deletion cells/hello-world/hello-world.bal
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ public function build(cellery:ImageName iName) returns error? {
cellery:Component helloComponent = {
name: "hello",
source: {
image: "wso2cellery/samples-hello-world-webapp:latest-dev"
image: "wso2cellery/samples-hello-world-webapp:0.4.0"
},
ingresses: {
webUI: <cellery:WebIngress>{ // Web ingress will be always exposed globally.
Expand Down
Loading

0 comments on commit 91e3e52

Please sign in to comment.