template

package
v0.8.0 Latest Latest
Warning

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

Go to latest
Published: Mar 19, 2018 License: Apache-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	DockerFNC = `FROM alpine:3.2
ADD {{.Alias}}-{{.Type}} /{{.Alias}}-{{.Type}}
ENTRYPOINT [ "/{{.Alias}}-{{.Type}}" ]
`

	DockerSRV = `FROM alpine:3.2
ADD {{.Alias}}-{{.Type}} /{{.Alias}}-{{.Type}}
ENTRYPOINT [ "/{{.Alias}}-{{.Type}}" ]
`

	DockerWEB = `` /* 127-byte string literal not displayed */

)
View Source
var (
	HandlerFNC = `` /* 328-byte string literal not displayed */

	HandlerSRV = `` /* 1288-byte string literal not displayed */

	SubscriberFNC = `` /* 267-byte string literal not displayed */

	SubscriberSRV = `` /* 394-byte string literal not displayed */

	HandlerAPI = `` /* 1143-byte string literal not displayed */

	HandlerWEB = `` /* 991-byte string literal not displayed */

)
View Source
var (
	MainFNC = `` /* 525-byte string literal not displayed */

	MainSRV = `` /* 732-byte string literal not displayed */

	MainAPI = `` /* 585-byte string literal not displayed */

	MainWEB = `` /* 684-byte string literal not displayed */

)
View Source
var (
	ProtoFNC = `` /* 217-byte string literal not displayed */

	ProtoSRV = `` /* 508-byte string literal not displayed */

	ProtoAPI = `` /* 166-byte string literal not displayed */

)
View Source
var (
	Readme = `# {{title .Alias}} {{title .Type}}

This is the {{title .Alias}} service with fqdn {{.FQDN}}.

## Getting Started

### Prerequisites

Install Consul
[https://www.consul.io/intro/getting-started/install.html](https://www.consul.io/intro/getting-started/install.html)

Run Consul
` + "```" +
		`
$ consul agent -dev -advertise=127.0.0.1
` + "```" +
		`

### Run Service

` + "```" +
		`
$ go run main.go
` + "```" +
		`

### Building a container

If you would like to build the docker container do the following
` + "```" +
		`
CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags '-w' -o {{.Alias}}-{{.Type}} ./main.go
docker build -t {{.Alias}}-{{.Type}} .

` + "```"

	ReadmeFNC = `# {{title .Alias}} {{title .Type}}

This is the {{title .Alias}} function with fqdn {{.FQDN}}.

## Getting Started

### Service Discovery

Install Consul
[https://www.consul.io/intro/getting-started/install.html](https://www.consul.io/intro/getting-started/install.html)

Run Consul
` + "```" +
		`
$ consul agent -dev
` + "```" +
		`
### Micro Toolkit

Install Micro

` + "```" +
		`
go get github.com/micro/micro
` + "```" +
		`

### Run Function

` + "```" +
		`
$ micro run -r {{.Dir}}
` + "```" +
		`

### Building a container

If you would like to build the docker container do the following
` + "```" +
		`
CGO_ENABLED=0 GOOS=linux go build -a -installsuffix cgo -ldflags '-w' -o {{.Alias}}-{{.Type}} ./main.go
docker build -t {{.Alias}}-{{.Type}} .

` + "```"
)
View Source
var (
	HTMLWEB = `` /* 2923-byte string literal not displayed */

)
View Source
var (
	WrapperAPI = `` /* 826-byte string literal not displayed */

)

Functions

This section is empty.

Types

This section is empty.

Jump to

Keyboard shortcuts

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