From 8d561817d56eb7f2be05cf6a31b284c640f966c3 Mon Sep 17 00:00:00 2001 From: Sthopeless Date: Fri, 7 May 2021 16:03:22 +0200 Subject: [PATCH] Initial commit --- create_container.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/create_container.sh b/create_container.sh index 92c6f9d..4539891 100644 --- a/create_container.sh +++ b/create_container.sh @@ -131,6 +131,7 @@ ROOTFS=${STORAGE}:${DISK_REF-}${DISK} # Create LXC msg "Creating LXC container..." DISK_SIZE=8G +MEMORY_RAM=4098 pvesm alloc $STORAGE $CTID $DISK $DISK_SIZE --format ${DISK_FORMAT:-raw} >/dev/null if [ "$STORAGE_TYPE" == "zfspool" ]; then warn "Some containers may not work properly due to ZFS not supporting 'fallocate'." @@ -142,7 +143,7 @@ HOSTNAME=Gitlab TEMPLATE_STRING="local:vztmpl/${TEMPLATE}" pct create $CTID $TEMPLATE_STRING -arch $ARCH -features nesting=1 \ -hostname $HOSTNAME -net0 name=eth0,bridge=vmbr0,ip=dhcp -onboot 1 \ - -ostype $OSTYPE -rootfs $ROOTFS,size=$DISK_SIZE -storage $STORAGE >/dev/null + -ostype $OSTYPE -rootfs $ROOTFS,size=$DISK_SIZE -storage $STORAGE, -memory $MEMORY_RAM >/dev/null # Modify LXC permissions to support Docker LXC_CONFIG=/etc/pve/lxc/${CTID}.conf