mirror of
https://github.com/luxfi/bridge.git
synced 2026-09-24 00:26:46 +00:00
update: deployed test tokens
This commit is contained in:
@@ -1,7 +0,0 @@
|
||||
module.exports = [
|
||||
[
|
||||
"0xFa005D52398B4BdAAf73C4e2E3AF8095533D790E", //usdt
|
||||
"0x42449554b0c7D85EbD488e14D7D48c6A78D3F9Be", //usdc
|
||||
"0xc16ECFE3cB80e142d7110b97a442d4caAA203ABf", //dai
|
||||
]
|
||||
];
|
||||
@@ -0,0 +1,7 @@
|
||||
module.exports = [
|
||||
[
|
||||
"0x46390FA219b22f739C63F0bF1c165a1FBc30B57c", //usdt
|
||||
"0xE49355609F94A4B8a2EfC6FBd077542F8EC90080", //usdc
|
||||
"0x568BF299E115D78a1fBa57BafdAe0fD8A26BFb7e", //dai
|
||||
]
|
||||
];
|
||||
@@ -0,0 +1,7 @@
|
||||
module.exports = [
|
||||
[
|
||||
"0x5519582dde6eb1f53F92298622c2ecb39A64369A", //usdt
|
||||
"0x6a49DbeD52B9Bd9a53E21C3bCb67dc2697cD6697", //usdc
|
||||
"0x2E8A24dE21105772FD161BF56471A0470A8AF45e", //dai
|
||||
]
|
||||
];
|
||||
@@ -159,11 +159,11 @@ contract Bridge is Ownable, AccessControl {
|
||||
|
||||
/**
|
||||
* @dev set vault address for teleport bridge
|
||||
* @param to_ new vault address
|
||||
* @param vault_ new vault address
|
||||
*/
|
||||
function setVault(address payable to_) public onlyAdmin {
|
||||
require(to_ != address(0), "Invalid address");
|
||||
vault = LuxVault(to_);
|
||||
function setVault(address payable vault_) public onlyAdmin {
|
||||
require(vault_ != address(0), "Invalid address");
|
||||
vault = LuxVault(vault_);
|
||||
}
|
||||
|
||||
function addNewERC20Vault(address _asset) public onlyAdmin {
|
||||
|
||||
@@ -8,6 +8,7 @@ dotenv.config();
|
||||
const PRIVATE_KEY: string = process.env.PRIVATE_KEY!;
|
||||
const SEPOLIA_RPC: string = process.env.SEPOLIA_RPC!;
|
||||
const BASE_RPC: string = process.env.BASE_RPC!;
|
||||
const BASE_SEPOLIA_RPC: string = process.env.BASE_SEPOLIA_RPC!;
|
||||
const BSC_TESTNET_RPC: string = process.env.BSC_TESTNET_RPC!;
|
||||
const LUX_MAINNET_RPC: string = process.env.LUX_MAINNET_RPC!;
|
||||
const LUX_TESTNET_RPC: string = process.env.LUX_TESTNET_RPC!;
|
||||
@@ -19,10 +20,14 @@ const config: HardhatUserConfig = {
|
||||
url: SEPOLIA_RPC,
|
||||
accounts: [`0x${PRIVATE_KEY}`],
|
||||
},
|
||||
bsc_testnet: {
|
||||
bscTestnet: {
|
||||
url: BSC_TESTNET_RPC,
|
||||
accounts: [`0x${PRIVATE_KEY}`],
|
||||
},
|
||||
baseTestnet: {
|
||||
url: BASE_SEPOLIA_RPC,
|
||||
accounts: [`0x${PRIVATE_KEY}`],
|
||||
},
|
||||
base: {
|
||||
url: BASE_RPC,
|
||||
accounts: [`0x${PRIVATE_KEY}`],
|
||||
@@ -31,7 +36,7 @@ const config: HardhatUserConfig = {
|
||||
url: LUX_MAINNET_RPC,
|
||||
accounts: [`0x${PRIVATE_KEY}`],
|
||||
},
|
||||
"lux-test": {
|
||||
luxTestnet: {
|
||||
url: LUX_TESTNET_RPC,
|
||||
accounts: [`0x${PRIVATE_KEY}`]
|
||||
}
|
||||
@@ -41,8 +46,9 @@ const config: HardhatUserConfig = {
|
||||
sepolia: process.env.ETHERSCAN_API_KEY!,
|
||||
bsc: process.env.BSCSCAN_API_KEY!,
|
||||
bscTestnet: process.env.BSCSCAN_API_KEY!,
|
||||
baseSepolia: process.env.BASESCAN_API_KEY!,
|
||||
lux: "your API key", // Leave empty if not applicable
|
||||
"lux-test": "your API key" // Leave empty if not applicable
|
||||
luxTestnet: "your API key" // Leave empty if not applicable
|
||||
},
|
||||
customChains: [
|
||||
{
|
||||
@@ -54,7 +60,7 @@ const config: HardhatUserConfig = {
|
||||
}
|
||||
},
|
||||
{
|
||||
network: "lux-test",
|
||||
network: "luxTestnet",
|
||||
chainId: 8888,
|
||||
urls: {
|
||||
apiURL: "https://api.explore.lux-test.network/api",
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
import { ethers } from "hardhat";
|
||||
|
||||
async function main() {
|
||||
const [deployer] = await ethers.getSigners();
|
||||
|
||||
/////Bridge
|
||||
const _signer = await ethers.getContractFactory("Bridge");
|
||||
const token = await _signer.deploy();
|
||||
console.log("Bridge address:", await token.getAddress());
|
||||
const _bridge = await _signer.deploy();
|
||||
console.log("Bridge address on BaseTestnet:", await _bridge.getAddress());
|
||||
}
|
||||
|
||||
main()
|
||||
@@ -0,0 +1,25 @@
|
||||
import { ethers } from "hardhat";
|
||||
|
||||
async function main() {
|
||||
const [deployer] = await ethers.getSigners();
|
||||
|
||||
|
||||
/////LuxVault
|
||||
const assets = [
|
||||
"0x46390FA219b22f739C63F0bF1c165a1FBc30B57c", //usdt
|
||||
"0xE49355609F94A4B8a2EfC6FBd077542F8EC90080", //usdc
|
||||
"0x568BF299E115D78a1fBa57BafdAe0fD8A26BFb7e", //dai
|
||||
]
|
||||
|
||||
const _signer = await ethers.getContractFactory("LuxVault");
|
||||
const _vault = await _signer.deploy(assets);
|
||||
await _vault.waitForDeployment();
|
||||
console.log("LuxVault baseTestnet address:", await _vault.getAddress());
|
||||
}
|
||||
|
||||
main()
|
||||
.then(() => process.exit(0))
|
||||
.catch((error) => {
|
||||
console.error(error);
|
||||
process.exit(1);
|
||||
});
|
||||
@@ -6,15 +6,15 @@ async function main() {
|
||||
|
||||
/////LuxVault
|
||||
const assets = [
|
||||
"0xFa005D52398B4BdAAf73C4e2E3AF8095533D790E", //usdt
|
||||
"0x42449554b0c7D85EbD488e14D7D48c6A78D3F9Be", //usdc
|
||||
"0xc16ECFE3cB80e142d7110b97a442d4caAA203ABf", //dai
|
||||
"0x5519582dde6eb1f53F92298622c2ecb39A64369A", //usdt
|
||||
"0x6a49DbeD52B9Bd9a53E21C3bCb67dc2697cD6697", //usdc
|
||||
"0x2E8A24dE21105772FD161BF56471A0470A8AF45e", //dai
|
||||
]
|
||||
|
||||
const _signer = await ethers.getContractFactory("LuxVault");
|
||||
const token = await _signer.deploy(assets);
|
||||
await token.waitForDeployment();
|
||||
console.log("LuxVault sepolia address:", await token.getAddress());
|
||||
const _vault = await _signer.deploy(assets);
|
||||
await _vault.waitForDeployment();
|
||||
console.log("LuxVault bscTestnet address:", await _vault.getAddress());
|
||||
}
|
||||
|
||||
main()
|
||||
@@ -0,0 +1,22 @@
|
||||
import { ethers } from "hardhat";
|
||||
|
||||
async function main() {
|
||||
const [deployer] = await ethers.getSigners();
|
||||
|
||||
|
||||
/////LuxVault
|
||||
const assets = [] as any[]
|
||||
|
||||
|
||||
const _signer = await ethers.getContractFactory("LuxVault");
|
||||
const _vault = await _signer.deploy(assets);
|
||||
await _vault.waitForDeployment();
|
||||
console.log("LuxVault address on luxTestnet:", await _vault.getAddress());
|
||||
}
|
||||
|
||||
main()
|
||||
.then(() => process.exit(0))
|
||||
.catch((error) => {
|
||||
console.error(error);
|
||||
process.exit(1);
|
||||
});
|
||||
Reference in New Issue
Block a user