From 5e77461e847bdc3804eedfc49d434b8e2747c2f0 Mon Sep 17 00:00:00 2001 From: Kristoff Kiefer Date: Wed, 14 Aug 2024 11:38:04 +0200 Subject: [PATCH 1/3] Added UCS Schema --- .../custom_schema_ldifs/ucs_mail.ldif | 18 ++++++++++++++++++ charts/dbildungs-iam-ldap/values.yaml | 9 ++++----- 2 files changed, 22 insertions(+), 5 deletions(-) create mode 100644 charts/dbildungs-iam-ldap/templates/custom_schema_ldifs/ucs_mail.ldif diff --git a/charts/dbildungs-iam-ldap/templates/custom_schema_ldifs/ucs_mail.ldif b/charts/dbildungs-iam-ldap/templates/custom_schema_ldifs/ucs_mail.ldif new file mode 100644 index 0000000..81071fa --- /dev/null +++ b/charts/dbildungs-iam-ldap/templates/custom_schema_ldifs/ucs_mail.ldif @@ -0,0 +1,18 @@ +dn: cn=ucsMail,cn=schema,cn=config +objectClass: olcSchemaConfig +cn: ucsMail +olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.41 NAME 'univentionCanonicalSenderRewriteEnabled' + DESC 'rewrite sender addresses?' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{10} SINGLE-VALUE ) +olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.42 NAME 'univentionCanonicalRecipientRewriteEnabled' + DESC 'rewrite recipient addresses?' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{10} SINGLE-VALUE ) +olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.43 NAME 'univentionInternalPrimaryMailAddress' + DESC 'primary mail address of user' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} SINGLE-VALUE ) +olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.44 NAME 'univentionInternalAlternativeMailAddress' + DESC 'additional mail addresses' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} + ) +olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.45 NAME 'univentionPublicPrimaryMailAddress' DESC 'public mail address of user' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} SINGLE-VALUE ) +olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.46 NAME 'univentionPublicAlternativeMailAddress' DESC 'additional mail addresses' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} ) +olcObjectClasses: ( 1.3.6.1.4.1.10176.1010.2.40 NAME 'univentionMailCanonicalMaps' + DESC 'data for rewriting mail addresses' + SUP top + AUXILIARY MAY ( univentionCanonicalSenderRewriteEnabled $ univentionCanonicalRecipientRewriteEnabled $ univentionInternalPrimaryMailAddress $ univentionInternalAlternativeMailAddress $ univentionPublicPrimaryMailAddress $ univentionPublicAlternativeMailAddress ) ) diff --git a/charts/dbildungs-iam-ldap/values.yaml b/charts/dbildungs-iam-ldap/values.yaml index fda991f..c59ed6b 100644 --- a/charts/dbildungs-iam-ldap/values.yaml +++ b/charts/dbildungs-iam-ldap/values.yaml @@ -95,11 +95,10 @@ pdb: # Custom openldap schema files used to be used in addition to default schemas # Note that the supplied files are sorted by name and inserted into 'LDAP_EXTRA_SCHEMAS' env var # after chart default schemas, allowing you to control the loading sequence. -# customSchemaFiles: -# custom.ldif: |- -# # custom schema -# anothercustom.ldif: |- -# # another custom schema +customSchemaFiles: + ucs_mail.ldif: |- + {{ .Files.Get "custom_schema_ldifs/ucs_mail.ldif" }} + # Custom openldap configuration files used to override default settings From 2cacd069f2be2db557b31487a281bb930ec8973f Mon Sep 17 00:00:00 2001 From: Kristoff Kiefer Date: Wed, 14 Aug 2024 11:50:17 +0200 Subject: [PATCH 2/3] Wrong dir --- .../{templates => }/custom_schema_ldifs/ucs_mail.ldif | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename charts/dbildungs-iam-ldap/{templates => }/custom_schema_ldifs/ucs_mail.ldif (100%) diff --git a/charts/dbildungs-iam-ldap/templates/custom_schema_ldifs/ucs_mail.ldif b/charts/dbildungs-iam-ldap/custom_schema_ldifs/ucs_mail.ldif similarity index 100% rename from charts/dbildungs-iam-ldap/templates/custom_schema_ldifs/ucs_mail.ldif rename to charts/dbildungs-iam-ldap/custom_schema_ldifs/ucs_mail.ldif From 00f24388d37e0a58c429559992f396a7b7daa163 Mon Sep 17 00:00:00 2001 From: Kristoff Kiefer Date: Wed, 14 Aug 2024 12:35:27 +0200 Subject: [PATCH 3/3] File replacements don't work in values --- .../custom_schema_ldifs/ucs_mail.ldif | 18 ----------------- charts/dbildungs-iam-ldap/values.yaml | 20 ++++++++++++++++++- 2 files changed, 19 insertions(+), 19 deletions(-) delete mode 100644 charts/dbildungs-iam-ldap/custom_schema_ldifs/ucs_mail.ldif diff --git a/charts/dbildungs-iam-ldap/custom_schema_ldifs/ucs_mail.ldif b/charts/dbildungs-iam-ldap/custom_schema_ldifs/ucs_mail.ldif deleted file mode 100644 index 81071fa..0000000 --- a/charts/dbildungs-iam-ldap/custom_schema_ldifs/ucs_mail.ldif +++ /dev/null @@ -1,18 +0,0 @@ -dn: cn=ucsMail,cn=schema,cn=config -objectClass: olcSchemaConfig -cn: ucsMail -olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.41 NAME 'univentionCanonicalSenderRewriteEnabled' - DESC 'rewrite sender addresses?' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{10} SINGLE-VALUE ) -olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.42 NAME 'univentionCanonicalRecipientRewriteEnabled' - DESC 'rewrite recipient addresses?' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{10} SINGLE-VALUE ) -olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.43 NAME 'univentionInternalPrimaryMailAddress' - DESC 'primary mail address of user' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} SINGLE-VALUE ) -olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.44 NAME 'univentionInternalAlternativeMailAddress' - DESC 'additional mail addresses' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} - ) -olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.45 NAME 'univentionPublicPrimaryMailAddress' DESC 'public mail address of user' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} SINGLE-VALUE ) -olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.46 NAME 'univentionPublicAlternativeMailAddress' DESC 'additional mail addresses' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} ) -olcObjectClasses: ( 1.3.6.1.4.1.10176.1010.2.40 NAME 'univentionMailCanonicalMaps' - DESC 'data for rewriting mail addresses' - SUP top - AUXILIARY MAY ( univentionCanonicalSenderRewriteEnabled $ univentionCanonicalRecipientRewriteEnabled $ univentionInternalPrimaryMailAddress $ univentionInternalAlternativeMailAddress $ univentionPublicPrimaryMailAddress $ univentionPublicAlternativeMailAddress ) ) diff --git a/charts/dbildungs-iam-ldap/values.yaml b/charts/dbildungs-iam-ldap/values.yaml index c59ed6b..82e41e8 100644 --- a/charts/dbildungs-iam-ldap/values.yaml +++ b/charts/dbildungs-iam-ldap/values.yaml @@ -97,7 +97,25 @@ pdb: # after chart default schemas, allowing you to control the loading sequence. customSchemaFiles: ucs_mail.ldif: |- - {{ .Files.Get "custom_schema_ldifs/ucs_mail.ldif" }} + dn: cn=ucsMail,cn=schema,cn=config + objectClass: olcSchemaConfig + cn: ucsMail + olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.41 NAME 'univentionCanonicalSenderRewriteEnabled' + DESC 'rewrite sender addresses?' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{10} SINGLE-VALUE ) + olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.42 NAME 'univentionCanonicalRecipientRewriteEnabled' + DESC 'rewrite recipient addresses?' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{10} SINGLE-VALUE ) + olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.43 NAME 'univentionInternalPrimaryMailAddress' + DESC 'primary mail address of user' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} SINGLE-VALUE ) + olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.44 NAME 'univentionInternalAlternativeMailAddress' + DESC 'additional mail addresses' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} + ) + olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.45 NAME 'univentionPublicPrimaryMailAddress' DESC 'public mail address of user' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} SINGLE-VALUE ) + olcAttributeTypes: ( 1.3.6.1.4.1.10176.1010.1.46 NAME 'univentionPublicAlternativeMailAddress' DESC 'additional mail addresses' EQUALITY caseIgnoreMatch SUBSTR caseIgnoreSubstringsMatch SYNTAX 1.3.6.1.4.1.1466.115.121.1.15{256} ) + olcObjectClasses: ( 1.3.6.1.4.1.10176.1010.2.40 NAME 'univentionMailCanonicalMaps' + DESC 'data for rewriting mail addresses' + SUP top + AUXILIARY MAY ( univentionCanonicalSenderRewriteEnabled $ univentionCanonicalRecipientRewriteEnabled $ univentionInternalPrimaryMailAddress $ univentionInternalAlternativeMailAddress $ univentionPublicPrimaryMailAddress $ univentionPublicAlternativeMailAddress ) ) +