Skip to content

Commit

Permalink
macos installer: install default policy.json file
Browse files Browse the repository at this point in the history
Include a default policy.json file in the macos package so users do not
have to add this manually.

Signed-off-by: Paul Holzinger <pholzing@redhat.com>
  • Loading branch information
Luap99 committed Feb 20, 2024
1 parent 96d9d3e commit 9fd1831
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
2 changes: 2 additions & 0 deletions contrib/pkginstaller/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,8 @@ packagedir: podman_version package_root Distribution welcome.html
cp -r scripts $(PACKAGE_DIR)/
cp -r $(PACKAGE_ROOT) $(PACKAGE_DIR)/
cp package.sh $(PACKAGE_DIR)/
mkdir $(PACKAGE_DIR)/config
cp ../../pkg/machine/ocipull/policy.json $(PACKAGE_DIR)/config/policy.json
cd $(PACKAGE_DIR) && pkgbuild --analyze --root ./root component.plist
../../test/version/version > $(PACKAGE_DIR)/VERSION
echo -n $(ARCH) > $(PACKAGE_DIR)/ARCH
Expand Down
3 changes: 2 additions & 1 deletion contrib/pkginstaller/package.sh
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ CODESIGN_IDENTITY=${CODESIGN_IDENTITY:-mock}
PRODUCTSIGN_IDENTITY=${PRODUCTSIGN_IDENTITY:-mock}
NO_CODESIGN=${NO_CODESIGN:-0}
HELPER_BINARIES_DIR="/opt/podman/bin"
MACHINE_POLICY_JSON_DIR="/opt/podman/config"

binDir="${BASEDIR}/root/podman/bin"

Expand All @@ -16,7 +17,7 @@ arch=$(cat "${BASEDIR}/ARCH")

function build_podman() {
pushd "$1"
make GOARCH="${goArch}" podman-remote HELPER_BINARIES_DIR="${HELPER_BINARIES_DIR}"
make GOARCH="${goArch}" podman-remote HELPER_BINARIES_DIR="${HELPER_BINARIES_DIR} MACHINE_POLICY_JSON_DIR=${MACHINE_POLICY_JSON_DIR}"
make GOARCH="${goArch}" podman-mac-helper
cp bin/darwin/podman "contrib/pkginstaller/out/packaging/${binDir}/podman"
cp bin/darwin/podman-mac-helper "contrib/pkginstaller/out/packaging/${binDir}/podman-mac-helper"
Expand Down

0 comments on commit 9fd1831

Please sign in to comment.