first commit
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
Some checks failed
Vulhub Format Check and Lint / format-check (push) Has been cancelled
Vulhub Format Check and Lint / markdown-check (push) Has been cancelled
Vulhub Docker Image CI / longtime-images-test (push) Has been cancelled
Vulhub Docker Image CI / images-test (push) Has been cancelled
This commit is contained in:
29
base/git/2.12.2/Dockerfile
Normal file
29
base/git/2.12.2/Dockerfile
Normal file
@@ -0,0 +1,29 @@
|
||||
FROM debian:buster
|
||||
|
||||
LABEL maintainer="phithon <root@leavesongs.com>"
|
||||
|
||||
RUN set -ex \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y --no-install-recommends ca-certificates \
|
||||
&& savedAptMark="$(apt-mark showmanual)" \
|
||||
&& apt-get install -y --no-install-recommends gcc make wget dh-autoreconf libcurl4-gnutls-dev libexpat1-dev gettext zlib1g-dev libssl-dev asciidoc xmlto docbook2x \
|
||||
&& mkdir -p /usr/src/git \
|
||||
&& wget -qO- https://github.com/git/git/archive/v2.12.2.tar.gz | tar zx -C /usr/src/git --strip-components=1 \
|
||||
&& cd /usr/src/git \
|
||||
&& make configure \
|
||||
&& ./configure --prefix=/usr/local \
|
||||
&& make all doc info \
|
||||
&& make install install-doc \
|
||||
# remove unused libraries
|
||||
&& apt-mark auto '.*' > /dev/null \
|
||||
&& apt-mark manual $savedAptMark \
|
||||
&& find /usr/local -type f -executable -exec ldd '{}' ';' \
|
||||
| awk '/=>/ { print $(NF-1) }' \
|
||||
| sort -u \
|
||||
| xargs -r dpkg-query --search \
|
||||
| cut -d: -f1 \
|
||||
| sort -u \
|
||||
| xargs -r apt-mark manual \
|
||||
\
|
||||
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
|
||||
&& rm -rf /var/lib/apt/lists/* /usr/src/git
|
26
base/git/2.12.2/with-openssh/Dockerfile
Normal file
26
base/git/2.12.2/with-openssh/Dockerfile
Normal file
@@ -0,0 +1,26 @@
|
||||
FROM vulhub/git:2.12.2
|
||||
|
||||
LABEL maintainer="phithon <root@leavesongs.com>"
|
||||
|
||||
RUN set -ex \
|
||||
&& apt-get update \
|
||||
&& apt-get install --no-install-recommends -y man less openssh-server \
|
||||
&& rm -r /var/lib/apt/lists/*
|
||||
|
||||
RUN set -ex \
|
||||
&& mkdir /var/run/sshd \
|
||||
&& chmod 0755 /var/run/sshd \
|
||||
&& echo 'git:x:33:33:git:/home/git:/bin/bash' >> /etc/passwd \
|
||||
&& echo 'git:*:16462:0:99999:7:::' >> /etc/shadow \
|
||||
&& echo 'git:x:33:' >> /etc/group \
|
||||
&& mkdir -p /home/git/.ssh \
|
||||
&& chown 33.33 -R /home/git
|
||||
|
||||
COPY authorized_keys /home/git/.ssh/authorized_keys
|
||||
|
||||
RUN chown 33.33 /home/git/.ssh/authorized_keys \
|
||||
&& chmod 0600 /home/git/.ssh/authorized_keys
|
||||
|
||||
EXPOSE 22
|
||||
|
||||
CMD ["/usr/sbin/sshd", "-D"]
|
1
base/git/2.12.2/with-openssh/authorized_keys
Normal file
1
base/git/2.12.2/with-openssh/authorized_keys
Normal file
@@ -0,0 +1 @@
|
||||
command="git-shell -c \"$SSH_ORIGINAL_COMMAND\"" ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCx/SUFC0h3o4fun2i3Ag/OmJHeZSp85zYwuKWaPzcKy8fUv/R5crsPBTw6hbVpuoTuIQVhjdzGDz3seV0FcA3eeqQKTiyr8eA+GjhraGdHda4yBtUsjYDFPz0OhP+1h26ar3Imzj0FiMy0qjukGF0gP5j7EddpuZ6YBFlnutpR+fqx5tPdKflZRFD590IJGFHO33ozjknxS6pIaBuiixQ4H+oX/xLMZGMvyqAeTWDLas9JF4pLlUZ1fQUyfyANms6OyFCnzIAbiQDekFDREM8tEM8fLFYXrO3Tt+01dXxLhhASufN0fjI+ewCeC/SJuBqxBDG1M7FgB5/BIHN3z6ab test@vulhub
|
29
base/git/2.29.1/Dockerfile
Normal file
29
base/git/2.29.1/Dockerfile
Normal file
@@ -0,0 +1,29 @@
|
||||
FROM debian:buster
|
||||
|
||||
LABEL maintainer="phithon <root@leavesongs.com>"
|
||||
|
||||
RUN set -ex \
|
||||
&& apt-get update \
|
||||
&& apt-get install -y --no-install-recommends ca-certificates \
|
||||
&& savedAptMark="$(apt-mark showmanual)" \
|
||||
&& apt-get install -y --no-install-recommends gcc make wget dh-autoreconf libcurl4-gnutls-dev libexpat1-dev gettext zlib1g-dev libssl-dev \
|
||||
&& mkdir -p /usr/src/git \
|
||||
&& wget -qO- https://github.com/git/git/archive/v2.29.1.tar.gz | tar zx -C /usr/src/git --strip-components=1 \
|
||||
&& cd /usr/src/git \
|
||||
&& make configure \
|
||||
&& ./configure --prefix=/usr/local \
|
||||
&& make all \
|
||||
&& make install \
|
||||
# remove unused libraries
|
||||
&& apt-mark auto '.*' > /dev/null \
|
||||
&& apt-mark manual $savedAptMark \
|
||||
&& find /usr/local -type f -executable -exec ldd '{}' ';' \
|
||||
| awk '/=>/ { print $(NF-1) }' \
|
||||
| sort -u \
|
||||
| xargs -r dpkg-query --search \
|
||||
| cut -d: -f1 \
|
||||
| sort -u \
|
||||
| xargs -r apt-mark manual \
|
||||
\
|
||||
&& apt-get purge -y --auto-remove -o APT::AutoRemove::RecommendsImportant=false \
|
||||
&& rm -rf /var/lib/apt/lists/* /usr/src/git
|
Reference in New Issue
Block a user