This commit is contained in:
2022-12-13 00:12:20 +00:00
parent 0dbb1ed83f
commit 7d2beca0ca

View File

@@ -1,15 +1,19 @@
#!/bin/bash
#start container
echo "$1"
echo "$2"
#lxc launch ubuntu $1 -p $2
echo "container name: $1"
echo "profile: $2"
#set docker requirements
echo "starting container"
lxc launch ubuntu $1 -p $2
echo "setting lxc docker requirements"
curl -s "https://git.limbosolutions.com/kb/lxc/raw/branch/main/scripts/lxc-config-docker-requirements.sh" | bash -s $1
lxc restart $1
lxc exec $1 -- bash -c "apt update -y && apt upgrade -y"
#setup docker
echo "updating apt"
lxc exec $1 -- sh -c "apt-get update -qq >/dev/null"
echo "upgrading apt"
lxc exec $1 -- sh -c "apt-get upgrade -qq >/dev/null"
echo "install fuse & docker"
lxc exec $1 -- bash -c "curl -s \"https://git.limbosolutions.com/kb/docker/raw/branch/main/scripts/ubuntu-fuse-setup.sh\" | bash"
#portainer