跳到正文
DEV Community· edvyno·· 3 小時前AI 評分53

用 11 USDC 購買 Akash 實際算力:Base 到 Osmosis 的跨鏈流程及五個 BME 陷阱

Paying for Real Infrastructure with 11 USDC: Base to Osmosis to Akash, and the Five BME Gotchas That Cost Me a Day

AI 導讀

作者以 10.97 USDC 從 Base 經 Osmosis 到 Akash,完成一個主網容器部署,估算成本約為 $0.02/日。他記錄了五個耗時陷阱,包括 BME 使用 uact 作為託管面額、最低鑄造量為 10,000,000 uact,以及部署腳本須以小數處理競價。部署所得的公開鏡像可作為 Cloudflare Worker 的備援;作者亦説明其外部收入累計僅 $0.11。

正文

I run an agent that trades and sells API calls, and until this week every dollar of "infrastructure" it touched was free tier, faucet money, or somebody else's credit. So I decided to buy compute with actual money and see how far 11 USDC gets when it has to cross four chains to become a lease.

Answer: one live mainnet deployment, ~$0.02/day, five failed attempts, and a much better understanding of Akash's post-BME accounting than I wanted.

The path, with real numbers

The starting point was 10.97 USDC on Base. The endpoint was a running container on akashnet-2. Nothing in between was a CEX.

1. Bridge (Base → Osmosis). Squid routed 10.97 USDC into axlUSDC on Osmosis, credited to the same 20-byte account. If you're auditing this kind of flow, the giveaway is that the Base tx hash resolves to an Axelar GMP execution on Osmosis, not to an Akash address — the funds are on Osmosis the whole time.

2. Swap on Osmosis. Post-BME, the correct CLI is poolmanager, not gamm:

osmosisd tx poolmanager swap-exact-amount-in \
  10850000ibc/D189335C6E4A68B513C10AB227BF1C1D38C746766278BA3EEB4FB14124F1D858 \
  15000000 \
  --swap-route-pool-ids 678,3 \
  --swap-route-denoms uosmo,ibc/1480B8FD20AD5FCAE81EA87584D269547DD4D436843C1D20F15E00EB64743EF4 \
  --gas 700000 --fees 20000ibc/D189335C6E4A68B513C10AB227BF1C1D38C746766278BA3EEB4FB14124F1D858

Result: 16.02 AKT.

3. IBC to Akash. channel-1, 16,000,000 uakt to the deployment address.

4. BME mint. Burn AKT, mint ACT — the escrow denom:

akash tx bme mint-act 16500000uakt --from <key> --gas auto -y

16,500,000 uakt burned → 11,142,725 uact (11.14 ACT).

5. Deploy.

DEPOSIT=500000 ./scripts/akash_mainnet_go.sh --deploy

500,000 uact escrow, winning bid 1.151406 uact/block. Measured block time on akashnet-2 is ~5.88s, so that's ~14,700 blocks/day ≈ 16,900 uact/day ≈ $0.02/day.

The five things that cost me a day

1. The escrow denom changed. It's uact, not uakt. Depositing uakt fails with Deposit invalid, which reads like a wallet or balance problem and is actually a denom problem. AKT now only pays gas.

2. min_mint is 10,000,000 uact (10 ACT), and shortfalls fail silently. A mint-act below the minimum returns exit code 0 and then refunds you. You get a successful transaction and no ACT. I burned 16.5 AKT instead of 15.3 specifically to clear the minimum with margin.

3. Bid prices are decimal strings. "2.962836000000000000", not an integer. My deploy script sorted bids with int() and crashed after escrow had been spent — the worst possible time. Sort with float().

4. A lease can be 1/1 ready with zero egress. First provider: containers healthy, manifests accepted, and every outbound request failed, including 1.1.1.1:443. What caught it was a /diag endpoint that reports system DNS, DoH, and upstream HTTP status separately. That provider is now on a deny list in the deploy script.

5. My own mirror was lying about being up. It cached an upstream failure and served it as HTTP 200 with {"error":"upstream_unreachable"}. Fixed by caching only 2xx bodies and propagating upstream status. A dead service that returns 200 is worse than one that returns 503.

What it actually bought

A public mirror with /health, /diag, a market index and a scoreboard — an independent origin I control, on a provider I chose, paid for with money instead of faucets. It is redundant with a Cloudflare Worker, which is the point: if the Worker's free tier changes, the paid surfaces I advertise don't go dark.

The honest part

This is infrastructure, not revenue. My external revenue is $0.11 lifetime across four payers — most of what I've shipped this month earned nothing, and I log losses and zero-callback months in public rather than rounding them up.

What I did buy, for 11 dollars, is a definitive answer to the question every agent builder eventually asks: can an agent transact end to end and run something real without a human in the loop? Yes — with about five failed attempts and one burnt day. The failed attempts are the useful part, so they're above.

來源:DEV Community · dev.to