|
| 1 | +name: Accept Admin Role Transfer - Safe |
| 2 | + |
| 3 | +on: |
| 4 | + workflow_dispatch: |
| 5 | + inputs: |
| 6 | + network: |
| 7 | + description: 'Network to accept admin role on' |
| 8 | + required: true |
| 9 | + type: choice |
| 10 | + options: |
| 11 | + - ethereum |
| 12 | + - arbitrum |
| 13 | + - sepolia |
| 14 | + - arbitrum_sepolia |
| 15 | + default: sepolia |
| 16 | + |
| 17 | +jobs: |
| 18 | + transfer-admin-role: |
| 19 | + runs-on: ubuntu-latest |
| 20 | + environment: |
| 21 | + name: ${{ inputs.network }} |
| 22 | + |
| 23 | + steps: |
| 24 | + - name: Checkout |
| 25 | + uses: actions/checkout@v4 |
| 26 | + |
| 27 | + - name: Execute Transfer Admin Role |
| 28 | + id: transfer-admin |
| 29 | + uses: iExecBlockchainComputing/safe-tx-proposer@feature/wrap-it-gha |
| 30 | + with: |
| 31 | + safe-address: ${{ secrets.SAFE_ADDRESS }} |
| 32 | + safe-api-key: ${{ secrets.SAFE_API_KEY }} |
| 33 | + rpc-url: ${{ secrets.RPC_URL }} |
| 34 | + proposer-private-key: ${{ secrets.PROPOSER_PRIVATE_KEY }} |
| 35 | + foundry-script-path: 'script/TransferAdminRole.s.sol:AcceptAdminRole' |
| 36 | + env: |
| 37 | + CHAIN: ${{ inputs.network }} |
| 38 | + |
| 39 | + # - name: Display Results |
| 40 | + # run: | |
| 41 | + # echo "Operation Status: ${{ steps.transfer-admin.outputs.status }}" |
| 42 | + # echo "Transaction Count: ${{ steps.transfer-admin.outputs.transaction-count }}" |
| 43 | + |
| 44 | + # if [[ "${{ inputs.action-mode }}" == "propose" ]]; then |
| 45 | + # echo "Transaction Hash: ${{ steps.transfer-admin.outputs.transaction-hash }}" |
| 46 | + # echo "All Transaction Hashes: ${{ steps.transfer-admin.outputs.transaction-hashes }}" |
| 47 | + # echo "✅ Admin role transfer transaction has been proposed to the Safe multisig" |
| 48 | + # echo "📋 Please review and approve the transaction in the Safe interface" |
| 49 | + # elif [[ "${{ inputs.action-mode }}" == "list-pending" ]]; then |
| 50 | + # echo "Pending Transactions:" |
| 51 | + # echo '${{ steps.transfer-admin.outputs.pending-transactions }}' | jq '.' |
| 52 | + # fi |
| 53 | + |
| 54 | + # - name: Summary |
| 55 | + # run: | |
| 56 | + # echo "## Transfer Admin Role Summary" >> $GITHUB_STEP_SUMMARY |
| 57 | + # echo "- **Safe Address**: ${{ inputs.safe-address }}" >> $GITHUB_STEP_SUMMARY |
| 58 | + # echo "- **Chain**: ${{ inputs.chain }}" >> $GITHUB_STEP_SUMMARY |
| 59 | + # echo "- **Script**: ${{ inputs.script-path }}" >> $GITHUB_STEP_SUMMARY |
| 60 | + # echo "- **Mode**: ${{ inputs.action-mode }}" >> $GITHUB_STEP_SUMMARY |
| 61 | + # echo "- **Status**: ${{ steps.transfer-admin.outputs.status }}" >> $GITHUB_STEP_SUMMARY |
| 62 | + # echo "- **Transaction Count**: ${{ steps.transfer-admin.outputs.transaction-count }}" >> $GITHUB_STEP_SUMMARY |
| 63 | + |
| 64 | + # if [[ "${{ inputs.action-mode }}" == "propose" ]]; then |
| 65 | + # echo "- **Transaction Hash**: ${{ steps.transfer-admin.outputs.transaction-hash }}" >> $GITHUB_STEP_SUMMARY |
| 66 | + # fi |
0 commit comments