Skip to content

Commit

Permalink
Packaging changes
Browse files Browse the repository at this point in the history
  • Loading branch information
michacassola committed Dec 29, 2024
1 parent edbc1d0 commit 2a78922
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion 1_post_install_script.sh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ cd "$unypkg_root_dir" || exit
#############################################################################################
### Start of script

wizard.sh -i
./wizard.sh -i

systemctl disable crowdsec
systemctl stop crowdsec
Expand Down
13 changes: 11 additions & 2 deletions unypkg-crowdsec-build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,17 @@ make DEFAULT_CONFIGDIR=/etc/uny/crowdsec BUILD_VERSION=v"$pkgver" build #BUILD_S
dest_dir="/uny/pkg/$pkgname/$pkgver"
mkdir -pv "$dest_dir"/
cp -a cmd "$dest_dir"/
mkdir -pv "$dest_dir"/cmd/{crowdsec,crowdsec-cli}
cp -a cmd/crowdsec/crowdsec "$dest_dir"/cmd/crowdsec/
cp -a cmd/crowdsec-cli/cscli "$dest_dir"/cmd/crowdsec-cli/
for plugin in cmd/notification-*/notification-*; do
base_name="$(basename "$plugin")"
plugin_name="${base_name/notification-/}"
mkdir -p "$dest_dir"/cmd/"$base_name"
cp -a "$plugin" "$dest_dir"/cmd/"$base_name"/
cp -a cmd/"$base_name"/"$plugin_name".yaml "$dest_dir"/cmd/"$base_name"/
done
sed -r "s|=/bin/(.*)|=/usr/bin/env bash -c \"\1\"|" -i config/crowdsec.service
cp -a config "$dest_dir"/
Expand Down

0 comments on commit 2a78922

Please sign in to comment.