Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
Gravwell Vagrantfile - just "vagrant up"
Vagrant.configure("2") do |config|
config.vm.box = "ubuntu/xenial64"
# progressbar via https://askubuntu.com/questions/445245/how-do-i-enable-fancy-apt-colours-and-progress-bars
# from https://dev.gravwell.io/docs/#!quickstart/quickstart.md
$script = <<SCRIPT
mkdir -p /etc/apt/apt.conf.d
echo 'Dpkg::Progress-Fancy "1";' > /etc/apt/apt.conf.d/99progressbar
curl -Ls https://update.gravwell.io/debian/update.gravwell.io.gpg.key | apt-key add -
# Add the repository
echo 'deb [ arch=amd64 ] https://update.gravwell.io/debian/ community main' > /etc/apt/sources.list.d/gravwell.list
apt-get install apt-transport-https
apt-get update
curl -sLO https://update.gravwell.io/files/gravwell_2.2.4.sh
chmod a+x gravwell_2.2.4.sh
NO_ASK=yes ./gravwell_2.2.4.sh
echo "To get your license file, head on over to https://www.gravwell.io/gravwell-community-edition and fill out the form. Logbot will email one to you shortly therafter."
SCRIPT
config.vm.provision "shell", inline: $script
config.vm.hostname = "gravwell"
config.vm.network :forwarded_port, host: 4443, guest: 443
end
@nma-io

This comment has been minimized.

Copy link

commented Jul 17, 2018

EDIT: This won't work - they declare NO_ASK in the middle of the script which will overwrite the env variable. ... May need to pass with the --no-questions and use the installer file rather than apt?

untested - this could work: env NO_ASK=yes apt-get install gravwell
The NO_ASK is how the stand alone installer works:

displayEULA() {
        EULA_LOC="$1"
        if [ "$NO_ASK" != "yes" ]; then
                cat $EULA_LOC
                echo "Do you accept the EULA as displayed and agree to its license?"
                getYesOrNo
                if [ "$yesno" != "y" ]; then
                        echo "Terminating installation"
                        exit -1
                fi
        else
                echo "EULA accepted via --no-questions"
        fi
}
@traetox

This comment has been minimized.

Copy link

commented Jul 17, 2018

Should be fixed in 2.1.1 that was just pushed out. Thanks for the heads up!

@paralax

This comment has been minimized.

Copy link
Owner Author

commented Jul 17, 2018

thanks all, you were able to help me fix this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.