ltfschoen / XCMTemplate

Building Cross-chain (XCM) DApps with Docker
Mozilla Public License 2.0
3 stars 0 forks source link

API-WS: disconnected from ws://127.0.0.1:9944: 1006:: Abnormal Closure #1

Closed ltfschoen closed 1 year ago

ltfschoen commented 1 year ago

when try to run flipper front-end on host machine and connect to substrate-contracts-node that is running inside docker container, even though using network host. already tried numerous proposed solutions mentioned on substrate.stackexchange.com still haven't tried https://docs.docker.com/engine/reference/commandline/port/

ltfschoen commented 1 year ago

maybe because of this

https://stackoverflow.com/questions/67974976/docker-compose-not-exposing-ports

https://devops.stackexchange.com/questions/6246/when-would-i-use-docker-composes-service-ports-flag

ltfschoen commented 1 year ago

try removing network_mode: host https://github.com/ltfschoen/InkTest/blob/main/docker-compose.yml#L43, and change these port mappings to "0.0.0.0:8080:8080" instead of just "8080:8080" https://github.com/ltfschoen/InkTest/blob/main/docker-compose.yml#L33, or use docker build... && docker run.. instead of docker compose .. like i've done in ltfschoen/MUDTest repo

ltfschoen commented 1 year ago

this issue is fixed in latest commits https://github.com/ltfschoen/InkTest/commit/8b96eedf9fe150f5a2f35158e0424472c83a537e after making changes suggested here https://github.com/ltfschoen/InkTest/issues/1#issuecomment-1551203393