Add go module

This commit is contained in:
nemunaire 2022-02-19 00:12:13 +01:00
parent ad11e9ce7f
commit d41785fd9a
4 changed files with 44 additions and 14 deletions

View File

@ -3,7 +3,7 @@ LINUXKIT ?= $(GOPATH)/bin/linuxkit
tuto1: token-validator/token-validator server.iso tuto1: token-validator/token-validator server.iso
pkg/login-app: pkg/login-app/cmd/login.go pkg/login-app/cmd/dialog-checklogin.go pkg/login-app/cmd/cmd pkg/login-app/cmd/dialog-login.go pkg/login-app/cmd/login-app pkg/login-app/cmd/dialog-errmsg.go pkg/login-app/cmd/main.go pkg/login-app/cmd/stream.go pkg/login-app/cmd/cinematic.go pkg/login-app/build.yml pkg/login-app/Dockerfile pkg/login-app: pkg/login-app/cmd/login.go pkg/login-app/cmd/dialog-checklogin.go pkg/login-app/cmd/cmd pkg/login-app/cmd/dialog-login.go pkg/login-app/cmd/login-app pkg/login-app/cmd/dialog-errmsg.go pkg/login-app/cmd/main.go pkg/login-app/cmd/stream.go pkg/login-app/cmd/cinematic.go pkg/login-app/build.yml pkg/login-app/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/login-app/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/login-app/
#$(LINUXKIT) pkg push -org nemunaire --sign=false pkg/login-app/ #$(LINUXKIT) pkg push -org nemunaire --sign=false pkg/login-app/
touch pkg/login-app touch pkg/login-app
@ -15,61 +15,61 @@ token-validator/token-validator: token-validator/*.go
GOOS=linux GOARM=5 GOARCH=arm go build -tags netgo -ldflags '-w -extldflags "-static"' -o $@ ./token-validator GOOS=linux GOARM=5 GOARCH=arm go build -tags netgo -ldflags '-w -extldflags "-static"' -o $@ ./token-validator
challenge: pkg/challenge/adlin pkg/challenge/issue pkg/challenge/init challenge: pkg/challenge/adlin pkg/challenge/issue pkg/challenge/init
$(LINUXKIT) pkg build -org nemunaire pkg/challenge/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/challenge/
challenge-initrd.img: challenge.yml subject/adlin.6.gz subject/adlin-TP1-topologie.png challenge-initrd.img: challenge.yml subject/adlin.6.gz subject/adlin-TP1-topologie.png
$(LINUXKIT) build -docker $< $(LINUXKIT) build -docker $<
pkg/arp-spoofer: pkg/arp-spoofer/cmd/main.go pkg/arp-spoofer/cmd/arp.go pkg/arp-spoofer/build.yml pkg/arp-spoofer/Dockerfile pkg/arp-spoofer: pkg/arp-spoofer/cmd/main.go pkg/arp-spoofer/cmd/arp.go pkg/arp-spoofer/build.yml pkg/arp-spoofer/Dockerfile
$(LINUXKIT) pkg build -org nemunaire $@ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire $@
touch $@ touch $@
pkg/login-validator: pkg/login-validator/cmd/login.go pkg/login-validator/cmd/main.go pkg/login-validator/cmd/pxetpl.go pkg/login-validator/cmd/logout.go pkg/login-validator/cmd/auth.go pkg/login-validator/cmd/arp.go pkg/login-validator/cmd/auth_krb5.go pkg/login-validator/cmd/auth_ldap.go pkg/login-validator/cmd/students.go pkg/login-validator/cmd/auth_fwd.go pkg/login-validator/cmd/ssh.go pkg/login-validator/build.yml pkg/login-validator/Dockerfile pkg/login-validator: pkg/login-validator/cmd/login.go pkg/login-validator/cmd/main.go pkg/login-validator/cmd/pxetpl.go pkg/login-validator/cmd/logout.go pkg/login-validator/cmd/auth.go pkg/login-validator/cmd/arp.go pkg/login-validator/cmd/auth_krb5.go pkg/login-validator/cmd/auth_ldap.go pkg/login-validator/cmd/students.go pkg/login-validator/cmd/auth_fwd.go pkg/login-validator/cmd/ssh.go pkg/login-validator/build.yml pkg/login-validator/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/login-validator/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/login-validator/
touch pkg/login-validator touch pkg/login-validator
pkg/monit: pkg/monit/build.yml pkg/monit/Dockerfile pkg/monit: pkg/monit/build.yml pkg/monit/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/monit/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/monit/
touch pkg/monit touch pkg/monit
pkg/postfix: pkg/postfix/build.yml pkg/postfix/docker-entrypoint.sh pkg/postfix/Dockerfile pkg/postfix: pkg/postfix/build.yml pkg/postfix/docker-entrypoint.sh pkg/postfix/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/postfix/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/postfix/
touch pkg/postfix touch pkg/postfix
pkg/tftpd: pkg/tftpd/build.yml pkg/tftpd/Dockerfile pkg/tftpd: pkg/tftpd/build.yml pkg/tftpd/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/tftpd/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/tftpd/
touch pkg/tftpd touch pkg/tftpd
pkg/unbound: pkg/unbound/build.yml pkg/unbound/docker-entrypoint.sh pkg/unbound/Dockerfile pkg/unbound: pkg/unbound/build.yml pkg/unbound/docker-entrypoint.sh pkg/unbound/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/unbound/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/unbound/
touch pkg/unbound touch pkg/unbound
pkg/wg-manager: pkg/wg-manager/cmd/register.go pkg/wg-manager/cmd/main.go pkg/wg-manager/build.yml pkg/wg-manager/Dockerfile pkg/wg-manager: pkg/wg-manager/cmd/register.go pkg/wg-manager/cmd/main.go pkg/wg-manager/build.yml pkg/wg-manager/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/wg-manager/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/wg-manager/
touch pkg/wg-manager touch pkg/wg-manager
server.iso: server.yml students.csv ssl/fullchain.pem ssl/privkey.pem challenge-initrd.img pkg/arp-spoofer pkg/login-validator pkg/monit pkg/postfix pkg/tftpd pkg/unbound pkg/wg-manager challenge-kernel login-initrd.img server.iso: server.yml students.csv ssl/fullchain.pem ssl/privkey.pem challenge-initrd.img pkg/arp-spoofer pkg/login-validator pkg/monit pkg/postfix pkg/tftpd pkg/unbound pkg/wg-manager challenge-kernel login-initrd.img
$(LINUXKIT) build -docker -format iso-bios $< $(LINUXKIT) build -docker -format iso-bios $<
pkg/debian-tuto2: pkg/debian-tuto2/sshd_config pkg/debian-tuto2/gai.conf pkg/debian-tuto2/isolinux.cfg pkg/debian-tuto2/build.yml pkg/debian-tuto2/default.script pkg/debian-tuto2/issue pkg/debian-tuto2/Dockerfile pkg/debian-tuto2: pkg/debian-tuto2/sshd_config pkg/debian-tuto2/gai.conf pkg/debian-tuto2/isolinux.cfg pkg/debian-tuto2/build.yml pkg/debian-tuto2/default.script pkg/debian-tuto2/issue pkg/debian-tuto2/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/debian-tuto2/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/debian-tuto2/
touch pkg/debian-tuto2 touch pkg/debian-tuto2
pkg/debian-tuto3: pkg/debian-tuto3/sshd_config pkg/debian-tuto3/build.yml pkg/debian-tuto3/issue pkg/debian-tuto3/Dockerfile pkg/debian-tuto3: pkg/debian-tuto3/sshd_config pkg/debian-tuto3/build.yml pkg/debian-tuto3/issue pkg/debian-tuto3/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/debian-tuto3/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/debian-tuto3/
touch pkg/debian-tuto3 touch pkg/debian-tuto3
pkg/router-tuto3: pkg/router-tuto3/build.yml pkg/router-tuto3/Dockerfile pkg/router-tuto3: pkg/router-tuto3/build.yml pkg/router-tuto3/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/router-tuto3/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/router-tuto3/
touch pkg/router-tuto3 touch pkg/router-tuto3
pkg/tinydeb: pkg/tinydeb/sshd_config pkg/tinydeb/gai.conf pkg/tinydeb/build.yml pkg/tinydeb/Dockerfile pkg/tinydeb: pkg/tinydeb/sshd_config pkg/tinydeb/gai.conf pkg/tinydeb/build.yml pkg/tinydeb/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/tinydeb/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/tinydeb/
touch pkg/tinydeb touch pkg/tinydeb
pkg/nsd: pkg/nsd/sshd_config pkg/nsd/build.yml pkg/nsd/init pkg/nsd/Dockerfile pkg/nsd: pkg/nsd/sshd_config pkg/nsd/build.yml pkg/nsd/init pkg/nsd/Dockerfile
$(LINUXKIT) pkg build -org nemunaire pkg/tinydeb/ $(LINUXKIT) pkg build --platforms linux/amd64 -org nemunaire pkg/tinydeb/
touch pkg/nsd touch pkg/nsd
tuto2-kernel: tuto2.yml tuto2-kernel: tuto2.yml

View File

@ -0,0 +1,12 @@
module git.nemunai.re/srs/adlin/pkg/arp-spoofer
go 1.16
require github.com/mdlayher/arp v0.0.0-20191213142603-f72070a231fc
require (
github.com/mdlayher/ethernet v0.0.0-20190313224307-5b5fc417d966 // indirect
github.com/mdlayher/raw v0.0.0-20190313224157-43dbcdd7739d // indirect
golang.org/x/net v0.0.0-20190313220215-9f648a60d977 // indirect
golang.org/x/sys v0.0.0-20190312061237-fead79001313 // indirect
)

View File

@ -0,0 +1,15 @@
github.com/google/go-cmp v0.2.0 h1:+dTQ8DZQJz0Mb/HjFlkptS1FeQ4cWSnN941F8aEG4SQ=
github.com/google/go-cmp v0.2.0/go.mod h1:oXzfMopK8JAjlY9xF4vHSVASa0yLyX7SntLO5aqRK0M=
github.com/mdlayher/arp v0.0.0-20191213142603-f72070a231fc h1:m7rJJJeXrYCFpsxXYapkDW53wJCDmf9bsIXUg0HoeQY=
github.com/mdlayher/arp v0.0.0-20191213142603-f72070a231fc/go.mod h1:eOj1DDj3NAZ6yv+WafaKzY37MFZ58TdfIhQ+8nQbiis=
github.com/mdlayher/ethernet v0.0.0-20190313224307-5b5fc417d966 h1:O3p5UmisBhl3V6lgs4Vdfg8HpjzbWJPyOfGLdwVJSmI=
github.com/mdlayher/ethernet v0.0.0-20190313224307-5b5fc417d966/go.mod h1:5s5p/sMJ6sNsFl6uCh85lkFGV8kLuIYJCRJLavVJwvg=
github.com/mdlayher/raw v0.0.0-20190313224157-43dbcdd7739d h1:rjAS0af7FIYCScTtEU5KjIldC6qVaEScUJhABHC+ccM=
github.com/mdlayher/raw v0.0.0-20190313224157-43dbcdd7739d/go.mod h1:r1fbeITl2xL/zLbVnNHFyOzQJTgr/3fpf1lJX/cjzR8=
golang.org/x/crypto v0.0.0-20190308221718-c2843e01d9a2/go.mod h1:djNgcEr1/C05ACkg1iLfiJU5Ep61QUkGW8qpdssI0+w=
golang.org/x/net v0.0.0-20190313220215-9f648a60d977 h1:actzWV6iWn3GLqN8dZjzsB+CLt+gaV2+wsxroxiQI8I=
golang.org/x/net v0.0.0-20190313220215-9f648a60d977/go.mod h1:t9HGtf8HONx5eT2rtn7q6eTqICYqUVnKs3thJo3Qplg=
golang.org/x/sys v0.0.0-20190215142949-d0b11bdaac8a/go.mod h1:STP8DvDyc/dI5b8T5hshtkjS+E42TnysNCUPdjciGhY=
golang.org/x/sys v0.0.0-20190312061237-fead79001313 h1:pczuHS43Cp2ktBEEmLwScxgjWsBSzdaQiKzUyf3DTTc=
golang.org/x/sys v0.0.0-20190312061237-fead79001313/go.mod h1:h1NjWce9XRLGQEsW7wpKNCjG9DtNlClVuFLEZdDNbEs=
golang.org/x/text v0.3.0/go.mod h1:NqM8EUOU14njkJ3fqMW+pc6Ldnwhi/IjpwHt7yyuwOQ=

View File

@ -0,0 +1,3 @@
module git.nemunai.re/srs/adlin/pkg/wg-manager
go 1.16