swanager

command module
v0.0.0-...-149ea5c Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 24, 2017 License: MIT Imports: 11 Imported by: 0

README

swanager

Development

Golang (1.7.5+) needs to be installed and set up

$ git clone git@github.com:dokkur/swanager.git && cd swanager
$ go get -u
$ go run swanager.go

Build

Simple:

./build.sh

Full:

TAG=latest DELETE_BUILD_IMAGE=0 GOLANG_BUILD_IMAGE=golang:1.8 ./build.sh

All params are optional.

Param Default value Description
TAG latest Tag of resulting image swanager:TAG
DELETE_BUILD_IMAGE 1 Whether of not, delete golang build image
GOLANG_BUILD_IMAGE golang:1.8 Golang build image

Run

Docker container
docker run -d -v /var/run/docker.sock:/var/run/docker.sock swanager

Required mounted resource is a docker socket to manage docker.

Configure swanager container:

Env vars Default value Description
SWANAGER_PORT 4945 API port
SWANAGER_LOG stdout Logfile
SWANAGER_MONGO_URL mongodb://127.0.0.1:27017/swanager mongodb url
SWANAGER_DB_NAME swanager Mongodb database name
SWANAGER_PATH_PREFIX /data Service mount points root
SWANAGER_LOCAL_SECRET_KEY - Secret key, to authenticate local services (if none, won't be authenticated)
Docker stack file

You may want to store mongodb to mounted volume, just check swanager.yml

Start

docker stack deploy --compose-file swanager.yml swanager

Stop

docker stack rm swanager

Documentation

The Go Gopher

There is no documentation for this package.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL