firestorm is a package providing load-balancing (WIP) and reverse proxying for fiery based web servers as plugins. It supports proxying of both HTTP and WebSocket
# You can install marquee from CRAN
::pak("firestorm")
pak
# Or get the development version from Github
::pak("thomasp85/firestorm") pak
Below you can see an example of using firestorm with a fiery server. Here we relay all requests to the fiery server to another service running on the same computer.
library(fiery)
library(firestorm)
# create a reverse proxy to another service running on your computer
# at 127.0.0.1:9876
<- ReverseProxy$new("http://127.0.0.1:9876")
revprox
# Attach it to a fiery server
<- Fire$new()
app $attach(revprox)
app
# Start the server
$ignite() app