[Webkooks] Switches the NPM deploy to rsync the directory instead of link it because docker will follow the link and then not update.
This commit is contained in:
@@ -22,13 +22,14 @@ let
|
||||
gitFull
|
||||
nodejs_22
|
||||
bashNonInteractive
|
||||
rsync
|
||||
];
|
||||
text = ''
|
||||
set -e
|
||||
id
|
||||
pwd
|
||||
|
||||
output_dir=$(date --utc --iso-8601=seconds)
|
||||
output_dir="./$(date --utc --iso-8601=seconds)"
|
||||
|
||||
export GIT_SSH_COMMAND='ssh -v -o "UserKnownHostsFile ${gitKnownHosts}" -i "${
|
||||
config.sops.secrets."deploy-key/mcp".path
|
||||
@@ -46,7 +47,8 @@ let
|
||||
# Use a local cache with --cache .npm
|
||||
npm ci --cache .npm
|
||||
npm run build -- --outDir "$output_dir"
|
||||
ln -s "$output_dir" deployed
|
||||
# Trailing slash on source to only copy contents, not the directory itself
|
||||
rsync --archive --delete "$output_dir"/ deployed
|
||||
'';
|
||||
};
|
||||
in
|
||||
|
||||
Reference in New Issue
Block a user