Terraform file locations in Morpheus

I often get asked where are all the Terraform files stored in Morpheus. I created this cheat sheet that hopefully helps.



Terraform File Locations in Morpheus


in the examples below

repo = f7435f67e448c6653af9ed683682b7dd
app = app-dcbb2660-50dd-4715-825c-289f2b40552c

/var/opt/morpheus/morpheus-ui/workspace/terraform

  • All TF Repos /var/opt/morpheus/morpheus-ui/workspace/terraform

    • /var/opt/morpheus/morpheus-ui/workspace/terraform/f7435f67e448c6653af9ed683682b7dd
      ( all apps of repo f7435f67e448c6653af9ed683682b7dd)
  • TF App Files /var/opt/morpheus/morpheus-ui/workspace/terraform/f7435f67e448c6653af9ed683682b7dd/app-dcbb2660-50dd-4715-825c-289f2b40552c

    • morpheus.tfplan
    • tfvars
    • .terraform
      • providers
      • modules
    • terraform.tfstate
    • terraform.tfstate.backup
  • plugin-cache /var/opt/morpheus/morpheus-ui/workspace/terraform/plugin-cache

    • linux_386
    • linux_amd64
    • registry.terraform.io
  • runtime /var/opt/morpheus/morpheus-ui/workspace/terraform/runtime
    (each TF version specified on an app or spec will be stored here)

    • 0.12.31
    • 0.15.5
    • 1.0.1
    • etc

/var/opt/morpheus/morpheus-local/repo (This is where all the .tf code files will get stored)

  • git (If TF is using a git repo ) /var/opt/morpheus/morpheus-local/repo/git
    • cloned repo with TF files ‘/var/opt/morpheus/morpheus-local/repo/git/f7435f67e448c6653af9ed683682b7dd’
  • local (If TF is using a local TF) /var/opt/morpheus/morpheus-local/repo/local
    • local .tf file
3 Likes