2023-09-12 16:37:30 +00:00
|
|
|
// SPDX-License-Identifier: UNLICENSED
|
2024-11-11 22:30:50 +00:00
|
|
|
pragma solidity >=0.8.27 <=0.9.0;
|
2023-09-12 16:37:30 +00:00
|
|
|
|
|
|
|
import { BaseScript } from "./Base.s.sol";
|
|
|
|
import { DeploymentConfig } from "./DeploymentConfig.s.sol";
|
|
|
|
import { StakeManager } from "../contracts/StakeManager.sol";
|
2023-11-07 08:49:22 +00:00
|
|
|
import { VaultFactory } from "../contracts/VaultFactory.sol";
|
2023-09-12 16:37:30 +00:00
|
|
|
|
|
|
|
contract Deploy is BaseScript {
|
2023-11-07 08:49:22 +00:00
|
|
|
function run() public returns (VaultFactory, StakeManager, DeploymentConfig) {
|
2023-09-12 16:37:30 +00:00
|
|
|
DeploymentConfig deploymentConfig = new DeploymentConfig(broadcaster);
|
2023-10-10 11:53:03 +00:00
|
|
|
(, address token) = deploymentConfig.activeNetworkConfig();
|
2023-09-12 16:37:30 +00:00
|
|
|
|
|
|
|
vm.startBroadcast(broadcaster);
|
2024-11-25 13:31:10 +00:00
|
|
|
StakeManager stakeManager = new StakeManager(token);
|
2023-11-07 08:49:22 +00:00
|
|
|
VaultFactory vaultFactory = new VaultFactory(address(stakeManager));
|
2023-09-12 16:37:30 +00:00
|
|
|
vm.stopBroadcast();
|
|
|
|
|
2023-11-07 08:49:22 +00:00
|
|
|
return (vaultFactory, stakeManager, deploymentConfig);
|
2023-09-12 16:37:30 +00:00
|
|
|
}
|
|
|
|
}
|