How can I write upgrade script by using foundry upgradeable package?

Can I pass parameter to run() function?
When I want to upgrade a contract, I think we need to pass proxy address.
How can I do that? I'm not sure below code block is working or not

:1234: Code to reproduce

contract DeployScript is Script {
    function setUp() public {}

    function run() public returns (address proxy, address implementation) {
        uint256 deployerPrivateKey = vm.envUint("PRIVATE_KEY");
        vm.startBroadcast(deployerPrivateKey);
        proxy = Upgrades.deployUUPSProxy("MyContract.sol", abi.encodeCall(MyContract.initialize, ()));
        implementation = Upgrades.getImplementationAddress(proxy);
        vm.stopBroadcast();
    }
}

contract UpgradeScript is Script {
    function setUp() public {}

    function run(address proxy) returns (address proxy, address newImplementation) {
        uint256 deployerPrivateKey = vm.envUint("PRIVATE_KEY");
        vm.startBroadcast(deployerPrivateKey);
        Upgrades.upgradeProxy(proxy, "MyContractV2", MyContractV2.initialize);
        newImplementation = Upgrades.getImplementationAddress(proxy);
        vm.stopBroadcast();
    }
}

:computer: Environment

You can pass in parameters from forge script, see Foundry docs at https://book.getfoundry.sh/reference/forge/forge-script

Or you could use a constant or environment variable.