Skip to content

Commit 96e5fed

Browse files
authored
provide grpc booter (#7)
1 parent 1e5e53b commit 96e5fed

File tree

13 files changed

+463
-89
lines changed

13 files changed

+463
-89
lines changed

.gitignore

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,3 +5,4 @@ pcap/pcap.test
55
pixiecore/pixiecore.test
66
vendor/
77
build/
8+
.vscode

Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ COPY . /work/
33
WORKDIR /work
44
RUN make
55

6-
FROM alpine:3.15
6+
FROM alpine:3.16
77
RUN apk -U add ca-certificates
88
COPY --from=builder /work/build/pixie /pixie
99
ENTRYPOINT ["/pixie"]

README.md

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,25 @@
11
# Pixiecore
22

33
This project is a permanent fork of: [Pixiecore](https://github.com/danderson/netboot/tree/master/pixiecore)
4+
5+
Sample command to run `pixie` in grpc mode which talks to the metal-api and provides grpc client certificates and the metal-api-view-hmac to the metal-hammer.
6+
With this metal-hammer will be able to talk to metal-api directly.
7+
8+
```bash
9+
docker run -it --rm -name pixiecore \
10+
--network host \
11+
--dns 10.1.253.13 \
12+
--dns 10.1.253.29 \
13+
--volume "/certs/grpc:/certs/grpc:ro" \
14+
ghcr.io/metal-stack/pixie grpc \
15+
--debug \
16+
--dhcp-no-bind \
17+
--pixie-api-url http://the-ip-of-this-service/certs \
18+
--grpc-address api.metal-stack.dev:50051 \
19+
--grpc-ca-cert /certs/grpc/ca.pem \
20+
--grpc-cert /certs/grpc/client.pem \
21+
--grpc-key /certs/grpc/client-key.pem \
22+
--metal-api-url https://api.metal-stack.io/metal \
23+
--metal-api-view-hmac a-view-hmac \
24+
--partition partition-1
25+
```

dhcp4/options_test.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,7 +146,7 @@ func TestOptionIP(t *testing.T) {
146146
t.Fatalf("wrong first IP, got %s", ip)
147147
}
148148

149-
ip, err = o.IP(2)
149+
_, err = o.IP(2)
150150
if err == nil {
151151
t.Fatal("option shouldn't be a valid IPs")
152152
}

go.mod

Lines changed: 23 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -3,47 +3,49 @@ module github.com/metal-stack/pixie
33
go 1.18
44

55
require (
6+
github.com/metal-stack/metal-api v0.18.0
67
github.com/metal-stack/v v1.0.3
78
github.com/pin/tftp v0.0.0-20210809155059-0161c5dd2e96
8-
github.com/prometheus/client_golang v1.12.1
9+
github.com/prometheus/client_golang v1.12.2
910
github.com/spf13/cobra v1.4.0
10-
github.com/spf13/viper v1.11.0
11-
github.com/stretchr/testify v1.7.1
11+
github.com/spf13/viper v1.12.0
12+
github.com/stretchr/testify v1.7.2
1213
go.uber.org/zap v1.21.0
13-
golang.org/x/crypto v0.0.0-20220427172511-eb4f295cb31f
14-
golang.org/x/net v0.0.0-20220425223048-2871e0cb64e4
14+
golang.org/x/crypto v0.0.0-20220525230936-793ad666bf5e
15+
golang.org/x/net v0.0.0-20220607020251-c690dde0001d
16+
google.golang.org/grpc v1.47.0
1517
)
1618

17-
require (
18-
github.com/benbjohnson/clock v1.1.0 // indirect
19+
require (
20+
github.com/benbjohnson/clock v1.3.0 // indirect
1921
github.com/beorn7/perks v1.0.1 // indirect
2022
github.com/cespare/xxhash/v2 v2.1.2 // indirect
2123
github.com/davecgh/go-spew v1.1.1 // indirect
22-
github.com/fsnotify/fsnotify v1.5.1 // indirect
24+
github.com/fsnotify/fsnotify v1.5.4 // indirect
2325
github.com/golang/protobuf v1.5.2 // indirect
24-
github.com/google/go-cmp v0.5.8 // indirect
2526
github.com/hashicorp/hcl v1.0.0 // indirect
2627
github.com/inconshreveable/mousetrap v1.0.0 // indirect
2728
github.com/magiconair/properties v1.8.6 // indirect
28-
github.com/matttproud/golang_protobuf_extensions v1.0.1 // indirect
29-
github.com/mitchellh/mapstructure v1.4.3 // indirect
30-
github.com/pelletier/go-toml v1.9.4 // indirect
31-
github.com/pelletier/go-toml/v2 v2.0.0-beta.8 // indirect
29+
github.com/matttproud/golang_protobuf_extensions v1.0.2-0.20181231171920-c182affec369 // indirect
30+
github.com/mitchellh/mapstructure v1.5.0 // indirect
31+
github.com/pelletier/go-toml v1.9.5 // indirect
32+
github.com/pelletier/go-toml/v2 v2.0.1 // indirect
3233
github.com/pmezard/go-difflib v1.0.0 // indirect
3334
github.com/prometheus/client_model v0.2.0 // indirect
34-
github.com/prometheus/common v0.32.1 // indirect
35+
github.com/prometheus/common v0.34.0 // indirect
3536
github.com/prometheus/procfs v0.7.3 // indirect
3637
github.com/spf13/afero v1.8.2 // indirect
37-
github.com/spf13/cast v1.4.1 // indirect
38+
github.com/spf13/cast v1.5.0 // indirect
3839
github.com/spf13/jwalterweatherman v1.1.0 // indirect
3940
github.com/spf13/pflag v1.0.5 // indirect
40-
github.com/subosito/gotenv v1.2.0 // indirect
41-
go.uber.org/atomic v1.7.0 // indirect
42-
go.uber.org/multierr v1.6.0 // indirect
43-
golang.org/x/sys v0.0.0-20220503163025-988cb79eb6c6 // indirect
41+
github.com/subosito/gotenv v1.3.0 // indirect
42+
go.uber.org/atomic v1.9.0 // indirect
43+
go.uber.org/multierr v1.8.0 // indirect
44+
golang.org/x/sys v0.0.0-20220520151302-bc2c85ada10a // indirect
4445
golang.org/x/text v0.3.7 // indirect
46+
google.golang.org/genproto v0.0.0-20220531173845-685668d2de03 // indirect
4547
google.golang.org/protobuf v1.28.0 // indirect
46-
gopkg.in/ini.v1 v1.66.4 // indirect
48+
gopkg.in/ini.v1 v1.66.6 // indirect
4749
gopkg.in/yaml.v2 v2.4.0 // indirect
48-
gopkg.in/yaml.v3 v3.0.0-20210107192922-496545a6307b // indirect
50+
gopkg.in/yaml.v3 v3.0.1 // indirect
4951
)

0 commit comments

Comments
 (0)