Say I have my live program at account X
and it's upgrade authority is held by A
. How do I transfer the upgrade authority to B
?
3 Answers
Figured it out, I can use the set_upgrade_authority
instruction:
set_upgrade_authority(&X,&A,&B)
-
can you share how to upgrade via Javascript by upgrade authority? I wonder if this work flow viable : developer give a new program so file to a dedicate admin , who then sign upgrade Tx offline and send back to developer to perform upgrade? Commented Mar 2 at 3:51
Using the CLI: solana program set-upgrade-authority --keypair <KEYPAIR_OF_NEW_UPGRADE_AUTHORITY> <PROGRAM_ADDRESS> --new-upgrade-authority <NEW_UPGRADE_AUTHORITY>
If you don't want the new authority to sign the set-upgrade-authority transaction, use this flag: --skip-new-upgrade-authority-signer-check
if you are really confident that you are setting the correct authority.
CLI command: solana program set-upgrade-authority --skip-new-upgrade-authority-signer-check <PROGRAM_ADDRESS> --new-upgrade-authority <NEW_UPGRADE_AUTHORITY>