#!/bin/bash

set -e
set -x

export DEBIAN_FRONTEND=noninteractive

groupadd rkt || true
gpasswd -a ubuntu rkt || true

DEBIAN_FRONTEND=noninteractive apt-get update -y
DEBIAN_FRONTEND=noninteractive apt-get dist-upgrade -y --force-yes
DEBIAN_FRONTEND=noninteractive apt-get install -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confnew" -y --force-yes build-essential autoconf
DEBIAN_FRONTEND=noninteractive apt-get install -o Dpkg::Options::="--force-confdef" -o Dpkg::Options::="--force-confnew" -y --force-yes wget squashfs-tools patch gnupg golang dbus libacl1-dev systemd-container libssl-dev libsystemd-dev libpam-systemd
