Sign inSign up

cnservices/microservices-demo-golang

By cnservices

Updated about 1 year ago

Microservices Demo - Golang

Image
0

2.5K

cnservices/microservices-demo-golang repository overview

Microservices Demo

Build

This is a Golang app that serves a web page showing the ID of the docker container in which it is running. To build this app, from the root of this repository just run:

docker build -t demo-go .

To create a container from that image, run:

docker run -p XXXX:8080 demo-go

You will be able to see the app going to:

localhost:XXXX
Rest API

The app contains three Rest API.

Index - Return the served site.

localhost:XXXX

Exit Successfully - Accessing this Rest API will make the container to exit successfully.

localhost:XXXX/exitSuccess

Exit With Error - Accessing this Rest API will make the container to exit with error.

localhost:XXXX/exitWithError

Tag summary

Content type

Image

Digest

sha256:f20043690

Size

7.9 MB

Last updated

about 1 year ago

docker pull cnservices/microservices-demo-golang