This module demonstrates creating a simple microservice in Vert.x, using Ruby, which sends regular messages on the Vert.x event bus.
mvn clean package
mvn docker:build
- If you need to push your Docker image, use
mvn docker:push
.
mvn docker:start
to boot up a Docker container andmvn docker:stop
to tear it down.
The Dockerfile in the module mirrors Docker settings in pom.xml
to illustrate different usage scenarios.
docker run -t -i vertxdemo/news-server-rb:1.0-SNAPSHOT
- Running Ruby verticles in Intellij requires installation and setup in project of JRuby
- Run Ruby verticles in IntelliJ by creating a Run task:
- Run -> Edit Configurations...
- Add a new Application configuration
- Main Class:
io.vertx.core.Launcher
- Program arguments:
run ./news-server-rb/src/main/rb/app/news_server.rb -ha
java -jar target/news-server-rb-1.0-SNAPSHOT-fat.jar -cp target/classes -ha