Skip to content

Commit 9506b6a

Browse files
authored
all: use same nix anvil options as in ci (#6119)
1 parent da3ede5 commit 9506b6a

File tree

2 files changed

+22
-1
lines changed

2 files changed

+22
-1
lines changed

flake.nix

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -149,6 +149,9 @@
149149
package = pkgsWithOverlays.foundry-bin;
150150
port = 3021;
151151
timestamp = 1743944919;
152+
gasLimit = 100000000000;
153+
baseFee = 1;
154+
blockTime = 2;
152155
};
153156
};
154157
};

nix/anvil.nix

Lines changed: 19 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,11 +17,29 @@
1717
default = 1743944919;
1818
description = "Timestamp for the genesis block";
1919
};
20+
21+
gasLimit = lib.mkOption {
22+
type = lib.types.int;
23+
default = 100000000000;
24+
description = "Gas limit for the genesis block";
25+
};
26+
27+
baseFee = lib.mkOption {
28+
type = lib.types.int;
29+
default = 1;
30+
description = "Base fee for the genesis block";
31+
};
32+
33+
blockTime = lib.mkOption {
34+
type = lib.types.int;
35+
default = 2;
36+
description = "Block time for the genesis block";
37+
};
2038
};
2139

2240
config = {
2341
outputs.settings.processes.${name} = {
24-
command = "${lib.getExe' config.package "anvil"} --disable-block-gas-limit --disable-code-size-limit --base-fee 1 --block-time 2 --timestamp ${toString config.timestamp} --port ${toString config.port}";
42+
command = "${lib.getExe' config.package "anvil"} --gas-limit ${toString config.gasLimit} --base-fee ${toString config.baseFee} --block-time ${toString config.blockTime} --timestamp ${toString config.timestamp} --port ${toString config.port}";
2543

2644
availability = {
2745
restart = "always";

0 commit comments

Comments
 (0)