2bb2f918ee
A recent patch[1] added --pbkdf-memory to the cryptsetup command line to limit the memory cryptsetup is using. However, some distros use an older version of cryptsetup that does not need this setting. This patch adds logic to detect this and run the commands without --pbkdf-memory. [1] https://review.opendev.org/663784 Change-Id: I9e0debcbfe6ceeff0012c827d70d80d938b5a2fb Story: 2006066 Task: 34782
15 lines
368 B
Plaintext
15 lines
368 B
Plaintext
description "Creates an encrypted ramfs for Octavia certs"
|
|
|
|
start on started cloud-config
|
|
stop on runlevel [!2345]
|
|
|
|
pre-start script
|
|
/usr/local/bin/certfs-ramfs
|
|
end script
|
|
|
|
post-stop script
|
|
certs_path=$(awk "/base_cert_dir / {printf \$3}" /etc/octavia/amphora-agent.conf)
|
|
umount "${certs_path}"
|
|
cryptsetup luksClose /dev/mapper/certfs-ramfs
|
|
end script
|