From 8a490af9692415012b13a3d3b70418b2248806b2 Mon Sep 17 00:00:00 2001 From: James Brundage <+@noreply.github.com> Date: Sun, 29 Sep 2024 00:37:23 -0700 Subject: [PATCH] feat: 4bitcss Container.Start.ps1 ( Fixes #76 ) Starting Jekyll in ThreadJob --- Container.start.ps1 | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/Container.start.ps1 b/Container.start.ps1 index 3ed5b0350..e13ec6eae 100644 --- a/Container.start.ps1 +++ b/Container.start.ps1 @@ -52,6 +52,21 @@ if ($args) { # If there is a Microservice.ps1, run it. . ./Microservice.ps1 } + #region Custom + else + { + Start-ThreadJob -Name "${env:ModuleName}.Jekyll" -ScriptBlock { + Push-Location ./docs + jekyll serve --host "$( + if ($env:JEKYLL_HOST) { $env:JEKYLL_HOST } + else { '*' } + )" '--port' $( + if ($env:JEKYLL_PORT) { $env:JEKYLL_PORT } + else { 4000 } + ) + } + } + #endregion Custom } # If you want to do something when the container is stopped, you can register an event.