mirror of https://github.com/portainer/portainer
fix(mingit): remove mingit BE-12245 (#1177)
parent
a59815264d
commit
5418a0bee6
|
@ -1,4 +1,3 @@
|
|||
{
|
||||
"docker": "v28.3.0",
|
||||
"mingit": "2.49.0.1"
|
||||
"docker": "v28.3.0"
|
||||
}
|
||||
|
|
|
@ -7,11 +7,10 @@ ARCH=${2:-"amd64"}
|
|||
BINARY_VERSION_FILE="./binary-version.json"
|
||||
|
||||
dockerVersion=$(jq -r '.docker' < "${BINARY_VERSION_FILE}")
|
||||
mingitVersion=$(jq -r '.mingit' < "${BINARY_VERSION_FILE}")
|
||||
|
||||
mkdir -p dist
|
||||
|
||||
echo "Checking and downloading binaries for docker ${dockerVersion}, and mingit ${mingitVersion} (Windows only)"
|
||||
echo "Checking and downloading binaries for docker ${dockerVersion}"
|
||||
|
||||
# Determine the binary file names based on the platform
|
||||
dockerBinary="dist/docker"
|
||||
|
@ -27,13 +26,3 @@ if [ ! -f "$dockerBinary" ]; then
|
|||
else
|
||||
echo "Docker binary already exists, skipping download."
|
||||
fi
|
||||
|
||||
# Check and download mingit binary only for Windows
|
||||
if [ "$PLATFORM" == "windows" ]; then
|
||||
if [ ! -f "dist/mingit" ]; then
|
||||
echo "Downloading mingit binary..."
|
||||
/usr/bin/env bash ./build/download_mingit_binary.sh "$PLATFORM" "$ARCH" "$mingitVersion"
|
||||
else
|
||||
echo "Mingit binary already exists, skipping download."
|
||||
fi
|
||||
fi
|
||||
|
|
|
@ -1,18 +0,0 @@
|
|||
#!/usr/bin/env bash
|
||||
set -euo pipefail
|
||||
|
||||
if [[ $# -ne 3 ]]; then
|
||||
echo "Illegal number of parameters" >&2
|
||||
exit 1
|
||||
fi
|
||||
|
||||
PLATFORM=$1
|
||||
MINGIT_VERSION=$3
|
||||
|
||||
if [[ ${PLATFORM} == "windows" ]]; then
|
||||
GIT_VERSION=$(echo $MINGIT_VERSION | cut -d "." -f 1-3)
|
||||
GIT_PATCH_VERSION=$(echo $MINGIT_VERSION | cut -d "." -f 4)
|
||||
|
||||
wget --tries=3 --waitretry=30 --quiet "https://github.com/git-for-windows/git/releases/download/v$GIT_VERSION.windows.$GIT_PATCH_VERSION/MinGit-$GIT_VERSION-busybox-64-bit.zip"
|
||||
unzip "MinGit-$GIT_VERSION-busybox-64-bit.zip" -d dist/mingit
|
||||
fi
|
|
@ -2,13 +2,11 @@ ARG OSVERSION
|
|||
FROM --platform=linux/amd64 gcr.io/k8s-staging-e2e-test-images/windows-servercore-cache:1.0-linux-amd64-${OSVERSION} as core
|
||||
|
||||
FROM mcr.microsoft.com/windows/nanoserver:${OSVERSION} as production
|
||||
ENV PATH "C:\mingit\cmd;C:\Windows\system32;C:\Windows;"
|
||||
|
||||
COPY --from=core /Windows/System32/netapi32.dll /Windows/System32/netapi32.dll
|
||||
|
||||
USER ContainerAdministrator
|
||||
|
||||
COPY dist/mingit/ mingit/
|
||||
COPY dist/docker.exe /
|
||||
COPY dist/mustache-templates /mustache-templates/
|
||||
COPY dist/portainer.exe /
|
||||
|
|
Loading…
Reference in New Issue