• listless@lemmy.cringecollective.io
    link
    fedilink
    arrow-up
    2
    ·
    edit-2
    2 months ago

    And there’s your problem. You’re echoing using double quotes which will interpret characters. Don’t do that. That’s a bug. cat or cp the file to the destination; printf if the contents are all in that variable.

    • aidan@lemmy.worldOP
      link
      fedilink
      arrow-up
      1
      ·
      2 months ago

      No, you’re still misunderstanding what’s being done. ${server_service} is an injected string, the string is the whole contents of the file. That file is not stored locally on the server, except through being injected here(by a terraform file template). And no, printf won’t be any better than echo because its not format string, and I don’t want any formatting from printf applied to it.