boxcutter/ubuntu

Custom 'script' is not persisted on Packer and Vagrant doesn´t display them when using Vagrantfile

joudaon opened this issue · 5 comments

Hello,

Thank for this project.

I have used this code to make an own custom devops environment (https://github.com/joudaon/vagrant-devops).

On the script folder I have added an script devops_tools.sh to install custom software (please see the script on: https://github.com/joudaon/vagrant-devops/blob/master/vagrant/provision/devops_tools.sh). And of course this script has been added to ubuntu.json file.

I want all these programs to be installed on the "box" packer build so that when I create a new Vagrantfile the software is already installed and I don´t have to provision it.

The thing is that when I create a new Vagrantfile and use that box, Ubuntu Destkop doesn´t display that installed software and that's why I have to provision devops_tools.sh on the Vagrant side and not on the Packer.

Any clue why this is happening?

Thank you.

Hi @boxcutter-robot I have tried that and didn´t work.

The devops_tools.sh script is run and packer builds box file for vagrant.

But when running, vagrant up none of the tools of that script are present.

Well, I placed devops_tools.sh just after motd.sh script. It must be placed after cleanup.sh?

Thank you.

I will try running devops_tools.sh just after cleanup.sh and let you know.

Thank you.

I tried running devops_tools.sh just after cleanup.sh and didn´t work neither... :(

I don´t know how to handle this, it should work and install those programs and they should be available on the base box.