From 88a8c5764156536efe595b91a11fe6d58bdc73d8 Mon Sep 17 00:00:00 2001 From: Ahmad Husen Date: Sun, 30 May 2021 13:19:29 +0700 Subject: [PATCH] feat(bash): copying files to /tmp instead of chown --- entrypoint.sh | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/entrypoint.sh b/entrypoint.sh index b20c0c0..c5db69d 100755 --- a/entrypoint.sh +++ b/entrypoint.sh @@ -1,11 +1,11 @@ #!/bin/bash # Set path -echo '::group::Configuring path with permission' +echo '::group::Copying $WORKPATH to /tmp/gh-action' WORKPATH=$GITHUB_WORKSPACE/$INPUT_PATH # Set path permision -sudo chown -R builder $WORKPATH -cd $WORKPATH +sudo -u builder cp -rfv $WORKPATH /tmp/gh-action +cd /tmp/gh-action echo '::endgroup::' # Update checksums @@ -37,3 +37,8 @@ if [[ -n "$INPUT_FLAGS" ]]; then sudo -u builder makepkg $INPUT_FLAGS fi echo '::endgroup::' + +echo '::group::Copying /tmp/gh-action to $WORKPATH' +sudo -u builder cp -rfv /tmp/gh-action $WORKPATH +cd $WORKPATH +echo '::endgroup::'