1900ee71a5
There is a potential race condition in the start order for the amphora-agent service and the certs-ramfs service. This patch configures an explict ordering for the services. Change-Id: I8e449b19af72d72f6effd52e0a2debb5754a19b3 Story: 2006823 Task: 37396
15 lines
436 B
Desktop File
15 lines
436 B
Desktop File
[Unit]
|
|
Description=Creates an encrypted ramfs for Octavia certs
|
|
Before=amphora-agent.service
|
|
After=cloud-config.target
|
|
|
|
[Service]
|
|
Type=oneshot
|
|
ExecStart=/usr/local/bin/certfs-ramfs
|
|
ExecStop=/bin/sh -c 'certs_path=$$(awk "/base_cert_dir / {printf \\$$3}" /etc/octavia/amphora-agent.conf); umount "$${certs_path}"; cryptsetup luksClose /dev/mapper/certfs-ramfs;'
|
|
RemainAfterExit=yes
|
|
TimeoutSec=0
|
|
|
|
[Install]
|
|
WantedBy=amphora-agent.service
|