Skip to content

Commit 22f0c8b

Browse files
Merge pull request #135 from matyasselmeci/pr/CERN-IAM-2.SOFTWARE-5843
Add entries to vomses file for SOFTWARE-5843 but remove them in the spec file
2 parents ef58943 + f0710fa commit 22f0c8b

File tree

3 files changed

+21
-27
lines changed

3 files changed

+21
-27
lines changed

bin/vomses-crosscheck

+4-25
Original file line numberDiff line numberDiff line change
@@ -7,17 +7,6 @@ import sys
77
vomses_path = "vomses"
88
vomsdir = "vomsdir"
99

10-
11-
# A list of .lsc files that are not meant to be in the vomses file (SOFTWARE-5843)
12-
lsc_ignore_missing_vomses = [
13-
"alice/voms-alice-auth.cern.ch.lsc",
14-
"atlas/voms-atlas-auth.cern.ch.lsc",
15-
"cms/voms-cms-auth.cern.ch.lsc",
16-
"dteam/voms-dteam-auth.cern.ch.lsc",
17-
"lhcb/voms-lhcb-auth.cern.ch.lsc",
18-
]
19-
20-
2110
def usage():
2211
print("usage: %s [vomses vomsdir]" % os.path.basename(__file__))
2312
print(" or: %s --system" % os.path.basename(__file__))
@@ -71,7 +60,6 @@ vomses_entries = get_vomses()
7160
missing_lsc_files = []
7261
missing_vomses_entries = []
7362
dn_mismatches = []
74-
wrongly_ignored_lsc = []
7563

7664
for entry in vomses_entries:
7765
lsc = get_lsc(entry)
@@ -88,24 +76,15 @@ vomses_lsc_files = set(entry.lsc for entry in vomses_entries)
8876

8977
os.chdir(vomsdir)
9078
for lsc_path in sorted(glob.glob("*/*.lsc")):
91-
if lsc_path in lsc_ignore_missing_vomses:
92-
if lsc_path in vomses_lsc_files:
93-
wrongly_ignored_lsc += [
94-
"vomses entry found for ignored lsc file %s; please remove from "
95-
"lsc_ignore_missing_vomses"
96-
]
97-
else:
98-
if lsc_path not in vomses_lsc_files:
99-
missing_vomses_entries += ["No vomses entry for %s" % lsc_path]
79+
if lsc_path not in vomses_lsc_files:
80+
missing_vomses_entries += ["No vomses entry for %s" % lsc_path]
10081

101-
for x in (missing_lsc_files, missing_vomses_entries, dn_mismatches,
102-
wrongly_ignored_lsc):
82+
for x in (missing_lsc_files, missing_vomses_entries, dn_mismatches):
10383
if x:
10484
for line in x:
10585
print(line)
10686
print()
10787

108-
e = bool(missing_lsc_files or missing_vomses_entries or dn_mismatches or
109-
wrongly_ignored_lsc)
88+
e = bool(missing_lsc_files or missing_vomses_entries or dn_mismatches)
11089
sys.exit(e)
11190

rpm/vo-client.spec

+12-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
# Set to 1 to enable IAM-based VOMS endpoints
2-
# (SOFTWARE-4666, SOFTWARE-4576, SOFTWARE-4595)
2+
# (SOFTWARE-4666, SOFTWARE-4576, SOFTWARE-4595, SOFTWARE-5843)
33
%define iam 1
4+
# Set to 1 to include IAM-based VOMS endpoints in the vomses file (SOFTWARE-5843)
5+
%define iam_vomses 0
46

57
Name: vo-client
68
Version: 135
@@ -44,15 +46,23 @@ Requires: %{name} = %{version}-%{release}
4446
%build
4547
make
4648

47-
%if ! 0%{iam}
49+
%if ! 0%{?iam}
4850
rm -f vomsdir/atlas/voms-atlas-auth.app.cern.ch.lsc
4951
rm -f vomsdir/cms/voms-cms-auth.app.cern.ch.lsc
52+
53+
for vo in alice atlas cms dteam lhcb; do
54+
rm -f vomsdir/${vo}/voms-${vo}-auth.cern.ch.lsc
55+
done
5056
%endif
5157

5258
# FIXME: Remove IAM vomses entries to avoid use by VOMS clients until
5359
# IAM LSC files are more widely distributed across the world
5460
# (SOFTWARE-4595)
5561
sed -Ei '/.*voms-(alice|lhcb|ops)-auth.app.cern.ch.*/d' vomses
62+
%if ! 0%{?iam_vomses}
63+
# Additional entries from SOFTWARE-5843:
64+
sed -Ei '/.*voms-(alice|atlas|cms|dteam|lhcb)-auth.cern.ch.*/d' vomses
65+
%endif
5666

5767
%install
5868
install -d $RPM_BUILD_ROOT/%{_sysconfdir}

vomses

+5
Original file line numberDiff line numberDiff line change
@@ -58,3 +58,8 @@
5858
"eic" "eic.voms2.opensciencegrid.org" "15001" "/DC=org/DC=incommon/C=US/ST=Wisconsin/O=University of Wisconsin-Madison/CN=eic.voms2.opensciencegrid.org" "eic"
5959
"eic" "eicvoms.sdcc.bnl.gov" "15001" "/DC=org/DC=incommon/C=US/ST=New York/O=Brookhaven National Laboratory/OU=SDCC/CN=eicvoms.sdcc.bnl.gov" "eic"
6060
"kagra" "voms.cc.kek.jp" "15027" "/C=JP/O=KEK/OU=CRC/CN=host/voms.cc.kek.jp" "kagra"
61+
"alice" "voms-alice-auth.cern.ch" "443" "/DC=ch/DC=cern/OU=computers/CN=alice-auth.cern.ch" "alice"
62+
"atlas" "voms-atlas-auth.cern.ch" "443" "/DC=ch/DC=cern/OU=computers/CN=atlas-auth.cern.ch" "atlas"
63+
"cms" "voms-cms-auth.cern.ch" "443" "/DC=ch/DC=cern/OU=computers/CN=cms-auth.cern.ch" "cms"
64+
"dteam" "voms-dteam-auth.cern.ch" "443" "/DC=ch/DC=cern/OU=computers/CN=dteam-auth.cern.ch" "dteam"
65+
"lhcb" "voms-lhcb-auth.cern.ch" "443" "/DC=ch/DC=cern/OU=computers/CN=lhcb-auth.cern.ch" "lhcb"

0 commit comments

Comments
 (0)