Initial set of builds for Cadmium
This commit is contained in:
24
scripts/download
Executable file
24
scripts/download
Executable file
@@ -0,0 +1,24 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ "x$1" = "x" ]; then
|
||||
echo "Usage: $0 <Tarball URL>"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if [ -e "source" ]; then
|
||||
echo "source/ directory already exists, remove it first"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
curl -L "$1" | tar -xzf -
|
||||
mv caddy* source
|
||||
|
||||
# Disable telemetry in run.go and rename to Cadmium
|
||||
patch -d source -p1 <"$(pwd)/patches/run.go.diff"
|
||||
|
||||
# Replace telemetry with a stub
|
||||
rm -r source/telemetry
|
||||
mkdir source/telemetry
|
||||
cp patches/collection.go source/telemetry/collection.go
|
||||
|
||||
|
Reference in New Issue
Block a user