From 3e467baf577089436b8c54c836d58003dfbd071b Mon Sep 17 00:00:00 2001 From: Shubham Bhattar Date: Sun, 21 Oct 2018 00:56:29 +0530 Subject: [PATCH] Used ADD command to download and save ONFILE script. ADD is capable of fetching remote files and saving it to the image. Thus, no need to depend on curl command anymore. This is related to [https://github.com/auth0/vault/pull/5](https://github.com/auth0/vault/pull/5) --- README.md | 18 ++++++------------ 1 file changed, 6 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 075e6a8..b507adc 100644 --- a/README.md +++ b/README.md @@ -19,22 +19,18 @@ First you need to install the `ONVAULT` utility, by adding the following stateme ```Dockerfile # installs Dockito Vault ONVAULT utility # https://github.com/dockito/vault -RUN apt-get update -y && \ - apt-get install -y curl && \ - curl -L https://raw.githubusercontent.com/dockito/vault/master/ONVAULT > /usr/local/bin/ONVAULT && \ - chmod +x /usr/local/bin/ONVAULT +ADD https://raw.githubusercontent.com/dockito/vault/master/ONVAULT /usr/local/bin/ONVAULT +RUN chmod +x /usr/local/bin/ONVAULT ``` -The script's only dependency is `curl` (being installed above). Or on Alpine Linux: ```Dockerfile # installs Dockito Vault ONVAULT utility # https://github.com/dockito/vault -RUN apk add -Uuv bash curl && \ - curl -L https://raw.githubusercontent.com/dockito/vault/master/ONVAULT > /usr/local/bin/ONVAULT && \ - chmod +x /usr/local/bin/ONVAULT +ADD https://raw.githubusercontent.com/dockito/vault/master/ONVAULT /usr/local/bin/ONVAULT +RUN chmod +x /usr/local/bin/ONVAULT ``` Then use it on any command that requires the private keys: @@ -50,10 +46,8 @@ FROM node:0.10.38 # installs Dockito Vault ONVAULT utility # https://github.com/dockito/vault -RUN apt-get update -y && \ - apt-get install -y curl && \ - curl -L https://raw.githubusercontent.com/dockito/vault/master/ONVAULT > /usr/local/bin/ONVAULT && \ - chmod +x /usr/local/bin/ONVAULT +ADD https://raw.githubusercontent.com/dockito/vault/master/ONVAULT /usr/local/bin/ONVAULT +RUN chmod +x /usr/local/bin/ONVAULT RUN mkdir -p /usr/src/app WORKDIR /usr/src/app