mirror of
https://github.com/netbirdio/netbird.git
synced 2025-04-09 17:50:15 +02:00
Merge pull request #899 from netbirdio/feature/create_macos_pkg_on_release
Adding static files for pkg creation for Mac
This commit is contained in:
commit
d2db6bd03e
2
.github/workflows/release.yml
vendored
2
.github/workflows/release.yml
vendored
@ -9,7 +9,7 @@ on:
|
|||||||
pull_request:
|
pull_request:
|
||||||
|
|
||||||
env:
|
env:
|
||||||
SIGN_PIPE_VER: "v0.0.6"
|
SIGN_PIPE_VER: "v0.0.7"
|
||||||
GORELEASER_VER: "v1.14.1"
|
GORELEASER_VER: "v1.14.1"
|
||||||
|
|
||||||
concurrency:
|
concurrency:
|
||||||
|
32
release_files/darwin_pkg/postinstall
Executable file
32
release_files/darwin_pkg/postinstall
Executable file
@ -0,0 +1,32 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
APP=/Applications/NetBird.app
|
||||||
|
AGENT=/usr/local/bin/netbird
|
||||||
|
LOG_FILE=/var/log/netbird/client_install.log
|
||||||
|
|
||||||
|
{
|
||||||
|
echo "Installing NetBird..."
|
||||||
|
|
||||||
|
if test -d $APP; then
|
||||||
|
echo "NetBird app copied successfully."
|
||||||
|
else
|
||||||
|
echo "NetBird app could not be copied to the Applications folder."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
ln -s $APP/Contents/MacOS/netbird $AGENT
|
||||||
|
if test -f $AGENT; then
|
||||||
|
echo "NetBird binary linked successfully."
|
||||||
|
else
|
||||||
|
echo "NetBird could not create symlink to /usr/local/bin"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
$AGENT service install
|
||||||
|
$AGENT service start
|
||||||
|
|
||||||
|
open $APP
|
||||||
|
|
||||||
|
echo "Finished Netbird installation successfully"
|
||||||
|
exit 0 # all good
|
||||||
|
} &> $LOG_FILE
|
8
release_files/darwin_pkg/preinstall
Executable file
8
release_files/darwin_pkg/preinstall
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
LOG_FILE=/var/log/netbird/client_install.log
|
||||||
|
|
||||||
|
{
|
||||||
|
echo "Preinstall complete"
|
||||||
|
exit 0 # all good
|
||||||
|
} &> $LOG_FILE
|
Loading…
Reference in New Issue
Block a user