Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix exe to allow overriding #1008

Open
wants to merge 2 commits into
base: develop
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 10 additions & 10 deletions default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -214,21 +214,21 @@ in rec {
exeFrontend = compressedJs frontend optimizationLevel externjs;
exeFrontendAssets = mkAssets exeFrontend;
exeAssets = mkAssets assets;
in pkgs.runCommand "serverExe" {} ''
in pkgs.runCommand "serverExe" {
backend = exeBackend;
frontend = exeFrontend;
frontendassets = exeFrontendAssets;
staticassets = exeAssets;
} ''
mkdir $out
set -eux
ln -s '${exeBackend}'/bin/* $out/
ln -s '${exeAssets}' $out/static.assets
for d in '${exeFrontendAssets}'/*/; do
ln -s $backend/bin/* $out/
ln -s $staticassets $out/static.assets
for d in $frontendassets/*/; do
ln -s "$d" "$out"/"$(basename "$d").assets"
done
echo ${version} > $out/version
'' // {
backend = exeBackend;
frontend = exeFrontend;
frontend-assets = exeFrontendAssets;
static-assets = exeAssets;
};
'';

server = { exe, hostName, adminEmail, routeHost, enableHttps, version, module ? serverModules.mkBaseEc2, redirectHosts ? [], configHash ? "" }@args:
let
Expand Down