You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes one needs to always use a specific port when serving a site during local development (e.g. an API might only accepts requests from, say, localhost:3469).
It's possible to serve manually from a specific port with blogdown::serve_site(port = 3469).
However, it's not possible (as far as I could tell) to set a port to use in .Rprofile.
It'd be great if it was possible to set e.g. options(blogdown.serve_site.port = 3469) and then whenever serve_site is called, it's serving from that port.
The text was updated successfully, but these errors were encountered:
I understand that this is not obvious, but the ... arguments of blogdown::serve_site are passed to servr::server_config(), and you can configure the default values of them via servr.* options (or environment variables).
Ah I figured something like that might be the case!
I just submitted a pull request for an edit to this page on the blogdown documentation, which is where I was expecting to find that information when I was searching for it yesterday: #771
Happy new year Yihui!
Sometimes one needs to always use a specific port when serving a site during local development (e.g. an API might only accepts requests from, say, localhost:3469).
It's possible to serve manually from a specific port with
blogdown::serve_site(port = 3469)
.However, it's not possible (as far as I could tell) to set a port to use in
.Rprofile
.It'd be great if it was possible to set e.g.
options(blogdown.serve_site.port = 3469)
and then whenever serve_site is called, it's serving from that port.The text was updated successfully, but these errors were encountered: