Last active
October 12, 2021 16:35
-
-
Save robrich/bc05df2270402dfbfd988666af57e81f to your computer and use it in GitHub Desktop.
MemSQL Vagrant Dev Cluster
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
# See docs for more: | |
# https://docs.memsql.com/v7.0/guides/deploy-memsql/self-managed/memsql-tools/single-host/native/step-2/ | |
# https://docs.memsql.com/v7.0/guides/deploy-memsql/self-managed/cluster-configuration/system-requirements/ | |
wget -O - 'https://release.memsql.com/release-aug2018.gpg' 2>/dev/null | apt-key add - | |
apt-key list | |
apt install -y apt-transport-https | |
echo "deb [arch=amd64] https://release.memsql.com/production/debian memsql main" | tee /etc/apt/sources.list.d/memsql.list | |
apt update | |
apt install -y memsql-toolbox memsql-client memsql-studio | |
systemctl start memsql-studio |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
memsql-deploy cluster-in-a-box --license "YOUR_LICENSE_KEY" --password "ANY_ADMIN_PASSWORD" --bind-address 0.0.0.0 -y |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Vagrant.configure("2") do |config| | |
config.vm.box = "generic/ubuntu1904" | |
# set the provider | |
config.vm.provider "virtualbox" | |
# configure the provider | |
config.vm.provider "virtualbox" do |v| | |
v.cpus = 4 | |
v.memory = 4096 | |
end | |
# 3306 is the database engine, 8080 is MemSQL Studio | |
config.vm.network "forwarded_port", guest: 3306, host: 3306 | |
config.vm.network "forwarded_port", guest: 8080, host: 8080 | |
# share current folder so scripts are available | |
config.vm.synced_folder ".", "/vagrant", disabled: false | |
config.vm.provision "shell", path: "provision.sh" | |
config.vm.provision "shell", privileged: false, inline: "/bin/bash --login /vagrant/start.sh" | |
end |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Vagrant.configure("2") do |config| | |
config.vm.box = "generic/ubuntu1904" | |
# set the provider | |
config.vm.provider "hyperv" | |
# configure the provider | |
config.vm.provider "hyperv" do |v| | |
v.cpus = 4 | |
v.memory = 4096 | |
v.maxmemory = 4096 | |
v.enable_virtualization_extensions = true # hyperv only | |
end | |
# 3306 is the database engine, 8080 is MemSQL Studio | |
config.vm.network "forwarded_port", guest: 3306, host: 3306 | |
config.vm.network "forwarded_port", guest: 8080, host: 8080 | |
# share current folder so scripts are available | |
config.vm.synced_folder ".", "/vagrant", disabled: false | |
config.vm.provision "shell", path: "provision.sh" | |
config.vm.provision "shell", privileged: false, inline: "/bin/bash --login /vagrant/start.sh" | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment