#!/bin/sh
set -e

TARGET='/target'
DISTNAME="$(cat ${TARGET}/etc/astra_version | cut -f3 -d' ' | cut -f2 -d'(' | cut -f1 -d')')"

mkdir -p "${TARGET}/etc/apt"

if [ "$DISTNAME" = "orel" ]; then
    echo 'deb https://dl.astralinux.ru/astra/stable/2.12_x86-64/repository/ orel main contrib non-free' > "${TARGET}/etc/apt/sources.list"
fi
