From 4641ccfc6be4df8788ba5cc4325a8831f6c2c054 Mon Sep 17 00:00:00 2001 From: Misty Stanley-Jones Date: Mon, 18 Sep 2017 15:39:21 -0700 Subject: [PATCH] Give sudo access to local environment variable (#4660) --- _includes/ee-linux-install-reuse.md | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/_includes/ee-linux-install-reuse.md b/_includes/ee-linux-install-reuse.md index 68848a580f..db564731be 100644 --- a/_includes/ee-linux-install-reuse.md +++ b/_includes/ee-linux-install-reuse.md @@ -69,7 +69,7 @@ You can install Docker EE in different ways, depending on your needs: This command relies on the variable you stored in the previous step. ```bash - $ sudo sh -c 'echo "$DOCKERURL/{{ linux-dist-url-slug }}" > /etc/yum/vars/dockerurl' + $ sudo -E sh -c 'echo "$DOCKERURL/{{ linux-dist-url-slug }}" > /etc/yum/vars/dockerurl' ``` {% if linux-dist == "rhel" %} @@ -78,6 +78,10 @@ You can install Docker EE in different ways, depending on your needs: should use `7`, but you can also use the more specific minor version, starting from `7.2`. + ```bash + $ sudo sh -c 'echo "7" > /etc/yum/vars/dockerosversion' + ``` + {% endif %} 4. Install required packages. `yum-utils` provides the `yum-config-manager` @@ -119,7 +123,7 @@ You can install Docker EE in different ways, depending on your needs: 6. Use the following command to add the **stable** repository: ```bash - $ sudo yum-config-manager \ + $ sudo -E yum-config-manager \ --add-repo \ "$DOCKERURL/{{ linux-dist-url-slug }}/docker-ee.repo" ```