2

I have a very simple terraform configuration. I boot up an aws instance of Ubuntu trusty and assign a security group.

My question is who is responsible of getting the latest code from my code repo? is it a bash script in terraform user_data argument or should I make a modified AMI that has a bash script to pull the code repo.

Basically my repo has docker configuration in it and all i need is to clone and do docker-compose -f env.yml up

Hakim
  • 121
  • 1

1 Answers1

1

You can achieve the clone of the repo and the execution of docker-compose in several ways.

You are right when you think that cloud-init could do that. Check this link for more information

RuBiCK
  • 305
  • 1
  • 13