2021-05-14 19:16:54 +00:00
|
|
|
require("@nomiclabs/hardhat-waffle");
|
2021-03-15 12:26:22 +00:00
|
|
|
require("@nomiclabs/hardhat-ethers");
|
2021-01-30 12:53:12 +00:00
|
|
|
require("@tenderly/hardhat-tenderly");
|
2021-03-13 14:19:26 +00:00
|
|
|
require("@nomiclabs/hardhat-etherscan");
|
2021-06-25 08:41:09 +00:00
|
|
|
require("@nomiclabs/hardhat-web3");
|
2021-05-14 19:16:54 +00:00
|
|
|
require("hardhat-deploy");
|
|
|
|
require("hardhat-deploy-ethers");
|
2021-06-01 14:50:52 +00:00
|
|
|
require("dotenv").config();
|
2021-01-30 12:53:12 +00:00
|
|
|
|
2021-03-19 20:37:23 +00:00
|
|
|
const { utils } = require("ethers");
|
|
|
|
|
2021-03-15 12:26:22 +00:00
|
|
|
const PRIVATE_KEY = process.env.PRIVATE_KEY;
|
|
|
|
const ALCHEMY_ID = process.env.ALCHEMY_ID;
|
|
|
|
|
2021-06-02 17:13:15 +00:00
|
|
|
if (!process.env.ALCHEMY_ID) {
|
|
|
|
throw new Error("ENV Variable ALCHEMY_ID not set!");
|
|
|
|
}
|
|
|
|
|
2021-01-30 12:53:12 +00:00
|
|
|
/**
|
|
|
|
* @type import('hardhat/config').HardhatUserConfig
|
|
|
|
*/
|
|
|
|
module.exports = {
|
|
|
|
solidity: {
|
|
|
|
compilers: [
|
|
|
|
{
|
2021-06-25 08:41:09 +00:00
|
|
|
version: "0.7.6",
|
2021-06-25 18:35:28 +00:00
|
|
|
settings: {
|
|
|
|
optimizer: {
|
|
|
|
enabled: false,
|
2021-07-13 20:59:35 +00:00
|
|
|
runs: 200,
|
|
|
|
},
|
|
|
|
},
|
2021-01-30 12:53:12 +00:00
|
|
|
},
|
|
|
|
{
|
2021-06-25 08:41:09 +00:00
|
|
|
version: "0.6.0",
|
2021-01-30 12:53:12 +00:00
|
|
|
},
|
|
|
|
{
|
2021-06-25 08:41:09 +00:00
|
|
|
version: "0.6.2",
|
2021-02-05 18:33:49 +00:00
|
|
|
},
|
|
|
|
{
|
2021-06-25 08:41:09 +00:00
|
|
|
version: "0.6.5",
|
2021-06-01 14:50:52 +00:00
|
|
|
},
|
|
|
|
],
|
2021-01-30 12:53:12 +00:00
|
|
|
},
|
2021-02-04 18:09:05 +00:00
|
|
|
networks: {
|
2021-05-14 19:16:54 +00:00
|
|
|
// defaultNetwork: "hardhat",
|
2021-03-15 12:26:22 +00:00
|
|
|
kovan: {
|
|
|
|
url: `https://eth-kovan.alchemyapi.io/v2/${ALCHEMY_ID}`,
|
2021-06-01 14:50:52 +00:00
|
|
|
accounts: [`0x${PRIVATE_KEY}`],
|
2021-02-05 17:07:07 +00:00
|
|
|
},
|
2021-03-19 20:37:23 +00:00
|
|
|
mainnet: {
|
2021-04-07 13:13:37 +00:00
|
|
|
url: `https://eth-mainnet.alchemyapi.io/v2/${ALCHEMY_ID}`,
|
2021-03-15 12:26:22 +00:00
|
|
|
accounts: [`0x${PRIVATE_KEY}`],
|
2021-03-19 20:37:23 +00:00
|
|
|
timeout: 150000,
|
2021-07-13 20:59:35 +00:00
|
|
|
gasPrice: parseInt(utils.parseUnits("30", "gwei")),
|
2021-03-19 20:37:23 +00:00
|
|
|
},
|
|
|
|
hardhat: {
|
|
|
|
forking: {
|
|
|
|
url: `https://eth-mainnet.alchemyapi.io/v2/${ALCHEMY_ID}`,
|
2021-06-24 11:28:01 +00:00
|
|
|
blockNumber: 12696000,
|
2021-03-19 20:37:23 +00:00
|
|
|
},
|
|
|
|
blockGasLimit: 12000000,
|
2021-02-04 18:09:05 +00:00
|
|
|
},
|
2021-04-07 13:13:37 +00:00
|
|
|
matic: {
|
|
|
|
url: "https://rpc-mainnet.maticvigil.com/",
|
|
|
|
accounts: [`0x${PRIVATE_KEY}`],
|
|
|
|
timeout: 150000,
|
2021-06-25 08:41:09 +00:00
|
|
|
gasPrice: parseInt(utils.parseUnits("1", "gwei")),
|
2021-06-01 14:50:52 +00:00
|
|
|
},
|
2021-02-04 18:09:05 +00:00
|
|
|
},
|
2021-01-30 12:53:12 +00:00
|
|
|
etherscan: {
|
2021-06-25 08:41:09 +00:00
|
|
|
apiKey: process.env.ETHERSCAN_API_KEY,
|
2021-02-04 18:09:05 +00:00
|
|
|
},
|
|
|
|
tenderly: {
|
|
|
|
project: process.env.TENDERLY_PROJECT,
|
|
|
|
username: process.env.TENDERLY_USERNAME,
|
2021-06-04 10:47:41 +00:00
|
|
|
},
|
|
|
|
mocha: {
|
2021-06-25 08:41:09 +00:00
|
|
|
timeout: 100 * 1000,
|
2021-06-01 14:50:52 +00:00
|
|
|
},
|
2021-01-30 12:53:12 +00:00
|
|
|
};
|