Custom UI - Tunnel fails to work

Hi there

Using the hello-world-app-custom-ui example ie https://developer.atlassian.com/platform/forge/build-a-custom-ui-app-in-confluence/

When I run the tunnel to start logging output, I browse the webpage, I receive ‘localhost refused to connect’ ie

Untitled

Im running version Node.js V20.9.0.

The strange thing, is that the tunnel worked well for the basic hello-world-app example, which used the UI Kit.

Any ideas why this is not working?

Thanks

Lee

Hi @LeeParvin1. There shouldn’t be anything different in that app template which would cause the tunnel to not work properly. Just to be certain, I tried it myself from scratch and didn’t encounter any problems. The ngrok tunnel isn’t active for some reason on your side.

When you visit http://localhost:8001 from your browser, are you getting any output back? (e.g. Loading… in the browser, and a message like Serving file index.html for resource main in your console log) If so, this tells us your app is running locally.

Are you getting this error message immediately after starting forge tunnel, or does this only occur after some idle time? (e.g. 10 or 20 minutes)

2 Likes

Whoever writes Atlassian’s docs never tests them. My very first entry to the ecosystem years ago was Connect hello world tutorials that also didn’t work.

Tunnelling port is likely the problem: https://developer.atlassian.com/platform/forge/tunneling/#connecting-the-tunnel-to-your-own-dev-server

resources:
  - key: foo
    path: static/foo/build
    tunnel:
      port: 3000

Let’s not throw out blanket statements like this that aren’t true. Docs work at the time of authorship and are tested. The problem is there are a lot of moving pieces with the platform and the maintainers of the documentation. Documentation can become outdated or obsolete with a single release. It’s a hard problem we’re working on and aware of.

If you find a problem with the docs there are a couple of ways to raise awareness. Use the 5 star rating at the top of the page to submit a bug report. After you click on a star rating you’ll be asked to give feedback.

Second on the side of most guides you will find a Get Help button. That will allow you to create a thread here in the community where you can let us know of the problem you are having.

1 Like

It’s a problem you don’t ever see on other developer platforms though. Atlassian only needs one employee to run through the hello world tutorials on a monthly basis to ensure they work for newbies.