Skip to content

genson1808/gen-core

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

27 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

gen-core

コアシステムはGolangで構築されており、APIサービス、ウェブサービスなどの開発に使用されます。

workflow (ワークフロー)

Docker

docker provides support for starting and stopping docker containers for running tests.

Docker は、テストを実行するための Docker コンテナの開始および停止をサポートしています。

container struct

// Container tracks information about the docker container started for tests.
type Container struct {
	ID   string
	Host string // IP:Port
}

Extract IP Port docker container with 'Format command and log output' of Docker using Go template

Go テンプレートを使用した Docker の「フォーマットコマンドとログ出力」で Docker コンテナの IP ポートを抽出する doc

tmpl := fmt.Sprintf("[{{range $k,$v := (index .NetworkSettings.Ports \"%s/tcp\")}}{{json $v}}{{end}}]", port)

cmd := exec.Command("docker", "inspect", "-f", tmpl, id)
var out bytes.Buffer
cmd.Stdout = &out
if err := cmd.Run(); err != nil {
	// handle err
}

Keystore (キーストア)

structure

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages