I forgot to mention that when generating a project like in your tutorial, it goes fine. my difference is that i'm doing the multi-platform Kotlin/KotlinJs
Thanks for sharing the project. I investigated this by running installDist locally, which creates a "start script" in /build/install/qlciscte/bin – and that indeed throws a IllegalArgumentException: Neither port nor sslPort specified.
now it works when I run the binary produced by gradle stage. however, when uploading to Heroku, the app still crashes. Here's the log entry:
2021-01-28T11:18:09.671617+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=qlciscte.herokuapp.com request_id=fbea81df-588f-443f-a520-7072d3110169 fwd="94.63.156.9" dyno= connect= service= status=503 bytes= protocol=https
It's not very informative. Do you know any trick to get a more detailed trace of what went wrong on Heroku?
meanwhile I also noticed that :) now I have another problem, but that has to with class version compilation of some libs i'm using.
thanks for the tip!
For further actions, you may consider blocking this person and/or reporting abuse
We're a place where coders share, stay up-to-date and grow their careers.
I forgot to mention that when generating a project like in your tutorial, it goes fine. my difference is that i'm doing the multi-platform Kotlin/KotlinJs
Thanks for sharing the project. I investigated this by running
installDist
locally, which creates a "start script" in/build/install/qlciscte/bin
– and that indeed throws aIllegalArgumentException: Neither port nor sslPort specified.
And in fact, you're actually hitting a bug here! More specifically, KT-37964 Gradle application/distribution plugin does not copy and name jar files correctly when using installDist task for multiplatform project.
The TLDR:
installDist
generates a script with an entry point using your projects.jar
, which the isn't properly being copied. The workaround:Hope this will be fixed in due time. Tripped me up as well, as you can see :)
You can also find a working Gradle configuration in the companion project for the "Building a Full Stack Web App with Kotlin Multiplatform" hands-on tutorial.
now it works when I run the binary produced by gradle stage. however, when uploading to Heroku, the app still crashes. Here's the log entry:
2021-01-28T11:18:09.671617+00:00 heroku[router]: at=error code=H10 desc="App crashed" method=GET path="/" host=qlciscte.herokuapp.com request_id=fbea81df-588f-443f-a520-7072d3110169 fwd="94.63.156.9" dyno= connect= service= status=503 bytes= protocol=https
It's not very informative. Do you know any trick to get a more detailed trace of what went wrong on Heroku?
Discovered the issue by running
heroku logs --tail
before actually triggering a build. That gave me:You might want to adjust the contents of your
Procfile
, since your project is no longer calleduntitled
😉meanwhile I also noticed that :) now I have another problem, but that has to with class version compilation of some libs i'm using.
thanks for the tip!