mirror of
https://git.freebsd.org/ports.git
synced 2025-07-18 09:49:18 -04:00
Generalize the packge building scripts to be able to be run on more than
one 'head' node, rather than just pointyhat itself. Constants are factored out into installation-specific files known as portbuild/conf/server.conf and portbuild/conf/client.conf. There is only one server.conf file. Individual <arch> directories may have their own client.conf files, or may symlink to ../conf/client.conf. Add the copying over of client.conf to the clients, and take care to force the file copy regardless of whether it is a symlink. Feature safe: yes
This commit is contained in:
parent
6cbd9ecd57
commit
f1c9dc80e7
Notes:
svn2git
2021-03-31 03:12:20 +00:00
svn path=/head/; revision=256987
1 changed files with 10 additions and 1 deletions
|
@ -1,5 +1,8 @@
|
||||||
#!/bin/sh
|
#!/bin/sh
|
||||||
#
|
# $FreeBSD$
|
||||||
|
|
||||||
|
# server-side script to set up an individual client
|
||||||
|
|
||||||
# XXX Use a worker pool that only runs N setups at once to avoid
|
# XXX Use a worker pool that only runs N setups at once to avoid
|
||||||
# raping the server. Hard to do in shell?
|
# raping the server. Hard to do in shell?
|
||||||
|
|
||||||
|
@ -19,6 +22,7 @@ buildid=$3
|
||||||
nodelist=$4
|
nodelist=$4
|
||||||
shift 4
|
shift 4
|
||||||
|
|
||||||
|
. ${pb}/conf/server.conf
|
||||||
if [ -f ${pb}/${arch}/portbuild.conf ]; then
|
if [ -f ${pb}/${arch}/portbuild.conf ]; then
|
||||||
. ${pb}/${arch}/portbuild.conf
|
. ${pb}/${arch}/portbuild.conf
|
||||||
else
|
else
|
||||||
|
@ -67,6 +71,11 @@ setup() {
|
||||||
${client_user}@${node}:${pb}/
|
${client_user}@${node}:${pb}/
|
||||||
checkerror $? || (echo "Copying scripts to ${node} failed"; return 1)
|
checkerror $? || (echo "Copying scripts to ${node} failed"; return 1)
|
||||||
|
|
||||||
|
# client.conf can be a symlink; copy the actual file
|
||||||
|
rsync ${rsync_gzip} -e "${ssh_cmd}" -r -L -p --delete ${pb}/${arch}/client.conf \
|
||||||
|
${client_user}@${node}:${pb}/${arch}
|
||||||
|
checkerror $? || (echo "copying client.conf to ${node} failed"; return 1)
|
||||||
|
|
||||||
rsync ${rsync_gzip} -e "${ssh_cmd}" -r -l -p --delete ${pb}/${arch}/portbuild* \
|
rsync ${rsync_gzip} -e "${ssh_cmd}" -r -l -p --delete ${pb}/${arch}/portbuild* \
|
||||||
${client_user}@${node}:${pb}/${arch}
|
${client_user}@${node}:${pb}/${arch}
|
||||||
checkerror $? || (echo "copying portbuild.conf files to ${node} failed"; return 1)
|
checkerror $? || (echo "copying portbuild.conf files to ${node} failed"; return 1)
|
||||||
|
|
Loading…
Add table
Reference in a new issue