blob: 33cdc7e675bf989483790953f0896148ff599fca (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
|
#!/bin/sh
set -eux
apt update
apt install -y apt-utils
mkdir -p -- /var/shione/debian/pool/main
cp -- /tmp/shione/build/*.deb /var/shione/debian/pool/main
# XXX: Stolen from `local-apt-repository` which did not work for me for some reason.
debs_dir_path=/var/shione/debian
deb_repo_path=/var/lib/local-apt-repository
mkdir -p -- "$deb_repo_path"
# Relative paths work better than absolute
cd -- "$deb_repo_path"
apt-ftparchive packages ../../../"$debs_dir_path" >"$deb_repo_path"/Packages
apt-ftparchive sources ../../../"$debs_dir_path" >"$deb_repo_path"/Sources
apt-ftparchive \
-o "APT::FTPArchive::Release::Origin=local-apt-repository-shione" \
-o "APT::FTPArchive::Release::Description=Local repository created by a minimal version of local-apt-repository" \
release "$deb_repo_path" > "$deb_repo_path"/Release
<<-EOF cat -- >/etc/apt/sources.list.d/local-apt-repository.list
# This enables the local repositories provided by local-apt-repository
#
# We do not use cryptographic signatures, as they are read from local system
# anyways.
deb [trusted=yes] file:///var/lib/local-apt-repository/ ./
deb-src [trusted=yes] file:///var/lib/local-apt-repository/ ./
EOF
apt update
apt install -y nftables-config
|