Forward local network to public

Hello

I started a local network with:

dfx start --host 0.0.0.0:8000

If I forward this port to public internet, and the domain is https://xx.a.com. and I run dfx deploy --network https://xx.a.com, but the deploy output is:

Deployed canisters.
URLs:
  Frontend canister via browser
    random_maze_assets: https://ryjl3-tyaaa-aaaaa-aaaba-cai.xxx.a.com/
  Backend canister via Candid interface:
    random_maze: https://r7inp-6aaaa-aaaaa-aaabq-cai.xxx.a.com/?id=rrkah-fqaaa-aaaaa-aaaaq-cai

Obviously, the link cannot open,

What should I do to solve this problem?

If you register a catch-all DNS record pointing to the same IP, those links should work as is. Or you could use the alternate form of the link: instead of <id>.your.replica, your.replica/?canisterId=<id>.

this is very interesting!!!
so your dev env. DApp could be available on the regular old internet
and with http(s) out calls from IC it could be linked to a canister on ic. ???

Visiting your.replica/?canisterId=<id> is ok, but is it possible to change the url to correct one?

Yes, we are building a online IDE, we provide a dfx docker container, so you can deploy and interact. If you are interested, you can visit https://chainide.com

1 Like

to change the URL that it displays on the command line? No. Why not set up that record? It will increase ergonomics a bunch.