Update URLs

This commit is contained in:
weslambert
2024-05-08 23:48:45 -04:00
committed by GitHub
parent 1bf216ea5a
commit 8b87da02e0

View File

@@ -10,10 +10,10 @@ RUN chmod +x entrypoint && \
mkdir -p /opt/velociraptor && \
for i in linux mac windows; do mkdir -p /opt/velociraptor/$i; done && \
# Get Velox binaries
WINDOWS_EXE=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r 'limit(6 ; ( .assets[].browser_download_url | select ( contains("windows-amd64.exe") )))' | grep -vE '.sig' | tail -1) && \
WINDOWS_MSI=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r 'limit(6 ; ( .assets[].browser_download_url | select ( contains("windows-amd64.msi") )))' | grep -vE '.sig' | tail -1) && \
LINUX_BIN=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r 'limit(6 ; ( .assets[].browser_download_url | select ( contains("linux-amd64") )))' | grep -vE "musl|sig" | sort | tail -1) && \
MAC_BIN=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r 'limit(1 ; ( .assets[].browser_download_url | select ( contains("darwin-amd64") )))' | grep -vE '.sig' | tail -1) && \
WINDOWS_EXE=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r '[.assets | sort_by(.created_at) | reverse | .[] | .browser_download_url | select(test("windows-amd64.exe$"))][0]') && \
WINDOWS_MSI=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r '[.assets | sort_by(.created_at) | reverse | .[] | .browser_download_url | select(test("windows-amd64.msi$"))][0]') && \
LINUX_BIN=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r '[.assets | sort_by(.created_at) | reverse | .[] | .browser_download_url | select(test("linux-amd64$"))][0]') && \
MAC_BIN=$(curl -s https://api.github.com/repos/velocidex/velociraptor/releases/latest | jq -r '[.assets | sort_by(.created_at) | reverse | .[] | .browser_download_url | select(test("darwin-amd64$"))][0]') && \
wget -O /opt/velociraptor/linux/velociraptor "$LINUX_BIN" && \
wget -O /opt/velociraptor/mac/velociraptor_client "$MAC_BIN" && \
wget -O /opt/velociraptor/windows/velociraptor_client.exe "$WINDOWS_EXE" && \
@@ -23,4 +23,3 @@ RUN chmod +x entrypoint && \
apt-get clean
WORKDIR /velociraptor
CMD ["/entrypoint"]