Skip to content

Commit 158c96f

Browse files
committed
Add service dependencies for openvswitch-ipsec.service
The openvswitch-ipsec must be started only after ipsec.service and it has to be up before crio and kubelet service, so add appropriate systemd service dependencies for openvswitch-ipsec.service. It also removes a workaround that was needed in ipsec-connect-wait script to explicitly trigger pluto to establish IPSec IKE SAs with peer nodes. Signed-off-by: Periyasamy Palanisamy <[email protected]>
1 parent 3bf1842 commit 158c96f

File tree

3 files changed

+8
-8
lines changed

3 files changed

+8
-8
lines changed

templates/common/_base/files/wait-for-ipsec-connect.yaml

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,15 +9,8 @@ contents:
99
exit 0
1010
fi
1111
12-
#
13-
if ! grep -q "auto=start" /etc/ipsec.d/openshift.conf; then
14-
sed -i '/^.*conn ovn.*$/a\ auto=start' /etc/ipsec.d/openshift.conf
15-
fi
16-
1712
cat /etc/ipsec.d/openshift.conf
1813
19-
chroot /proc/1/root ipsec restart
20-
2114
timeout=180
2215
elapsed=0
2316
desiredconn=""
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
name: openvswitch-ipsec.service
2+
dropins:
3+
- name: 01-after-pluto-start.conf
4+
contents: |
5+
[Unit]
6+
After=ipsec.service
7+
Before=crio.service

templates/common/_base/units/wait-for-ipsec-connect.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ enabled: true
33
contents: |
44
[Unit]
55
Description=Ensure IKE SA established for existing IPsec connections.
6-
After=ipsec.service
6+
After=openvswitch-ipsec.service
77
Before=kubelet-dependencies.target node-valid-hostname.service
88
99
[Service]

0 commit comments

Comments
 (0)