Skip to content
This repository was archived by the owner on Jan 21, 2020. It is now read-only.

Commit 64defd0

Browse files
author
David Chung
authored
script to install infrakit; small CLI layout change (#536)
Signed-off-by: David Chung <david.chung@docker.com>
1 parent a674126 commit 64defd0

2 files changed

Lines changed: 28 additions & 2 deletions

File tree

cmd/infrakit/plugin/plugin.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,15 +122,15 @@ func Command(plugins func() discovery.Plugins) *cobra.Command {
122122
}
123123

124124
if !*quiet {
125-
fmt.Printf("%-30s\t%-50s\t%-s\n", "NAME", "LISTEN", "INTERFACE")
125+
fmt.Printf("%-20s%-50s%-s\n", "INTERFACE", "LISTEN", "NAME")
126126
}
127127

128128
sort.Strings(keys)
129129

130130
for _, k := range keys {
131131

132132
ep := view[k]
133-
fmt.Printf("%-30s\t%-50s\t%-s\n", ep.name, ep.listen, ep.spi)
133+
fmt.Printf("%-20s%-50s%-s\n", ep.spi, ep.listen, ep.name)
134134

135135
}
136136

docs/install

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
#!/bin/sh
2+
3+
# Installs infrakit by cross compiling locally inside a docker container.
4+
5+
if [[ "$(which docker)" == "" ]]; then
6+
echo "You must have Docker locally."
7+
exit -1
8+
fi
9+
10+
dir=$(pwd)
11+
case "$(uname)" in
12+
Darwin)
13+
export target="darwin"
14+
;;
15+
Linux)
16+
export target="linux"
17+
;;
18+
*)
19+
echo "not supported: $(uname)"
20+
exit -1
21+
;;
22+
esac
23+
24+
25+
docker run --rm -v $dir:/build infrakit/installer build-infrakit $target
26+
sudo cp ./infrakit /usr/local/bin

0 commit comments

Comments
 (0)