mirror of
https://github.com/zyllian/webdog.git
synced 2025-05-11 02:56:38 -07:00
make serving binding address more easily configurable
This commit is contained in:
parent
190cba1f3a
commit
624853f3ba
2 changed files with 3 additions and 3 deletions
|
@ -147,8 +147,8 @@ fn skip_path(builder: &SiteBuilder, path: &Path) -> bool {
|
|||
|
||||
impl Site {
|
||||
/// Serves the site for development. Don't use this in production.
|
||||
pub async fn serve(self) -> eyre::Result<()> {
|
||||
let addr = SocketAddr::from(([127, 0, 0, 1], 8080));
|
||||
pub async fn serve(self, addr: &str) -> eyre::Result<()> {
|
||||
let addr: SocketAddr = addr.parse()?;
|
||||
|
||||
let mut builder = SiteBuilder::new(self, true)?.prepare()?;
|
||||
let site = &builder.site;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue