diff --git a/power-on/action.yml b/power-on/action.yml index 16a5d88..e5a7908 100644 --- a/power-on/action.yml +++ b/power-on/action.yml @@ -1,29 +1,18 @@ - repository: - name: publishing - runs-on: [self-hosted, Linux, local] - if: ${{ github.repository_owner == 'Armbian' }} - steps: +name: "Runner prepare" +author: "Igor Pecovnik" +description: "Cleaning self hosted runners" +runs: + using: "composite" + steps: - - name: Remove previous artefacts if any - run: | - sudo rm -rf changes 2>/dev/null || true - - name: Download changes - uses: actions/download-artifact@v3 - with: - name: changes + - name: Install SSH key for repository + uses: shimataro/ssh-key-action@v2 + with: + key: ${{ secrets.KEY_POWER_ON }} + name: ${{ inputs.KEY_ID }} + known_hosts: ${{ secrets.KNOWN_HOSTS_REPOSITORY }} + if_key_exists: replace - - name: Check - run: | - [ -s changes ] || echo "SKIP=yes" >> $GITHUB_ENV - - name: Install SSH key for repository - if: ${{ github.repository_owner == 'Armbian' && env.SKIP != 'yes' }} - uses: shimataro/ssh-key-action@v2 - with: - key: ${{ secrets.KEY_REPOSITORY }} - name: ${{ inputs.KEY_ID }} - known_hosts: ${{ secrets.KNOWN_HOSTS_REPOSITORY }} - if_key_exists: replace - - - name: Update repository - if: ${{ github.repository_owner == 'Armbian' && env.SKIP != 'yes' }} - run: ssh -T -i ~/.ssh/${{ inputs.KEY_ID }} ${{ secrets.USER_REPOSITORY }}@${{ secrets.HOST_REPOSITORY }} + - name: Update repository + if: ${{ github.repository_owner == 'Armbian' && env.SKIP != 'yes' }} + run: ssh -T -i ~/.ssh/${{ inputs.KEY_ID }} ${{ secrets.USER_REPOSITORY }}@${{ secrets.HOST_REPOSITORY }}