-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
bfed790
commit f4d0a8a
Showing
5 changed files
with
54 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
env: | ||
- GO111MODULE=on | ||
- GOPROXY=https://gocenter.io | ||
before: | ||
hooks: | ||
- go mod tidy | ||
builds: | ||
- env: | ||
- CGO_ENABLED=0 | ||
archives: | ||
- replacements: | ||
darwin: Darwin | ||
linux: Linux | ||
windows: Windows | ||
386: i386 | ||
amd64: x86_64 | ||
checksum: | ||
name_template: 'checksums.txt' | ||
snapshot: | ||
name_template: "{{ .Tag }}-next" | ||
changelog: | ||
sort: asc | ||
filters: | ||
exclude: | ||
- '^docs:' | ||
- '^test:' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,22 @@ | ||
# tftp-proxy | ||
A TFTP server that proxies request to an HTTP backend if a file is not found. | ||
|
||
# How to build | ||
# Building | ||
|
||
go build | ||
|
||
or for linux: | ||
|
||
env GOOS=linux GOARCH=amd64 go build | ||
|
||
# How to run | ||
./tftp-proxy -url=http://example.com -dir=/var/lib/tftpboot & | ||
|
||
or for linux: | ||
|
||
scp tftp-proxy.service tftp-proxy destination-host: | ||
ssh destination-host | ||
sudo mv tftp-proxy.service /etc/systemd/system/ | ||
sudo mv tftp-proxy /usr/bin/tftp-proxy | ||
sudo vi /etc/systemd/system/tftp-proxy.service | ||
systemctl enable tftp-proxy |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,5 @@ | ||
module tftp-proxy | ||
|
||
require github.com/pin/tftp v2.1.0+incompatible | ||
|
||
go 1.13 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
[Unit] | ||
Description=tftp-proxy | ||
|
||
[Service] | ||
ExecStart=/usr/bin/tftp-proxy -url=http://zerotouch.example.com | ||
|
||
[Install] | ||
WantedBy=multi-user.target |