Make the build script work with SELinux
Generally speaking the scripts are executed from a user's homedirectory.
By default the SELinux context will be: unconfined_u:object_r:user_home_t:s0
For podman to work with SELinux enable the context needs to be
system_u:object_r:container_file_t:s0. Podman can do this automatically
if the volume is made with the :z attribute.
(cherry picked from commit 8f6852e813
)
This commit is contained in:
parent
c23aecab0b
commit
51de348e0c
10
build.sh
10
build.sh
|
@ -71,9 +71,9 @@ fi
|
|||
|
||||
# You can add --no-cache as an option to podman_build below to rebuild all containers from scratch
|
||||
export podman_build="$podman build --build-arg img_version=${img_version}"
|
||||
export podman_build_mono="$podman_build --build-arg mono_version=${mono_version} -v ${files_root}:/root/files"
|
||||
export podman_build_mono="$podman_build --build-arg mono_version=${mono_version} -v ${files_root}:/root/files:z"
|
||||
|
||||
$podman build -v ${files_root}:/root/files -t godot-fedora:${img_version} -f Dockerfile.base . 2>&1 | tee logs/base.log
|
||||
$podman build -v ${files_root}:/root/files:z -t godot-fedora:${img_version} -f Dockerfile.base . 2>&1 | tee logs/base.log
|
||||
$podman_build -t godot-export:${img_version} -f Dockerfile.export . 2>&1 | tee logs/export.log
|
||||
|
||||
$podman_build_mono -t godot-mono:${img_version} -f Dockerfile.mono . 2>&1 | tee logs/mono.log
|
||||
|
@ -93,8 +93,8 @@ if [ ! -e files/MacOSX${OSX_SDK}.sdk.tar.xz ] || [ ! -e files/iPhoneOS${IOS_SDK}
|
|||
fi
|
||||
|
||||
echo "Building OSX and iOS SDK packages. This will take a while"
|
||||
$podman_build -t godot-xcode-packer:${img_version} -f Dockerfile.xcode -v ${files_root}:/root/files . 2>&1 | tee logs/xcode.log
|
||||
$podman run -it --rm -v ${files_root}:/root/files -e XCODE_SDKV="${XCODE_SDK}" -e OSX_SDKV="${OSX_SDK}" -e IOS_SDKV="${IOS_SDK}" godot-xcode-packer:${img_version} 2>&1 | tee logs/xcode_packer.log
|
||||
$podman_build -t godot-xcode-packer:${img_version} -f Dockerfile.xcode -v ${files_root}:/root/files:z . 2>&1 | tee logs/xcode.log
|
||||
$podman run -it --rm -v ${files_root}:/root/files:z -e XCODE_SDKV="${XCODE_SDK}" -e OSX_SDKV="${OSX_SDK}" -e IOS_SDKV="${IOS_SDK}" godot-xcode-packer:${img_version} 2>&1 | tee logs/xcode_packer.log
|
||||
fi
|
||||
|
||||
$podman_build_mono -t godot-osx:${img_version} -f Dockerfile.osx . 2>&1 | tee logs/osx.log
|
||||
|
@ -113,5 +113,5 @@ if [ "${build_msvc}" != "0" ]; then
|
|||
exit 1
|
||||
fi
|
||||
|
||||
$podman_build -t godot-msvc:${img_version} -f Dockerfile.msvc -v ${files_root}:/root/files . 2>&1 | tee logs/msvc.log
|
||||
$podman_build -t godot-msvc:${img_version} -f Dockerfile.msvc -v ${files_root}:/root/files:z . 2>&1 | tee logs/msvc.log
|
||||
fi
|
||||
|
|
Loading…
Reference in New Issue