bitpro가 원문에서 글자만 모은 내용이에요. 표·그림·수식은 빠지거나 깨질 수 있어요. 전체 23쪽 중 8쪽
TITY_VALUE=/gravity/config/identity.yaml
export SAFETY_RULES_IDENTITY_VARIANT=from_file
export SAFETY_RULES_IDENTITY_KEY=identity_blob_path
export SAFETY_RULES_IDENTITY_VALUE=/gravity/config/identity.yaml
export DISCOVERY_METHOD_FULLNODE_BLOCK=''
export PFN_SEEDS_BLOCK=' seeds:
"0xe7ddaced105af1c4381ca670cea01b0a8e3006c7e360a4f4e40e79fe06c29433":
addresses:
- "/dns/testnet-rpc-p2p-1.gravity.xyz/tcp/6195/noise-ik/86d3bd6c81fb6994bdbe8df40da28acf44433138cb09ad491c4d98637abd817a/handshake/0"
role: PreferredUpstream'
envsubst < ../../cluster/templates/public_full_node.yaml.tpl \
> config/public_full_node.yaml
envsubst < ../../cluster/templates/reth_config_pfn_prune.json.tpl \
> config/reth_config.json
```
If you do not want transaction-lookup pruning, do not set `PRUNE_TRANSACTIONLOOKUP_DISTANCE`, and render `reth_config.json` from the non-prune template instead:
```bash
envsubst < ../../cluster/templates/reth_config_pfn.json.tpl \
> config/reth_config.json
```
Verify the rendered config:
```bash
jq . config/reth_config.json >/dev/null
grep -n 'public_full_node.yaml\|prune.transactionlookup.distance\|gravity/config\|gravity/data' \
config/reth_config.json
grep -n 'PreferredUpstream\|testnet-rpc-p2p-1.gravity.xyz\|/gravity/config/identity.yaml' \
config/public_full_node.yaml
```
Expected `reth_config.json` behavior:
* `chain` points to `/gravity/config/genesis.json`;
* `gravity_node_config` points to `/gravity/config/public_full_node.yaml`;
* `datadir` points to `/gravity/data/data/reth`;
* `log.file.directory` points to `/gravity/logs/execution_logs/`;
* when pruning is enabled, `prune.transactionlookup.distance` is `10064`.
## 7. Pruning Mode
`prune_transactionlookup_distance = 10064` starts reth with transaction-lookup pruning enabled. This keeps recent transaction-hash lookup data while allowing older lookup indexes to be pruned.
Use a value **greater than or equal to `10064`** for production-like PFN/RPC nodes. Treat smaller values as test-only and reject them during config review.
Use this pruning mode when you want lower execution database growth and do not need arbitrary old `eth_getTransactionByHash` lookups from this node.
If you omit `prune_transactionlookup_distance`, the generated PFN reth config uses archive-style transaction lookup behavior and keeps historical lookup indexes instead of pruning them. That is simpler for indexers or debugging flows that need old transaction hashes, but it uses more disk over time.
Do not set `prune_transactionlookup_distance = 0` to disable pruning. A distance of `0` is still a pruning mode and can prune transaction lookup data aggressively. To run without transaction-lookup pruning, leave the field out.
## 8. Optional: Warm Start From a Snapshot or Existing Node
A new Docker PFN can sync from genesis, but that may take a long time on an established testnet. To warm start, load the snapshot into the Docker data volume **before the first node start**.
If the Docker PFN has already started once, stop the container and remove the old data volume before importing a snapshot. Do not merge snapshot files into an already-initialized database.
The Docker container mounts its data volume at `/gravity/data`. The chain databases must live under `/gravity/data/data`, so extract snapshot contents into that `data` subdirectory.
### Option A: Download the Public Testnet Data Snapshot
Gravity publishes a public Longevity Testnet PFN data snapshot at a stable URL. Download the current `latest` cut to your node host (the file is large; resume is supported):
```bash
curl -L --fail --continue-at - \
"https://gravity-snapshots.b-cdn.net/gravity-testnet-data/latest.tar" \
-o /tmp/gravity-testnet-latest.tar
```
The snapshot is a point-in-time cut. After start, the node syncs forward to the chain tip.
The snapshot tar contains database directories such as `consensus_db/`, `quorumstoreDB/`, and `reth/` at the archive root. It does not contain an outer `data/` directory.
For the Linux compose flow, load the snapshot into the compose data volume:
```bash
docker compose run --rm --no-deps \
--user root \
--entrypoint sh \
-v /tmp:/snapshot:ro \
gravity_node \
-lc 'mkdir -p /gravity/data/data && \
tar -xf /snapshot/gravity-testnet-latest.tar -C /gravity/data/data && \
chown -R 10001:10001 /gravity/data /gravity/logs'
```
For the macOS `docker run` flow, load the snapshot into the explicit named volume used by the start command below:
```bash
set -a
. ./.env
set +a
docker volume create gravity_node_testnet_pfn_data
docker volume create gravity_node_testnet_pfn_logs
docker run --rm \
--user root \
--entrypoint sh \
-v gravity_node_testnet_pfn_data:/gravity/data \
-v gravity_node_testnet_pfn_logs:/gravity/logs \
-v /tmp:/snapshot:ro \
${GRAVITY_IMAGE}:${IMAGE_TAG} \
-lc 'mkdir -p /gravity/data/data && \
tar -xf /snapshot/gravity-testnet-latest.tar -C /gravity/data/data && \
chown -R 10001:10001 /gravity/data /gravity/logs'
```
After extraction, the Docker data volume should contain:
```
/gravity/data/data/consensus_db/
/gravity/data/data/quorumstoreDB/
/gravity/data/data/reth/
```
### Option B: Copy From an Existing Node You Control
If you already run a trusted RPC/PFN, you can copy only the chain databases from that node:
```bash
cd <YOUR_EXISTING_NODE_DATA_DIR>
tar -cf /tmp/testnet-pfn-data.tar consensus_db quorumstoreDB reth
```
Then load `/tmp/testnet-pfn-data.tar` into the Docker data volume with the same compose or `docker run` extraction pattern above. Mount `/tmp` as `/snapshot` and replace the extraction command with:
```bash
tar -xf /snapshot/testnet-pfn-data.tar -C /gravity/data/data
```
Do **not** copy `rand_db` or `secure_storage.json` from another node. Those files carry node-specific randomness or safety state and should not be reused.
## 9. Start the PFN
Make sure the selected host ports are free:
```bash
lsof -nP -iTCP:26195 -iTCP:28545 -iTCP:29001 -iTCP:30001 -iTCP:28661 -iTCP:32024
```
On Linux, use Docker Compose:
```bash
docker compose up -d
docker ps --filter name=gravity_node
```
The compose file uses `network_mode: host` because p2p ports need predictable advertised addresses.
On Docker Desktop for macOS, host networking behaves differently. For local validation from the macOS host, use explicit port publishing:
```bash
docker rm -f gravity_node 2>/dev/null || true
set -a
. ./.env
set +a
docker run -d --name gravity_node --restart unless-stopped \
-p 26195:26195 \
-p 28545:28545 \
-p 29001:29001 \
-p 30001:30001 \
-p 28661:28661 \
-p 32024:32024 \
-v "$(pwd)/config:/gravity/config:ro" \
-v gravity_node_testnet_pfn_data:/gravity/data \
-v gravity_node_testnet_pfn_logs:/gravity/logs \
-e RUST_BACKTRACE=1 \
-e RUST_LOG=info \
--ulimit nofile=1048576:1048576 \
${GRAVITY_IMAGE}:${IMAGE_TAG}
```
## 10. Verify Sync
Confirm that your local Docker PFN is on the testnet chain:
```bash
curl -s --noproxy '*' http://127.0.0.1:28545 \
-H 'content-type: application/json' \
-d '{"jsonrpc":"2.0","method":"eth_chainId","params":[],"id":1}' | jq -r .result
```
The expected result is `0x7695e9`, which is decimal `7771625`.
Query the local Docker PFN:
```bash
curl -s --noproxy '*' http://127.0.0.1:28545 \
-H 'content-type: application/json' \
-d '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}' | jq -r .result
```
Compare with the public RPC:
```bash
curl -s --noproxy '*' https://testnet-rpc.gravity.xyz \
-H 'content-type: application/json' \
-d '{"jsonrpc":"2.0","method":"eth_blockNumber","params":[],"id":1}' | jq -r .result
```
When the two heights are close and your local height keeps advancing, the node is caught up. Gravity has BFT-final blocks: once a block is returned by your node, there is no EVM-style reorg to wait for.
Follow logs:
```bash
docker logs gravity_node -f
docker exec gravity_node sh -lc \
'tail -n 200 /gravity/logs/execution_logs/*/reth.log'
docker exec gravity_node sh -lc \
'tail -n 200 /gravity/logs/consensus_log/vfn.log'
```
Confirm the prune config was accepted:
```bash
docker exec gravity_node sh -lc \
'grep -R "Pruner initialized\\|prune_config\\|transaction_lookup" /gravity/logs/execution_logs || true'
```
## 11. Stop, Restart, or Reset
For the Linux compose flow, stop the container but keep chain data:
```bash
docker compose down
```
Restart:
```bash
docker compose up -d
```
Delete the local PFN database and start from zero again:
```bash
docker compose down -v
```
For the macOS `docker run` flow, stop the container but keep chain data:
```bash
docker rm -f gravity_node
```
Delete the local PFN database and start from zero again:
```bash
docker rm -f gravity_node
docker volume rm gravity_node_testnet_pfn_data gravity_node_testnet_pfn_logs
```
Only remove Docker volumes when you intentionally want to delete the node database.
## Files to Keep Out of Version Control
Do not commit generated runtime files:
* `docker/gravity_node/.env`;
* `docker/gravity_node/config/*`;
* `cluster/output/<YOUR_NODE_ID>/config/identity.yaml`;
* Docker volumes such as `gravity-data`, `gravity-logs`, `gravity_node_testnet_pfn_data`, and `gravity_node_testnet_pfn_logs`;
* node databases and logs.
The reusable materials are the public guide and SDK templates. Each operator should generate their own identity and runtime config.
## See Also
* [Gravity Longevity Testnet (L1)](/gravity-networks/l1-longevity-testnet)
* [Gravity Longevity Testnet Hardforks](/gravity-networks/testnet-hardforks)
* [Run a Gravity Testnet Public Full Node](/gravity-networks/run-a-testnet-pfn)
* [Run a Gravity Mainnet Public Full Node With Docker](/gravity-networks/run-a-mainnet-pfn-with-docker)
* [Node Providers](/ecosystem-infrastructures/node-providers)
# Deployed Contracts
Canonical EVM ecosystem preinstall contracts on Gravity Mainnet (L1).
Gravity L1 ships the standard EVM ecosystem contracts at their **universal cross-chain addresses** — the same addresses they occupy on Ethereum, Base, Arbitrum, and most other EVM chains. Because tooling (viem, ethers, wagmi, Foundry, wallet SDKs, ERC-4337 bundlers, Safe UI, …) hardcodes these addresses, any dapp that relies on them works on Gravity with **zero per-chain configuration**.
{% hint style="info" %}
These are the standard, audited ecosystem deployments — distinct from Gravity's own **system runtime contracts** in the `0x1625Fxxxx` range. For those, see [System Contracts](/developer-resources/mainnet).
{% endhint %}
## Deployer factories (L1, chain ID `127001`)
| Contract | Address | Role |
| --------------------------------------- | -------------------------------------------- | --------------------------------------------------- |
| Arachnid Deterministic Deployment Proxy | `0x4e59b44847b379578588920cA78FbF26c0B4956C` | `CREATE2` deployer factory |
| CreateX | `0xba5Ed099633D3B313e4D5F7bdc1305d3c28ba5Ed` | `CREATE2` / `CREATE3` deployer factory |
| Safe Singleton Factory | `0x914d7Fec6aaC8cd542e72Bca78B30650d45643d7` | `CREATE2` deployer factory (used by the Safe suite) |
## Core infrastructure
| Contract | Address | Role |
| -------------- | -------------------------------------------- | --------------------------------------- |
| Multicall3 | `0xcA11bde05977b3631167028862bE2a173976CA11` | Batched reads/writes in a single call |
| Permit2 | `0x000000000022D473030F116dDEE9F6B43aC78BA3` | Uniswap signature-based token approvals |
| Wrapped G (wG) | `0xBB859E225ac8Fb6BE1C7e38D87b767e95Fef0EbD` | ERC-20 wrapper for native G |
## ERC-4337 account abstraction
| Contract | Address | Role |
| ------------------ | -------------------------------------------- | --------------------------------------------- |
| EntryPoint v0.6 | `0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789` | Account-abstraction entrypoint |
| SenderCreator v0.6 | `0x7fc98430eAEdbb6070B35B39D798725049088348` | EntryPoint v0.6 account-deployment helper |
| EntryPoint v0.7 | `0x0000000071727De22E5E9d8BAf0edAc6f37da032` | Account-abstraction entrypoint |
| SenderCreator v0.7 | `0xEFC2c1444eBCC4Db75e7613d20C6a62fF67A167C` | EntryPoint v0.7 account-deployment helper |
| EntryPoint v0.8 | `0x4337084D9E255Ff0702461CF8895CE9E3b5Ff108` | Account-abstraction entrypoint (EIP-7702 era) |
All three EntryPoint versions are live, so bundlers, paymasters, and smart-wallet SDKs work on Gravity regardless of which version they target.
## Safe{Wallet} smart-account suite (v1.4.1)
The full canonical [Safe](https://safe.global) contract suite is deployed at its universal addresses, so the Safe SDK / Transaction Service and any Safe-based tooling work on Gravity.
| Contract | Address | Role |
| ---------------------------- | -------------------------------------------- | ---------------------------------------------------- |
| Safe (L1 singleton) | `0x41675C099F32341bf84BFc5382aF534df5C7461a` | Safe master copy (mainnet-style) |
| SafeL2 (L2 singleton) | `0x29fcB43b46531BcA003ddC8FCB67FFE91900C762` | Safe master copy emitting events for indexers |
| SafeProxyFactory | `0x4e1DCf7AD4e460CfD30791CCC4F9c8a4f820ec67` | Deploys Safe proxies (`createProxyWithNonce`) |
| CompatibilityFallbackHandler | `0xfd0732Dc9E303f09fCEf3a7388Ad10A83459Ec99` | Default fallback handler (EIP-1271, token receivers) |
| MultiSend | `0x38869bf66a61cF6bDB996A6aE40D5853Fd43B526` | Batch multiple calls in one Safe tx |
| MultiSendCallOnly | `0x9641d764fc13c8B624c04430C7356C1C7C8102e2` | Batch `CALL`-only txs (no delegatecall) |
| CreateCall | `0x9b35Af71d77eaf8d7e40252370304687390A1A52` | Deploy contracts from within a Safe |
| SignMessageLib | `0xd53cd0aB83D845Ac265BE939c57F53AD838012c9` | On-chain EIP-1271 message signing |
| SimulateTxAccessor | `0x3d4BA2E0884aa488718476ca2FB8Efc291A46199` | `staticcall` tx simulation |
{% hint style="info" %}
On Gravity, point Safe proxies at the **SafeL2** singleton (`0x29fc…0C762`) rather than the L1 `Safe` — the L2 variant emits the events the Safe Transaction Service and indexers rely on (the L1 singleton is the mainnet/gas-optimised variant).
{% endhint %}
## Bridged asset tokens
Canonical bridged representations of the major assets, deployed deterministically (CREATE2 via CreateX) by the Gravity operator on 2026-08-11. USDC.e follows [Circle's Bridged USDC Standard](https://www.circle.com/bridged-usdc) (upgrade path to native USDC); USDT.e and WETH.e are Chainlink `BurnMintERC20` tokens (burn/mint RBAC, CCIP-ready).
{% hint style="warning" %}
**Deployed, but not yet usable.** The bridge wire-up with the partner team (Chainlink) is still in progress: total supply of all three tokens is 0, no mint/burn roles are configured, and there is no bridge route in or out. Until the handover completes, do **not** integrate these tokens as live assets, list them as usable in wallets or UIs, or provide liquidity against them — any pre-handover "liquidity" in them is unbacked. The addresses below are published so integrators can prepare.
{% endhint %}
| Token | Address | Decimals | Standard |
| ------------------------------- | -------------------------------------------- | -------- | ----------------------------- |
| USDC.e — Bridged USDC (Gravity) | `0x979c024b381E25a093b8B4CEb06e74B8140664ff` | 6 | Circle FiatToken v2.2 (proxy) |
| USDT.e — Bridged USDT (Gravity) | `0x06Fd3e67231baea179676c490482372F7Fb4A3f2` | 6 | Chainlink BurnMintERC20 |
| WETH.e — Bridged WETH (Gravity) | `0x9Da9C5b2CBf7dcC773071338A6480e0E5FDee177` | 18 | Chainlink BurnMintERC20 |
Supporting contracts for USDC.e: implementation `0xc4092FcAFB2D2B6367b25E2e2e2d8F306402bcBE`, MasterMinter `0x71C045E9A23dFAAA11828b4582cbBDafDca21B8a`, SignatureChecker library `0xFe6f85f6111DB61D04de45bd2c9E0EA56F309e4e`.
## Verify before you hardcode
Confirm an address has code before relying on it:
```bash
cast code 0xcA11bde05977b3631167028862bE2a173976CA11 --rpc-url https://mainnet-rpc.gravity.xyz
```
A non-empty result means the contract is live; an empty `0x` means it is not deployed yet.
## See also
* [System Contracts](/developer-resources/mainnet) — Gravity's system runtime and bridge contracts (`0x1625Fxxxx`).
* [Token Contracts on Gravity](/the-g-token/token-contracts) — canonical ERC-20 list (G, wG, USDT, …).
* [Gravity Skill](/developer-resources/gravity-skill) — the agent skill that bundles these addresses for AI coding tools.
* [Gravity Mainnet (L1)](/gravity-networks/l1-mainnet) — network connection parameters.
# Deployed Contracts (Testnet)
Canonical EVM ecosystem preinstall contracts on the Gravity Longevity Testnet (L1).
The Gravity Longevity Testnet (L1, Chain ID `7771625`) ships the same standard EVM ecosystem contracts as mainnet, at their **universal cross-chain addresses** — the same addresses they occupy on Ethereum, Base, Arbitrum, Gravity Mainnet, and most other EVM chains. Because tooling (viem, ethers, wagmi, Foundry, wallet SDKs, ERC-4337 bundlers, Safe UI, …) hardcodes these addresses, any dapp that relies on them works on the testnet with **zero per-chain configuration**.
{% hint style="info" %}
These are the standard, audited ecosystem deployments — distinct from Gravity's own **system runtime contracts** in the `0x1625Fxxxx` range. Addresses match [Gravity Mainnet (L1)](/developer-resources/deployed-contracts). Prefer a quick `cast code` check before hardcoding (see [Verify before you hardcode](#verify-before-you-hardcode)).
{% endhint %}
## Deployer factories (L1, chain ID `7771625`)
| Contract | Address | Role |
| --------------------------------------- | -------------------------------------------- | --------------------------------------------------- |
| Arachnid Deterministic Deployment Proxy | `0x4e59b44847b379578588920cA78FbF26c0B4956C` | `CREATE2` deployer factory |
| CreateX | `0xba5Ed099633D3B313e4D5F7bdc1305d3c28ba5Ed` | `CREATE2` / `CREATE3` deployer factory |
| Safe Singleton Factory | `0x914d7Fec6aaC8cd542e72Bca78B30650d45643d7` | `CREATE2` deployer factory (used by the Safe suite) |
## Core infrastructure
| Contract | Address | Role |
| -------------- | -------------------------------------------- | --------------------------------------- |
| Multicall3 | `0xcA11bde05977b3631167028862bE2a173976CA11` | Batched reads/writes in a single call |
| Permit2 | `0x000000000022D473030F116dDEE9F6B43aC78BA3` | Uniswap signature-based token approvals |
| Wrapped G (wG) | `0xBB859E225ac8Fb6BE1C7e38D87b767e95Fef0EbD` | ERC-20 wrapper for native G |
## ERC-4337 account abstraction
| Contract | Address | Role |
| ------------------ | -------------------------------------------- | --------------------------------------------- |
| EntryPoint v0.6 | `0x5FF137D4b0FDCD49DcA30c7CF57E578a026d2789` | Account-abstraction entrypoint |
| SenderCreator v0.6 | `0x7fc98430eAEdbb6070B35B39D798725049088348` | EntryPoint v0.6 account-deployment helper |
| EntryPoint v0.7 | `0x0000000071727De22E5E9d8BAf0edAc6f37da032` | Account-abstraction entrypoint |
| SenderCreator v0.7 | `0xEFC2c1444eBCC4Db75e7613d20C6a62fF67A167C` | EntryPoint v0.7 account-deployment helper |
| EntryPoint v0.8 | `0x4337084D9E255Ff0702461CF8895CE9E3b5Ff108` | Account-abstraction entrypoint (EIP-7702 era) |
## Safe{Wallet} smart-account suite (v1.4.1)
The full canonical [Safe](https://safe.global) contract suite is deployed on the Longevity Testnet at the same universal addresses as [mainnet](/developer-resources/deployed-contracts#safe-wallet-smart-account-suite-v1-4-1). Safe SDK / Foundry / cast workflows that target these addresses work without per-chain overrides.
| Contract | Address | Role |
| ---------------------------- | -------------------------------------------- | ---------------------------------------------------- |
| Safe (L1 singleton) | `0x41675C099F32341bf84BFc5382aF534df5C7461a` | Safe master copy (mainnet-style) |
| SafeL2 (L2 singleton) | `0x29fcB43b46531BcA003ddC8FCB67FFE91900C762` | Safe master copy emitting events for indexers |
| SafeProxyFactory | `0x4e1DCf7AD4e460CfD30791CCC4F9c8a4f820ec67` | Dep프로젝트로 돌아가기