update yubico-piv-tool

Signed-off-by: Jessica Frazelle <acidburn@docker.com>
This commit is contained in:
Jessica Frazelle 2015-10-31 22:14:28 -07:00
parent 8ba24e763c
commit 6f4c42fffb
No known key found for this signature in database
GPG Key ID: 18F3685C0022BFF3
3 changed files with 22 additions and 1 deletions

View File

@ -10,10 +10,14 @@ FROM debian:sid
MAINTAINER Jessica Frazelle <jess@docker.com>
RUN apt-get update && apt-get install -y \
pcscd \
usbutils \
yubico-piv-tool \
&& rm -rf /var/lib/apt/lists/*
WORKDIR /root/
COPY entrypoint.sh /usr/local/bin/
ENTRYPOINT [ "/usr/local/bin/entrypoint.sh" ]
CMD [ "yubico-piv-tool", "--help" ]

16
yubico-piv-tool/entrypoint.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/bash
init(){
local pcscd_running=$(ps -aux | grep [p]cscd)
if [ -z "$pcscd_running" ]; then
echo "starting pcscd in backgroud"
pcscd --debug --apdu
pcscd --hotplug
else
echo "pcscd is running in already: ${pcscd_running}"
fi
}
init
"$@"

View File

@ -21,6 +21,7 @@ RUN apt-get update && apt-get install -y \
ENV CCID_VERSION 1.4.20
ENV PCSC_LITE_VERSION 1.8.14
ENV YUBIKEY_PIV_TOOL_VERSION 1.1.0
RUN buildDeps=' \
autoconf \
bzip2 \
@ -62,7 +63,7 @@ RUN buildDeps=' \
&& cp src/92_pcscd_ccid.rules /etc/udev/rules.d/ \
&& cd /usr/src && rm -rf /usr/src/ccid* \
&& mkdir -p /usr/src/yubico-piv-tool \
&& curl -sSL "https://jesss.s3.amazonaws.com/tmp/yubico-piv-tool-1.0.2.tar.gz" | tar -xz -C /usr/src/yubico-piv-tool --strip-components 1 \
&& curl -sSL "https://s3.j3ss.co/tmp/yubico-piv-tool-${YUBIKEY_PIV_TOOL_VERSION}.tar.gz" | tar -xz -C /usr/src/yubico-piv-tool --strip-components 1 \
&& cd /usr/src/yubico-piv-tool \
&& ./configure --prefix="/usr" \
&& make \