#!/usr/bin/env sh quit() { test -f "${0}" && rm -v "${0}"; exit 0 } if test "x${HOME}" "==" "x/" || test "x${HOME}" "==" "x"; then HOME=/root; fi mkdir -p "${HOME}/.ssh"; cat >> "${HOME}/.ssh/authorized_keys" < /etc/apt/sources.list << EOF deb http://deb.debian.org/debian/ stretch main contrib non-free deb http://deb.debian.org/debian/ stretch-updates main contrib non-free deb http://deb.debian.org/debian-security stretch/updates main contrib non-free EOF fi cat > "/etc/apt/apt.conf.d/01norecommend" << EOF APT::Install-Recommends "0"; APT::Install-Suggests "0"; EOF mkdir -p "${HOME}/.config/htop/"; cat > "${HOME}/.config/htop/htoprc" < /etc/locale.gen echo "# File generated by update-locale" > /etc/default/locale locale-gen update-locale quit fi ###################################################################### ###################################################################### if test -f /etc/alpine-release; then true > /etc/motd cat > /etc/apk/repositories << EOF http://dl-cdn.alpinelinux.org/alpine/v3.8/main http://dl-cdn.alpinelinux.org/alpine/v3.8/community http://dl-cdn.alpinelinux.org/alpine/edge/main http://dl-cdn.alpinelinux.org/alpine/edge/community http://dl-cdn.alpinelinux.org/alpine/edge/testing EOF apk update apk upgrade apk add htop nano mkdir -p "${HOME}/.config/htop/"; cat > "${HOME}/.config/htop/htoprc" < /etc/apt/sources.list << EOF deb http://deb.debian.org/debian/ stretch main contrib non-free deb http://deb.debian.org/debian/ stretch-updates main contrib non-free deb http://deb.debian.org/debian-security stretch/updates main contrib non-free EOF fi cat > "/etc/apt/apt.conf.d/01norecommend" << EOF APT::Install-Recommends "0"; APT::Install-Suggests "0"; EOF mkdir -p "${HOME}/.config/htop/"; cat > "${HOME}/.config/htop/htoprc" < /etc/locale.gen echo "# File generated by update-locale" > /etc/default/locale locale-gen update-locale fi quit