From c2b82dc111090ff8fa30f74782ac97a060944e16 Mon Sep 17 00:00:00 2001 From: Marco Mascheroni Date: Thu, 6 Jul 2023 05:43:51 -0700 Subject: [PATCH 1/3] Add option to set xml output directory in OSG_autoconf. Fixes #318 --- factory/tools/OSG_autoconf.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/factory/tools/OSG_autoconf.py b/factory/tools/OSG_autoconf.py index af0acbfd1..38eae1d1e 100644 --- a/factory/tools/OSG_autoconf.py +++ b/factory/tools/OSG_autoconf.py @@ -635,6 +635,7 @@ def create_missing_file_internal(missing_info, osg_info, whitelist_info, osg_col def main(args): """The main""" config = get_yaml_file_info(args.config[0]) + xmloutdir = config.get('XML_OUTDIR', None) try: # Queries the OSG collector result = get_information(config["OSG_COLLECTOR"]) @@ -657,7 +658,9 @@ def main(args): # Convert the resoruce dictionary obtained this way into a string (xml) entries_configuration = get_entries_configuration(result) # Write the factory configuration file on the disk - write_to_xml_file(white_list.replace("yml", "xml"), entries_configuration) + xmloutdir = os.path.dirname(white_list) if xmloutdir==None else xmloutdir + filename = os.path.basename(white_list.replace("yml", "xml")) + write_to_xml_file(os.path.join(xmloutdir, filename), entries_configuration) if __name__ == "__main__": From 8487be099d306379c07543ebf86c885e6aa823c6 Mon Sep 17 00:00:00 2001 From: Marco Mascheroni Date: Wed, 2 Aug 2023 07:05:35 -0700 Subject: [PATCH 2/3] Add a few items to CHANGELOG --- CHANGELOG.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 01527fe1c..ab9805b6a 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -176,8 +176,8 @@ Changes since the last release ### New features / functionalities -- item one of the list -- item N +- Add option to set xml output directory in OSG_autoconf (PR #319) +- Allow OSG_autoconf to skip sites or CEs that are not present in the OSR collector (PR #315) ### Changed defaults / behaviours From 8b346708e519caef947e9f194517954b6c501896 Mon Sep 17 00:00:00 2001 From: Marco Mambelli Date: Thu, 17 Aug 2023 14:07:45 -0500 Subject: [PATCH 3/3] Fixed CHANGELOG and pre-commit fixes --- CHANGELOG.md | 8 +++++--- factory/tools/OSG_autoconf.py | 4 ++-- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ab9805b6a..dfe0ef2ab 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,6 +10,8 @@ Changes since the last release ### New features / functionalities - Added support for Debian 11 and Ubuntu 22 worker nodes (PR #320) +- Add option to set xml output directory in OSG_autoconf (PR #319) +- Allow OSG_autoconf to skip sites or CEs that are not present in the OSG collector (PR #315) ### Changed defaults / behaviours @@ -27,7 +29,7 @@ Changes since the last release - Fixing Python 3.9 deprecations (`imp`, `getchildren()` in `xml.etree.ElementTree`) (PR #302, PR #303) - Populate missing Entry parameters for ARC CEs submissions (PR #304) - Modified the usage of subprocess module, for building/rebuilding cvmfsexec distributions, only when necessary (PR #309) -- manual_glidein_submit now correctly sets idtokens in the EncryptedInputFiles (issue #283, PR#284) +- manual_glidein_submit now correctly sets idtokens in the EncryptedInputFiles (issue #283, PR #284) ### Testing / Development @@ -176,8 +178,8 @@ Changes since the last release ### New features / functionalities -- Add option to set xml output directory in OSG_autoconf (PR #319) -- Allow OSG_autoconf to skip sites or CEs that are not present in the OSR collector (PR #315) +- item one of the list +- item N ### Changed defaults / behaviours diff --git a/factory/tools/OSG_autoconf.py b/factory/tools/OSG_autoconf.py index 38eae1d1e..616d3a31a 100644 --- a/factory/tools/OSG_autoconf.py +++ b/factory/tools/OSG_autoconf.py @@ -635,7 +635,7 @@ def create_missing_file_internal(missing_info, osg_info, whitelist_info, osg_col def main(args): """The main""" config = get_yaml_file_info(args.config[0]) - xmloutdir = config.get('XML_OUTDIR', None) + xmloutdir = config.get("XML_OUTDIR", None) try: # Queries the OSG collector result = get_information(config["OSG_COLLECTOR"]) @@ -658,7 +658,7 @@ def main(args): # Convert the resoruce dictionary obtained this way into a string (xml) entries_configuration = get_entries_configuration(result) # Write the factory configuration file on the disk - xmloutdir = os.path.dirname(white_list) if xmloutdir==None else xmloutdir + xmloutdir = os.path.dirname(white_list) if xmloutdir == None else xmloutdir filename = os.path.basename(white_list.replace("yml", "xml")) write_to_xml_file(os.path.join(xmloutdir, filename), entries_configuration)