)]}'
{"elements/certs-ramfs/init-scripts/systemd/certs-ramfs.service":[{"author":{"_account_id":10273,"name":"Adam Harwell","email":"flux.adam@gmail.com","username":"rm_you"},"change_message_id":"308da484447854df0a39bc02aef16d556aedb40f","unresolved":false,"context_lines":[{"line_number":5,"context_line":"[Service]"},{"line_number":6,"context_line":"Type\u003doneshot"},{"line_number":7,"context_line":"ExecStart\u003d/bin/sh -c \u0027modprobe brd; passphrase\u003d$$(head /dev/urandom | tr -dc \"a-zA-Z0-9\" | fold -w 32 | head -n 1); certs_path\u003d$$(awk \"/base_cert_dir / {printf \\\\$$3}\" /etc/octavia/amphora-agent.conf); mkdir -p \"$${certs_path}\"; echo -n \"$${passphrase}\" | cryptsetup luksFormat /dev/ram0 -; echo -n \"$${passphrase}\" | cryptsetup luksOpen /dev/ram0 certfs-ramfs -; mkfs.ext2 /dev/mapper/certfs-ramfs; mount /dev/mapper/certfs-ramfs \"$${certs_path}\"\u0027"},{"line_number":8,"context_line":"ExecStop\u003d/bin/sh -c \u0027certs_path\u003d$$(awk \"/base_cert_dir / {printf \\\\$$3}\" /etc/octavia/amphora-agent.conf); umount \"$${certs_path}\"; cryptsetup luksClose /dev/mapper/certfs-ramfs;\u0027"},{"line_number":9,"context_line":"RemainAfterExit\u003dyes"},{"line_number":10,"context_line":"TimeoutSec\u003d0"},{"line_number":11,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"ff346bd7_970e1c39","line":8,"updated":"2017-07-26 05:49:39.000000000","message":"I don\u0027t understand this at all... Why do we need to double up on all this stuff? In my testing I was able to do this:\n\necho \"hi \u003d 1\" \u003e /tmp/myfile\n/bin/sh -c \u0027a\u003d$(awk \"/hi/ {print \\$3}\" /tmp/myfile); echo $a\u0027\n\nSo from what I understand, we should be REMOVING some of the doubled-up dollar-signs and such, not adding more? Is this something to do with systemd?","commit_id":"bb1c16b165c25da9b6e0d608403d8793f52461c7"},{"author":{"_account_id":21798,"name":"Bernard Cafarelli","email":"bcafarel@redhat.com","username":"bcafarel"},"change_message_id":"46cb1afe37cc5c0eab72faf65d18aa2844acf084","unresolved":false,"context_lines":[{"line_number":5,"context_line":"[Service]"},{"line_number":6,"context_line":"Type\u003doneshot"},{"line_number":7,"context_line":"ExecStart\u003d/bin/sh -c \u0027modprobe brd; passphrase\u003d$$(head /dev/urandom | tr -dc \"a-zA-Z0-9\" | fold -w 32 | head -n 1); certs_path\u003d$$(awk \"/base_cert_dir / {printf \\\\$$3}\" /etc/octavia/amphora-agent.conf); mkdir -p \"$${certs_path}\"; echo -n \"$${passphrase}\" | cryptsetup luksFormat /dev/ram0 -; echo -n \"$${passphrase}\" | cryptsetup luksOpen /dev/ram0 certfs-ramfs -; mkfs.ext2 /dev/mapper/certfs-ramfs; mount /dev/mapper/certfs-ramfs \"$${certs_path}\"\u0027"},{"line_number":8,"context_line":"ExecStop\u003d/bin/sh -c \u0027certs_path\u003d$$(awk \"/base_cert_dir / {printf \\\\$$3}\" /etc/octavia/amphora-agent.conf); umount \"$${certs_path}\"; cryptsetup luksClose /dev/mapper/certfs-ramfs;\u0027"},{"line_number":9,"context_line":"RemainAfterExit\u003dyes"},{"line_number":10,"context_line":"TimeoutSec\u003d0"},{"line_number":11,"context_line":""}],"source_content_type":"application/octet-stream","patch_set":1,"id":"ff346bd7_db3a8a96","line":8,"in_reply_to":"ff346bd7_970e1c39","updated":"2017-07-26 09:12:03.000000000","message":"Indeed this is systemd-specific (the init scripts for other init systems do not have these double chars).\nThe warning is logged in \"journalctl -u certs-ramfs.service\", and the related systemd doc: https://www.freedesktop.org/software/systemd/man/systemd.service.html#Command%20lines\n\"In particular, any backslashes should be doubled\"\n\"To pass a literal dollar sign, use \"$$\".\"","commit_id":"bb1c16b165c25da9b6e0d608403d8793f52461c7"}]}
