I am manually testing it.. below is my provisioner and log..
"provisioners": [{
"type": "shell",
"pause_before": "30s",
"inline": [
"curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo
apt-key add -",
"sudo add-apt-repository \"deb [arch=amd64]
https://download.docker.com/linux/ubuntu bionic stable\"",
"sudo apt-get update",
"sudo apt-get install -y docker-ce",
"sudo usermod -aG docker ubuntu",
"curl -sSL http://sjeeva.github.io/getcompose | sudo sh",
"sudo mkdir /data",
"sudo systemctl stop docker",
"sudo systemctl disable docker",
"sudo cp /tmp/docker.service /lib/systemd/system/docker.service"
]
}]
amazon-ebs: docker-compose version 1.24.1, build 4667896b is installed
==> amazon-ebs: Synchronizing state of docker.service with SysV service
script with /lib/systemd/systemd-sysv-install.
==> amazon-ebs: Executing: /lib/systemd/systemd-sysv-install disable docker
==> amazon-ebs: Pausing after run of step 'StepProvision'. Press enter to
continue.
On Monday, July 22, 2019 at 11:47:22 PM UTC+5:30, Rickard von Essen wrote:
>
> Could you provide details of what you have done and how you verified it?
>
> On Mon, Jul 22, 2019, 19:56 Jeeva Chelladhurai <[email protected]
> <javascript:>> wrote:
>
>> Hello All,
>>
>> I am building an AMI using packer. I want to install docker on my target
>> image however the docker should be in stopped state. In my provisioner I
>> have stopped and disabled the docker service, nonetheless, when I launch a
>> new VM the docker service is enabled and running.
>>
>> Please guide me how to disable a service in packer.
>>
>> I'm building an ubuntu 18.04 image.
>>
>> Thanks,
>> Jeeva'
>>
>> --
>> This mailing list is governed under the HashiCorp Community Guidelines -
>> https://www.hashicorp.com/community-guidelines.html. Behavior in
>> violation of those guidelines may result in your removal from this mailing
>> list.
>>
>> GitHub Issues: https://github.com/mitchellh/packer/issues
>> IRC: #packer-tool on Freenode
>> ---
>> You received this message because you are subscribed to the Google Groups
>> "Packer" group.
>> To unsubscribe from this group and stop receiving emails from it, send an
>> email to [email protected] <javascript:>.
>> To view this discussion on the web visit
>> https://groups.google.com/d/msgid/packer-tool/8a9941fd-76ee-4e04-8061-35ee2b4f8966%40googlegroups.com
>>
>> <https://groups.google.com/d/msgid/packer-tool/8a9941fd-76ee-4e04-8061-35ee2b4f8966%40googlegroups.com?utm_medium=email&utm_source=footer>
>> .
>>
>
--
This mailing list is governed under the HashiCorp Community Guidelines -
https://www.hashicorp.com/community-guidelines.html. Behavior in violation of
those guidelines may result in your removal from this mailing list.
GitHub Issues: https://github.com/mitchellh/packer/issues
IRC: #packer-tool on Freenode
---
You received this message because you are subscribed to the Google Groups
"Packer" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
To view this discussion on the web visit
https://groups.google.com/d/msgid/packer-tool/e3691a88-091d-4208-b89f-eaedd6358d2d%40googlegroups.com.