mirror of
https://src.koozali.org/infra/smeserver-koji.git
synced 2024-11-24 18:47:28 +01:00
27 lines
673 B
Bash
Executable File
27 lines
673 B
Bash
Executable File
#!/bin/bash
|
|
# Copyright (C) 2019 Intel Corporation
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
|
|
set -xe
|
|
SCRIPT_DIR="$(dirname "$(realpath "$0")")"
|
|
source "$SCRIPT_DIR"/globals.sh
|
|
source "$SCRIPT_DIR"/parameters.sh
|
|
|
|
KOJI_BUILD_FQDN=$1
|
|
|
|
dnf install -y nfs-utils
|
|
|
|
# Export server directory to be mounted by clients
|
|
echo "$KOJI_DIR $KOJI_BUILD_FQDN(ro,no_root_squash)" >> /etc/exports
|
|
|
|
# allow nfs usage in selinux and firewall
|
|
setsebool -P httpd_use_nfs=1
|
|
|
|
firewall-cmd --permanent --add-service=nfs
|
|
firewall-cmd --permanent --add-service=mountd
|
|
firewall-cmd --permanent --add-service=rpc-bind
|
|
firewall-cmd --reload
|
|
|
|
systemctl enable --now rpcbind
|
|
systemctl enable --now nfs-server
|