You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@airflow.apache.org by GitBox <gi...@apache.org> on 2022/01/21 15:06:26 UTC

[GitHub] [airflow-ci-infra] ashb commented on a change in pull request #48: Sets up proper ownership and permissions for buildx plugin

ashb commented on a change in pull request #48:
URL: https://github.com/apache/airflow-ci-infra/pull/48#discussion_r789735076



##########
File path: github-runner-ami/packer/files/docker-buildx.sh
##########
@@ -26,6 +26,6 @@ fi
 buildx_version="v0.7.1"
 buildx_binary="buildx-${buildx_version}.$(uname -s)-${architecture}"
 plugins_dir="/home/runner/.docker/cli-plugins"
-mkdir -pv "${plugins_dir}"
-curl -L "https://github.com/docker/buildx/releases/download/${buildx_version}/${buildx_binary}" -o "${plugins_dir}/${buildx_binary}"
-chown -R runner:runner "${plugins_dir}"
+sudo -u runner mkdir -pv "${plugins_dir}"
+sudo -u runner curl -L "https://github.com/docker/buildx/releases/download/${buildx_version}/${buildx_binary}" -o "${plugins_dir}/docker-buildx"
+sudo -u runner chmod a+x "${plugins_dir}/docker-buildx"

Review comment:
       `sudo` shouldn't be needed, as these scripts are already run via sudo https://github.com/apache/airflow-ci-infra/blob/31fa88c66307d07cf80f0f8a25c1422590ed67d1/github-runner-ami/packer/ubuntu2004.pkr.hcl#L148




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@airflow.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org