I'm creating an AWS instance and I'm trying to run a Vault server when created. My problem is that creation process doesn't ever finish, because the server is not running on background. This is my configuration:

```
resource "aws_instance" "web" {
  ami           = "ami-466768ac"
  instance_type = "t2.micro"
  key_name = "my_key"

  tags {
    Name = "Vault"
  }

  provisioner "remote-exec" {

    connection {
      type        = "ssh"
      agent       = false
      user        = "ec2-user"
      private_key = "${file("/path/to/my_key")}"
    }

    inline = [
      "curl -O https://releases.hashicorp.com/vault/0.10.4/vault_0.10.4_linux_amd64.zip",
      "unzip vault_0.10.4_linux_amd64.zip",
      "./vault server -dev -dev-listen-address=0.0.0.0:8200"
    ]
  }

}

```

Basically, I'm downloading Vault via `curl` and running a dev server. Server is actually run (I see it in the terminal logs), but instance creation (by Terraform) never finishes:

```
aws_instance.web: Still creating... (40s elapsed)
aws_instance.web: Still creating... (50s elapsed)
aws_instance.web: Still creating... (1m0s elapsed)
aws_instance.web: Still creating... (1m10s elapsed)
aws_instance.web: Still creating... (1m20s elapsed)
aws_instance.web: Still creating... (1m30s elapsed)
...

```

I have tried to add `&` at the end of the starting Vault server command, in order to not to block the shell but, when I do that, the instance is created but Vault server is not actually started.

How can I start the server in background mode on instance creation?

**EDIT**

I have also tried with `nohup`:

```
nohup ./vault server -dev -dev-listen-address=0.0.0.0:8200

```

But server is not started when terraform finishes...