From: Kefu Chai Date: Sat, 29 Sep 2018 03:47:52 +0000 (+0800) Subject: ceph-dashboard-pull-requests: fix permission denied error X-Git-Url: http://git-server-git.apps.pok.os.sepia.ceph.com/?a=commitdiff_plain;h=refs%2Fpull%2F1139%2Fhead;p=ceph-build.git ceph-dashboard-pull-requests: fix permission denied error as stdout redirect is performed by the shell, and shell is launched by the "jenkins" user, so permission denied is expected when we are trying to create a file under /etc/yum.repos.d/. in that case, we'll have following failure: /tmp/jenkins8899238112048417478.sh: line 14: /etc/yum.repos.d/google-chrome.repo: Permission denied Build step 'Execute shell' marked build as failure Signed-off-by: Kefu Chai --- diff --git a/ceph-dashboard-pull-requests/setup/setup b/ceph-dashboard-pull-requests/setup/setup index 835a2d08..9fdd1c74 100644 --- a/ceph-dashboard-pull-requests/setup/setup +++ b/ceph-dashboard-pull-requests/setup/setup @@ -9,13 +9,13 @@ if grep -q debian /etc/*-release; then sudo apt-get install -y google-chrome-stable elif grep -q rhel /etc/*-release; then - sudo cat <<-EOF > /etc/yum.repos.d/google-chrome.repo - [google-chrome] - name=google-chrome - baseurl=https://dl.google.com/linux/chrome/rpm/stable/x86_64 - enabled=1 - gpgcheck=1 - gpgkey=https://dl.google.com/linux/linux_signing_key.pub - EOF + sudo dd of=/etc/yum.repos.d/google-chrome.repo status=none <