integ/ldap/ldapscripts/files/install-ldapscripts-files-to-etc.patch
Bin Qian 54f2f7d6c6 Make /usr readonly to support OSTree
OSTree structure requires /usr to be readonly as OSTree's dracut
hook creates a read-only bind mount over /usr.

1. deploy validate_postgresql_connection.sh directly to
   /usr/local/bin. It was copied to the location after
   installation.
2. move /usr/local/etc/ldapscripts to /etc/ldapscripts, files
   need writable.
3. move /usr/libexec/cni to /opt/cni/bin. Plugins are installed
   at runtime.

TCs:
   provision aio-dx centos with /usr mount to readonly fs.
   unlocked host
   provision aio-sx debian and unlocked host.
   upgrade AIO-DX from 21.12
   upgrade AIO-SX from 21.12
   successfully apply cert-manager and nginx-ingress-controller

Story: 2009101
Task: 44314

Change-Id: I99231f3f7db3d2d8eaceba137e13dea650370f71
Signed-off-by: Bin Qian <bin.qian@windriver.com>
2022-04-29 11:19:37 -04:00

39 lines
1.2 KiB
Diff

From ff3f64dadeb81a9224acaf62ce564d940f582d7c Mon Sep 17 00:00:00 2001
From: Bin Qian <bin.qian@windriver.com>
Date: Fri, 29 Apr 2022 10:54:08 -0400
Subject: [PATCH] install ldapscripts files to /etc
Deploy ldapscripts config files to /etc/ldapscripts as it was done
originally. We no longer need to use sed to modify the path.
Signed-off-by: Bin Qian <bin.qian@windriver.com>
---
Makefile | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
index 6e5b193..7585602 100644
--- a/Makefile
+++ b/Makefile
@@ -30,7 +30,7 @@ VERSION = 2.0.8
# Default installation paths
SBINDIR = $(PREFIX)/sbin
MANDIR = $(PREFIX)/man
-ETCDIR = $(PREFIX)/etc/$(NAME)
+ETCDIR = /etc/$(NAME)
LIBDIR = $(PREFIX)/lib/$(NAME)
# Files to install
@@ -85,7 +85,7 @@ help:
configure:
@echo -n 'Configuring scripts... '
@sed 's|^BINDPWDFILE=.*|BINDPWDFILE="$(ETCDIR)/$(PWDFILE)"|g' 'etc/$(ETCFILE)' > 'etc/$(ETCFILE).patched'
- @sed '/^_CONFIGFILE=/s|^\(.*"\).*\(".*\)|\1$(ETCDIR)/$(ETCFILE)\2|g' 'lib/$(RUNFILE)' > 'lib/$(RUNFILE).patched'
+ @cp 'lib/$(RUNFILE)' 'lib/$(RUNFILE).patched'
@for i in $(SBINFILES) ; do \
sed 's|^_RUNTIMEFILE=.*|_RUNTIMEFILE="$(LIBDIR)/$(RUNFILE)"|g' "sbin/$$i" > "sbin/$$i.patched" ; \
done
--
2.29.2