diff options
author | Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org> | 2018-06-05 12:24:55 +0000 |
---|---|---|
committer | Maxim Kuvyrkov <maxim.kuvyrkov@linaro.org> | 2018-06-05 12:24:55 +0000 |
commit | 47bde2dd97c1bf74dfc2614f7427e93a26794169 (patch) | |
tree | e221a92b593cda45da3e6dedeccfd0f999955805 /xenial-arm64-tcwg-base | |
parent | 70e4517c8db330f8c30a2faaa4c676c471eecc46 (diff) |
tcwg-host: Generalize handling of /home files
Change-Id: I33b65cc9657a399367379eb85543408b4687cc5a
Diffstat (limited to 'xenial-arm64-tcwg-base')
-rw-r--r-- | xenial-arm64-tcwg-base/xenial-arm64-tcwg-host/Dockerfile | 20 |
1 files changed, 12 insertions, 8 deletions
diff --git a/xenial-arm64-tcwg-base/xenial-arm64-tcwg-host/Dockerfile b/xenial-arm64-tcwg-base/xenial-arm64-tcwg-host/Dockerfile index 7c8fabb5..d90081f2 100644 --- a/xenial-arm64-tcwg-base/xenial-arm64-tcwg-host/Dockerfile +++ b/xenial-arm64-tcwg-base/xenial-arm64-tcwg-host/Dockerfile @@ -1,12 +1,16 @@ # Auto generated from tcwg-base/tcwg-host/Dockerfile.in. Do not edit. FROM linaro/ci-arm64-tcwg-base-ubuntu:xenial -COPY authorized_keys-* passwd / +COPY passwd start.sh / +COPY home/ /home-data/ -RUN new-user.sh --group primary:10000 \ - && while read line; do new-user.sh --passwd "$line"; done </passwd \ - && for key in /authorized_keys-*; do new-user.sh --key "$key"; done \ - && rm /passwd /authorized_keys-* - -COPY start.sh / -# checksum: afddac381f8b29995fca71713d12bbc7 +RUN new-user.sh --group tcwg-infra:9000 && new-user.sh --group primary:10000 \ + && while read line; do \ + new-user.sh --passwd "$line"; \ + user=$(echo "$line" | cut -d: -f 1); \ + gid=$(echo "$line" | cut -d: -f 4); \ + chown -R $user:$gid /home-data/$user/; \ + rsync -a /home-data/$user/ /home/$user/; \ + done </passwd \ + && rm -rf /passwd /home-data/ +# checksum: c86a4054a024547022a39736bfef0604 |