Skip to content

Commit

Permalink
Merge pull request #583 from htcondor/V6-HTCONDOR-2030-fix-tests
Browse files Browse the repository at this point in the history
HTCONDOR-2030: Fix tests
  • Loading branch information
ColeBollig authored Sep 12, 2023
2 parents 5f40db7 + b68bb52 commit 468cf6c
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 10 deletions.
1 change: 1 addition & 0 deletions .github/workflows/build_and_test_rpms.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ jobs:
platform:
- centos:7
- rockylinux:8
- almalinux:9
target_env:
- uw_build
- osg-3.6
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/upload_rpms.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ jobs:
platform:
- centos:7
- rockylinux:8
- almalinux:9
steps:
- uses: actions/checkout@v3

Expand Down
2 changes: 1 addition & 1 deletion config/condor-ce-collector.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
d /var/run/condor-ce 0755 condor condor - -
d /run/condor-ce 0755 condor condor - -
d /var/lock/condor-ce 0755 condor condor - -
d /var/lock/condor-ce/user 1777 condor condor - -
2 changes: 1 addition & 1 deletion config/condor-ce.conf
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
d /var/run/condor-ce 0755 condor condor - -
d /run/condor-ce 0755 condor condor - -
d /var/lock/condor-ce 0755 condor condor - -
d /var/lock/condor-ce/user 1777 condor condor - -
11 changes: 7 additions & 4 deletions tests/build_rpms.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,8 +35,10 @@ yum install -y epel-release $YUM_PKG_NAME
# Broken mirror?
echo "exclude=mirror.beyondhosting.net" >> /etc/yum/pluginconf.d/fastestmirror.conf

if [[ $OS_VERSION != 7 ]]; then
yum-config-manager --enable powertools
if [ $OS_VERSION -eq 8 ]; then
dnf config-manager --enable powertools
elif [ $OS_VERSION -eq 9 ]; then
dnf config-manager --enable crb
fi

# Install packages required for the build
Expand All @@ -62,11 +64,11 @@ if [[ $BUILD_ENV == osg* ]]; then
OSG_SERIES=$(cut -d- -f2 <<< "$BUILD_ENV")
yum install -y https://repo.opensciencegrid.org/osg/${OSG_SERIES}/osg-${OSG_SERIES}-el${OS_VERSION}-release-latest.rpm
else
# This is currently tracking the 9.0 stable release.
# This is currently tracking the 10.x feature release.
# For the stable release series the version number is required.
# For the feature series, one can either use the version number (i.e. 9.1)
# or 'current' which tracks the latest feature series
yum install -y https://research.cs.wisc.edu/htcondor/repo/9.0/htcondor-release-current.el${OS_VERSION}.noarch.rpm
yum install -y https://research.cs.wisc.edu/htcondor/repo/10.x/htcondor-release-current.el${OS_VERSION}.noarch.rpm
fi

# Prepare the RPM environment
Expand All @@ -78,6 +80,7 @@ printf "%s\n" "%dist .el${OS_VERSION}" >> /etc/rpm/macros.dist
cp htcondor-ce/rpm/htcondor-ce.spec /tmp/rpmbuild/SPECS
package_version=`grep Version htcondor-ce/rpm/htcondor-ce.spec | awk '{print $2}'`
pushd htcondor-ce
git config --global --add safe.directory /htcondor-ce
git archive --format=tar --prefix=htcondor-ce-${package_version}/ HEAD | \
gzip > /tmp/rpmbuild/SOURCES/htcondor-ce-${package_version}.tar.gz
popd
Expand Down
2 changes: 1 addition & 1 deletion tests/containers/README.dev.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ docker build -t entrypoint -f tests/containers/entrypoint/Dockerfile .
You may also specify `--build-arg` for:

- `BASE_IMAGE`: EL-based OS container base image (default: `rockylinux:8`, suggested alternative `centos:7`)
- `CONDOR_SERIES`: HTCondor release series (default `9.0`)
- `CONDOR_SERIES`: HTCondor release series (default `10.x`)

### Starting the CE ###

Expand Down
8 changes: 5 additions & 3 deletions tests/containers/entrypoint/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ FROM $BASE_IMAGE

# "ARG BASE_IMAGE" needs to be here again because the previous instance has gone out of scope.
ARG BASE_IMAGE=rockylinux:8
ARG CONDOR_SERIES=9.0
ARG CONDOR_SERIES=10.x

RUN groupadd -o -g 9619 testuser && \
useradd -m -u 9619 -g 9619 -s /bin/bash testuser
Expand All @@ -28,8 +28,10 @@ RUN \
yum update -y && \
yum install -y https://research.cs.wisc.edu/htcondor/repo/${CONDOR_SERIES}/htcondor-release-current.el${EL}.noarch.rpm \
$YUM_PKG_NAME && \
if [[ $OS_VERSION != 7 ]]; then \
yum-config-manager --enable powertools; \
if [ $OS_VERSION -eq 8 ]; then \
dnf config-manager --enable powertools; \
elif [ $OS_VERSION -eq 9 ]; then \
dnf config-manager --enable crb; \
fi && \
yum install -y git \
make \
Expand Down

0 comments on commit 468cf6c

Please sign in to comment.