From 120179950934692bd304ce5f38a54f0ecba673eb Mon Sep 17 00:00:00 2001 From: Binyang2014 Date: Mon, 30 Dec 2019 19:23:12 +0800 Subject: [PATCH] [Storage-Manager] move apt-get to docker image (#4086) * move apt-get to docker image --- src/storage-manager/build/storage-manager.dockerfile | 11 ++++++++++- src/storage-manager/deploy/scripts/entrypoint.sh | 9 +-------- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/src/storage-manager/build/storage-manager.dockerfile b/src/storage-manager/build/storage-manager.dockerfile index c332c94abb..7562d87df6 100644 --- a/src/storage-manager/build/storage-manager.dockerfile +++ b/src/storage-manager/build/storage-manager.dockerfile @@ -26,7 +26,16 @@ RUN apt-get -y update && \ nfs-common \ netbase \ nfs-kernel-server \ - kmod + kmod \ + winbind \ + libpam-winbind \ + libnss-winbind + +# Use default config for Kerberos +RUN DEBIAN_FRONTEND=noninteractive apt-get -y install \ + libpam-krb5 \ + krb5-config \ + krb5-user ENV SHARE_ROOT=/share/pai diff --git a/src/storage-manager/deploy/scripts/entrypoint.sh b/src/storage-manager/deploy/scripts/entrypoint.sh index 21b38eb428..ffadf2795c 100644 --- a/src/storage-manager/deploy/scripts/entrypoint.sh +++ b/src/storage-manager/deploy/scripts/entrypoint.sh @@ -32,16 +32,9 @@ cp /etc/pai-config/smb.conf /etc/samba/smb.conf # install krb5 and join domain if [[ $SECURETYPE == "ADS" ]]; then - echo "install krb5 ----------" + echo "init krb5 ----------" cp /etc/pai-config/krb5.conf /etc/krb5.conf cp /etc/pai-config/nsswitch.conf /etc/nsswitch.conf - apt update && apt install -y \ - winbind \ - libpam-winbind \ - libnss-winbind \ - libpam-krb5 \ - krb5-config \ - krb5-user echo "join domain ----------" net ads join -U "$DOMAINUSER"%"$DOMAINPWD" echo "domain info ----------"