building repository pakete distr0-0.4.4_1 riseup-vpn-0.4.4_1
Some checks failed
continuous-integration/drone/push Build is failing
Some checks failed
continuous-integration/drone/push Build is failing
This commit is contained in:
parent
86fa56c677
commit
66a18489cf
37
.drone.yml
Normal file
37
.drone.yml
Normal file
@ -0,0 +1,37 @@
|
|||||||
|
kind: pipeline
|
||||||
|
name: always
|
||||||
|
|
||||||
|
clone:
|
||||||
|
depth: 10
|
||||||
|
|
||||||
|
volumes:
|
||||||
|
- name: dronecache
|
||||||
|
host:
|
||||||
|
path: /home/xo/dronecache
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: build
|
||||||
|
image: ghcr.io/void-linux/void-linux:20210312rc01-full-x86_64
|
||||||
|
pull: always
|
||||||
|
privileged: true
|
||||||
|
commands:
|
||||||
|
- 'sh /files/bin/init.sh'
|
||||||
|
- 'bash /files/bin/autobuild.sh'
|
||||||
|
- 'bash /files/bin/cleanup.sh'
|
||||||
|
volumes:
|
||||||
|
- name: dronecache
|
||||||
|
path: /files
|
||||||
|
|
||||||
|
- name: notify
|
||||||
|
image: drillster/drone-email
|
||||||
|
pull: always
|
||||||
|
when:
|
||||||
|
status: [ success, changed, failure ]
|
||||||
|
settings:
|
||||||
|
host: mail.tzend.de
|
||||||
|
from: drone@tzend.de
|
||||||
|
username:
|
||||||
|
from_secret: email_username
|
||||||
|
password:
|
||||||
|
from_secret: email_password
|
||||||
|
|
42
srcpkgs/distr0/INSTALL
Normal file
42
srcpkgs/distr0/INSTALL
Normal file
@ -0,0 +1,42 @@
|
|||||||
|
# INSTALL
|
||||||
|
|
||||||
|
do_that() {
|
||||||
|
if [ -f etc/default/grub-btrfs/config ]; then
|
||||||
|
if ! grep -q void.conf etc/default/grub-btrfs/config; then
|
||||||
|
echo "file=\"/etc/default/grub-btrfs/void.conf\"" >> etc/default/grub-btrfs/config
|
||||||
|
echo '[ -f "${file}" ] && . "${file}"' >> etc/default/grub-btrfs/config
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if [ -f etc/void-snapshot.cfg ]; then
|
||||||
|
if ! grep -q -e NO_UPDATE_GRUB -e REGULAR_SNAPSHOT_HOME etc/void-snapshot.cfg; then
|
||||||
|
rm etc/void-snapshot.cfg
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
if [ -e var/spool/cron/root ]; then
|
||||||
|
if ! grep -q "#void.system" var/spool/cron/root; then
|
||||||
|
echo '0 * * * * /usr/bin/void-snapshot cron #void.system' >> var/spool/cron/root
|
||||||
|
else
|
||||||
|
if grep "#void.system" var/spool/cron/root | grep -q "^#"; then
|
||||||
|
sed -i '/#void.system/d' var/spool/cron/root
|
||||||
|
echo '#0 * * * * /usr/bin/void-snapshot cron #void.system' >> var/spool/cron/root
|
||||||
|
else
|
||||||
|
sed -i '/#void.system/d' var/spool/cron/root
|
||||||
|
echo '0 * * * * /usr/bin/void-snapshot cron #void.system' >> var/spool/cron/root
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
case "$ACTION" in
|
||||||
|
pre)
|
||||||
|
#Actions here
|
||||||
|
;;
|
||||||
|
post)
|
||||||
|
do_that
|
||||||
|
if [ "$UPDATE" = "yes" ]; then
|
||||||
|
echo update
|
||||||
|
else
|
||||||
|
echo new install
|
||||||
|
fi
|
||||||
|
;;
|
||||||
|
esac
|
13
srcpkgs/distr0/files/bash/editor.sh
Normal file
13
srcpkgs/distr0/files/bash/editor.sh
Normal file
@ -0,0 +1,13 @@
|
|||||||
|
if command -v nano > /dev/null; then
|
||||||
|
e=nano
|
||||||
|
elif command -v nvim > /dev/null; then
|
||||||
|
e=nvim
|
||||||
|
elif command -v vim > /dev/null; then
|
||||||
|
e=vim
|
||||||
|
fi
|
||||||
|
|
||||||
|
export EDITOR="${e}"
|
||||||
|
export VISUAL="${e}"
|
||||||
|
export SUDO_EDITOR="${e}"
|
||||||
|
unset e
|
||||||
|
|
12
srcpkgs/distr0/files/bash/xbps-aliase.sh
Normal file
12
srcpkgs/distr0/files/bash/xbps-aliase.sh
Normal file
@ -0,0 +1,12 @@
|
|||||||
|
[ "$(id -u)" -eq 0 ] && return
|
||||||
|
alias xu="sudo void-update"
|
||||||
|
alias xr="sudo xbps-remove -R"
|
||||||
|
alias xs="xbps-query -Rs"
|
||||||
|
alias xq="xbps-query"
|
||||||
|
alias backup="sudo void-backup"
|
||||||
|
alias snapshot="sudo void-snapshot"
|
||||||
|
|
||||||
|
|
||||||
|
echo "Tippe 'helpme' für weitere Hilfe!"
|
||||||
|
echo "Have a nice Day!"
|
||||||
|
echo ""
|
8
srcpkgs/distr0/files/bin/change_luks_pw
Normal file
8
srcpkgs/distr0/files/bin/change_luks_pw
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if ! [ "$(id -u)" -eq 0 ]; then
|
||||||
|
echo "Not root. Use: sudo $(basename $0)"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
cryptsetup luksChangeKey $(cryptsetup status $(lvdisplay -m $(findmnt -vn -o SOURCE -T /)|grep "Physical volume"|awk '{print $3}')|grep device|awk '{print $2}')
|
15
srcpkgs/distr0/files/bin/helpme
Normal file
15
srcpkgs/distr0/files/bin/helpme
Normal file
@ -0,0 +1,15 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
clear
|
||||||
|
cat << EOF
|
||||||
|
xu updaten
|
||||||
|
xi "Paketname" installieren
|
||||||
|
xr "Paketname" deinstallieren
|
||||||
|
xs "Suchbegriff" suchen
|
||||||
|
|
||||||
|
|
||||||
|
passwd Passwort des Nutzers $USER ändern
|
||||||
|
change_luks_pw Passwort der Systemfestplatte ändern
|
||||||
|
backup Backup machen oder einrichten
|
||||||
|
snapshot Snapshots einstellen
|
||||||
|
|
||||||
|
EOF
|
41
srcpkgs/distr0/files/bin/joinvpn
Normal file
41
srcpkgs/distr0/files/bin/joinvpn
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
basewgfolder="/etc/wireguard"
|
||||||
|
|
||||||
|
if [ $UID -ne 0 ]; then
|
||||||
|
echo "Keine Rootrechte"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
umask 0077
|
||||||
|
mkdir -p "${basewgfolder}/wg0"
|
||||||
|
cd "${basewgfolder}/wg0"
|
||||||
|
|
||||||
|
|
||||||
|
if [[ -f "${basewgfolder}/wg0/privkey" ]]; then
|
||||||
|
read -p "Address: " ADDRESS
|
||||||
|
read -p "PublicKey: " PUBKEY_SERVER
|
||||||
|
read -p "Endpoint: " ENDPOINT
|
||||||
|
read -p "Port: " PORT
|
||||||
|
{ echo "[Interface]";
|
||||||
|
echo "Address = ${ADDRESS}";
|
||||||
|
echo "PostUp = wg set %i private-key /etc/wireguard/wg0/wg0.key <(cat /etc/wireguard/wg0/privkey)";
|
||||||
|
echo "[Peer]";
|
||||||
|
echo "PublicKey = ${PUBKEY_SERVER}";
|
||||||
|
echo "Endpoint = ${ENDPOINT}:${PORT}";
|
||||||
|
echo "AllowedIPs = fd23::23:0:0/96";
|
||||||
|
echo "PresharedKey = $(cat psk)";
|
||||||
|
echo "PersistentKeepalive = 25"; } > "${basewgfolder}/wg0.conf"
|
||||||
|
else
|
||||||
|
test -f privkey || wg genkey > privkey
|
||||||
|
test -f pubkey || wg pubkey < privkey > pubkey
|
||||||
|
test -f psk || wg genpsk > psk
|
||||||
|
echo "Frage O nach den den folgenden Daten und wenn du sie hast, starte das hier nochmal"
|
||||||
|
echo "Address"
|
||||||
|
echo "PublicKey"
|
||||||
|
echo "Endpoint"
|
||||||
|
echo "Port"
|
||||||
|
echo ""
|
||||||
|
echo "Schicke ihm verschlüsselt (Matrix oder Email) folgende Daten:"
|
||||||
|
echo "PublicKey = $(cat pubkey)"
|
||||||
|
echo "PresharedKey = $(cat psk)"
|
||||||
|
echo "Hostname = ${HOSTNAME}"
|
||||||
|
fi
|
22
srcpkgs/distr0/files/bin/pinentry-chooser
Executable file
22
srcpkgs/distr0/files/bin/pinentry-chooser
Executable file
@ -0,0 +1,22 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
case $PINENTRY_USER_DATA in
|
||||||
|
tty)
|
||||||
|
exec pinentry-curses "$@"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
if ! test -x ~/.config/pinentry; then
|
||||||
|
for i in pinentry-kwallet pinentry-qt pinentry-gnome3 pinentry-gtk-2 pinentry-emacs pinentry-dmenu pinentry-curses pinentry-tty; do
|
||||||
|
if command -v "${i}" > /dev/null; then
|
||||||
|
echo "#!/bin/sh" > ~/.config/pinentry
|
||||||
|
echo "${i} \${@}" >> ~/.config/pinentry
|
||||||
|
chmod +x ~/.config/pinentry
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
fi
|
||||||
|
|
||||||
|
exec ~/.config/pinentry "$@"
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
132
srcpkgs/distr0/files/bin/void-backup
Executable file
132
srcpkgs/distr0/files/bin/void-backup
Executable file
@ -0,0 +1,132 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
export LANG="en_US.UTF-8"
|
||||||
|
backupcfg="/etc/backup.cfg"
|
||||||
|
ziel="/var/lib/backup/ziel"
|
||||||
|
cfg="/etc/btrbk/btrbk.conf.void"
|
||||||
|
|
||||||
|
fhelp() {
|
||||||
|
echo "Nutze es so:"
|
||||||
|
echo "sudo backup"
|
||||||
|
echo "sudo backup poweroff (um den Rechner nach dem Backup herunterzufahren.)"
|
||||||
|
#echo "sudo backup update (um den Rechner nach dem Backup up zu daten.)"
|
||||||
|
#echo "update und poweroff sind mixbar"
|
||||||
|
echo "sudo backup passwd (um das Passwort für die Backupfestplatte zu ändern.)"
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ "${UID}" -ne "0" ]; then
|
||||||
|
echo "Keine Rootrechte."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
for argval in "$@"
|
||||||
|
do
|
||||||
|
case "${argval}" in
|
||||||
|
power|poweroff|p)
|
||||||
|
poweroff=y
|
||||||
|
;;
|
||||||
|
help|-h|--help|h)
|
||||||
|
fhelp
|
||||||
|
exit
|
||||||
|
;;
|
||||||
|
update) update=y ;;
|
||||||
|
passwd) passwd=y ;;
|
||||||
|
clean) do=clean ;;
|
||||||
|
run) do=run ;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
test -z "${do}" && do=run
|
||||||
|
|
||||||
|
if [[ ! -f /etc/btrbk/btrbk.conf ]]; then
|
||||||
|
if [[ -f "${backupcfg}" ]]; then
|
||||||
|
source "${backupcfg}"
|
||||||
|
else
|
||||||
|
echo "${backupcfg} fehlt."
|
||||||
|
echo "Diese Datei wird normalerweise durch \`void-createbackupcontainer\`"
|
||||||
|
echo "angelegt. Bitte Sprich mit deinem Systemadministrator."
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -z "${UUID}" ]; then
|
||||||
|
echo "Keine Backupplatte angegeben."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ ! -e "/dev/disk/by-uuid/${UUID}" ]; then
|
||||||
|
echo "Bitte Backupfestplatte anschliessen."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ -e /tmp/backup ]; then
|
||||||
|
echo "Es läuft schon ein Backupvorgang oder wurde nicht richtig beendet."
|
||||||
|
echo "Bei letzterem: 'sudo rm -rf /tmp/backup'"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
touch /tmp/backup
|
||||||
|
|
||||||
|
if [[ "${passwd}" == "y" ]]; then
|
||||||
|
cryptsetup luksChangeKey "/dev/disk/by-uuid/${UUID}"
|
||||||
|
rm -rf /tmp/backup
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
|
||||||
|
function finish {
|
||||||
|
sync
|
||||||
|
if [ "${poweroff}" = "y" ]; then
|
||||||
|
shutdown -h now
|
||||||
|
fi
|
||||||
|
sleep 4
|
||||||
|
umount "${ziel}"
|
||||||
|
echo " "
|
||||||
|
echo " "
|
||||||
|
if [[ "${MOUNTEDBY}" == "script" ]]; then
|
||||||
|
cryptsetup close "luks-${UUID}"
|
||||||
|
echo "Festplatte kann nun sicher entfernt werden."
|
||||||
|
elif [[ "${MOUNTEDBY}" == "de" ]]; then
|
||||||
|
echo "Festplatte bitte mit der grafischen Oberflaeche auswerfen (wie ein USB-Stick)"
|
||||||
|
echo ""
|
||||||
|
echo "oder:"
|
||||||
|
echo "sudo umount /dev/mapper/luks-${UUID}"
|
||||||
|
echo "sudo cryptsetup close luks-${UUID}"
|
||||||
|
echo ""
|
||||||
|
fi
|
||||||
|
rm -rf /tmp/backup
|
||||||
|
echo "FERTIG"
|
||||||
|
|
||||||
|
}
|
||||||
|
trap finish EXIT
|
||||||
|
|
||||||
|
if mountpoint -q -x "/dev/mapper/luks-${UUID}" > /dev/null; then
|
||||||
|
MOUNTEDBY="de"
|
||||||
|
else
|
||||||
|
if ! cryptsetup open UUID="${UUID}" "luks-${UUID}"; then
|
||||||
|
echo "Konnte /dev/disk/by-uuid/${UUID} nicht öffnen."
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
MOUNTEDBY="script"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! mount "/dev/mapper/luks-${UUID}" "${ziel}"; then
|
||||||
|
echo "Konnte /dev/mapper/luks-${UUID} in ${ziel} nicht mounten."
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
cfg="/etc/btrbk/btrbk.conf"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if mountpoint -q /var/lib/backup/quelle/bootfs; then
|
||||||
|
mkdir -p /var/lib/backup/quelle/bootfs/system/backup "/var/lib/backup/ziel/void/bootfs"
|
||||||
|
boot="backupboot"
|
||||||
|
fi
|
||||||
|
|
||||||
|
mkdir -p /var/lib/backup/quelle/rootfs/system/backup "/var/lib/backup/ziel/void/rootfs" "/var/lib/backup/ziel/void/homefs"
|
||||||
|
for t in backup "${boot}"; do
|
||||||
|
if [[ "${t}" ]]; then
|
||||||
|
btrbk --config="${cfg}" --progress --quiet clean "${t}"
|
||||||
|
if ! btrbk --config="${cfg}" --progress --quiet "${do}" "${t}"; then
|
||||||
|
btrbk --config="${cfg}" --progress --quiet clean
|
||||||
|
echo "Wegen Fehler nicht herunterfahren."
|
||||||
|
poweroff=n
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
done
|
86
srcpkgs/distr0/files/bin/void-createbackupcontainer
Executable file
86
srcpkgs/distr0/files/bin/void-createbackupcontainer
Executable file
@ -0,0 +1,86 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
backupcfg="/etc/backup.cfg"
|
||||||
|
|
||||||
|
if [ $UID -ne 0 ]; then
|
||||||
|
echo "Keine Rootrechte."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
input() {
|
||||||
|
output=""
|
||||||
|
echo "${1}"
|
||||||
|
read -r -p "[${2}]: " output
|
||||||
|
test -z "${output}" && output="${2}"
|
||||||
|
return 0
|
||||||
|
}
|
||||||
|
|
||||||
|
multiplechoice() {
|
||||||
|
output=""
|
||||||
|
local done=""
|
||||||
|
local input=("${@}")
|
||||||
|
#for i in $(seq 1 "$(( ${#input[@]} - 1 ))"); do
|
||||||
|
for i in $(seq 0 "$(( ${#input[@]} - 1 ))"); do
|
||||||
|
if [[ "${i}" == "0" ]]; then
|
||||||
|
choices="${input[$i]}"
|
||||||
|
use="${input[$i]}"
|
||||||
|
else
|
||||||
|
choices="${choices}|${input[$i]}"
|
||||||
|
use+=" ${input[$i]}"
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
while input "[${choices}]: " "${input[0]}"; do
|
||||||
|
for i in $(seq 0 "${#input[@]}"); do
|
||||||
|
if [[ "${output}" == "${input[$i]}" ]] || [[ "${output}" == "${input[$i]:0:2}" ]]; then
|
||||||
|
output="${input[$i]}"
|
||||||
|
done=1
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
if [[ -z "${done}" ]]; then
|
||||||
|
echo wronginput "${output}"
|
||||||
|
echo use these: "${use}"
|
||||||
|
else
|
||||||
|
break
|
||||||
|
fi
|
||||||
|
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
echo "Bitte Backupgerät noch nicht anschliessen!"
|
||||||
|
read
|
||||||
|
DISKS_DETAILS=$(lsblk -l -o KNAME,TYPE,SIZE,MODEL|grep disk)
|
||||||
|
echo "${DISKS_DETAILS}"
|
||||||
|
echo ""
|
||||||
|
echo "Nun das Gerät anschliessen und das neue in der Liste auswaehlen"
|
||||||
|
read
|
||||||
|
DISKS_DETAILS=$(lsblk -l -o KNAME,TYPE,SIZE,MODEL|grep disk)
|
||||||
|
echo "${DISKS_DETAILS}"
|
||||||
|
multiplechoice $(echo "${DISKS_DETAILS}"|awk '{print $1}')
|
||||||
|
TARGET_PHY_DISK="/dev/${output}"
|
||||||
|
|
||||||
|
parted -a optimal "${TARGET_PHY_DISK}" -s -- mklabel gpt
|
||||||
|
sleep 5
|
||||||
|
parted -a optimal "${TARGET_PHY_DISK}" unit mib -s -- mkpart backup btrfs 1 100%
|
||||||
|
sleep 5
|
||||||
|
sync
|
||||||
|
|
||||||
|
if ! cryptsetup luksFormat "${TARGET_PHY_DISK}1"; then
|
||||||
|
echo "Konnte ${TARGET_PHY_DISK} nicht verschluesseln."
|
||||||
|
exit 1
|
||||||
|
else
|
||||||
|
UUID="$(lsblk -l -o KNAME,UUID | grep "$(basename ${TARGET_PHY_DISK})1"|awk '{print $2}')"
|
||||||
|
if ! cryptsetup open "/dev/disk/by-uuid/${UUID}" "luks-${UUID}"; then
|
||||||
|
echo "Konnte /dev/disk/by-uuid/${UUID} nicht oeffnen."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if ! mkfs.btrfs -f "/dev/mapper/luks-${UUID}"; then
|
||||||
|
echo "Konnte /dev/mapper/luks-${UUID} nicht formatieren"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
cryptsetup close "luks-${UUID}"
|
||||||
|
|
||||||
|
echo "UUID=\"${UUID}\"" > "${backupcfg}"
|
||||||
|
|
||||||
|
echo "Erstellen des Containers fertig."
|
85
srcpkgs/distr0/files/bin/void-snapshot
Normal file
85
srcpkgs/distr0/files/bin/void-snapshot
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
if [ "${UID}" -ne "0" ]; then
|
||||||
|
echo "Keine Rootrechte."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
infos() {
|
||||||
|
echo "Snapshots sind Kopien der Dateien die keinen zusätzlichen Platz"
|
||||||
|
echo "benötigen."
|
||||||
|
echo ""
|
||||||
|
echo "Es wird bei jedem Update vom Betriebsystem ein Snapshot angelegt."
|
||||||
|
echo "Es wird jede volle Stunde vom Betriebsystem ein Snapshot angelegt."
|
||||||
|
echo "So ist das Betriebssystem auch bei Problemen bootbar."
|
||||||
|
echo ""
|
||||||
|
echo "Optional kann auch jede Stunde ein Snapshot der persönlichen Daten"
|
||||||
|
echo "angelegt werden. Dann verliert man bei versehentlichem löschen"
|
||||||
|
echo "maximal die Arbeit einer Stunde."
|
||||||
|
echo "Dafür folgendes im Terminal ausführen:"
|
||||||
|
echo 'echo REGULAR_SNAPSHOT_HOME=1 | sudo tee -a /etc/void-snapshot.cfg'
|
||||||
|
echo ""
|
||||||
|
echo "Nur für Experten:"
|
||||||
|
echo 'echo NO_UPDATE_GRUB=1 | sudo tee -a /etc/void-snapshot.cfg'
|
||||||
|
}
|
||||||
|
|
||||||
|
cron=""
|
||||||
|
update=""
|
||||||
|
case $1 in
|
||||||
|
update)
|
||||||
|
update=1
|
||||||
|
word="update"
|
||||||
|
;;
|
||||||
|
cron)
|
||||||
|
cron=1
|
||||||
|
word="regular"
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
infos
|
||||||
|
exit
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
|
||||||
|
if [ "$#" -eq "0" ]; then
|
||||||
|
infos
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
|
cfg="/etc/btrbk/btrbk.conf.void"
|
||||||
|
test -f "/etc/btrbk/btrbk.conf" && cfg="/etc/btrbk/btrbk.conf"
|
||||||
|
|
||||||
|
if mountpoint -q /var/lib/backup/quelle/bootfs; then
|
||||||
|
mkdir -p "/var/lib/backup/quelle/bootfs/system/snapshots/${word}"
|
||||||
|
if ! btrbk --config="${cfg}" --quiet run "${word}boot"; then
|
||||||
|
btrbk --config="${cfg}" --quiet clean "${word}boot"
|
||||||
|
echo "fail: btrbk --config=${cfg} --quiet run ${word}boot"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
mkdir -p "/var/lib/backup/quelle/rootfs/system/snapshots/${word}"
|
||||||
|
if ! btrbk --config="${cfg}" --quiet run "${word}root"; then
|
||||||
|
btrbk --config="${cfg}" --quiet clean "${word}root"
|
||||||
|
echo "fail: btrbk --config=${cfg} --quiet run ${word}root"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
|
test -f /etc/void-snapshot.cfg && . /etc/void-snapshot.cfg
|
||||||
|
|
||||||
|
if [[ -z "${NO_UPDATE_GRUB}" ]]; then
|
||||||
|
if ! update-grub 2> /dev/null; then
|
||||||
|
echo update-grub failed
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ "${cron}" ]; then
|
||||||
|
if [ "${REGULAR_SNAPSHOT_HOME}" ]; then
|
||||||
|
mkdir -p "/var/lib/backup/quelle/rootfs/system/snapshots/${word}"
|
||||||
|
if ! btrbk --config="${cfg}" --quiet run "${word}home"; then
|
||||||
|
btrbk --config="${cfg}" --quiet clean "${word}home"
|
||||||
|
echo "fail: btrbk --config=${cfg} --quiet clean ${word}home"
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
74
srcpkgs/distr0/files/bin/void-update
Executable file
74
srcpkgs/distr0/files/bin/void-update
Executable file
@ -0,0 +1,74 @@
|
|||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
if [ $UID -ne 0 ]; then
|
||||||
|
echo "Keine Rootrechte."
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
RESTART=""
|
||||||
|
|
||||||
|
set -Eeuo pipefail
|
||||||
|
|
||||||
|
RESTART=
|
||||||
|
echo "Synchronisiere Repositorys."
|
||||||
|
xbps-install -S > /dev/null
|
||||||
|
|
||||||
|
#mapfile -t updatedpkgs < <(xbps-install -un|awk '{print $1}')
|
||||||
|
updatedpkgs="$(xbps-install -un|awk '{print $1}')"
|
||||||
|
|
||||||
|
if [[ -z "${updatedpkgs}" ]]; then
|
||||||
|
echo "Keine Updates"
|
||||||
|
exit
|
||||||
|
else
|
||||||
|
echo "${updatedpkgs}"
|
||||||
|
echo "Es sind Updates da!"
|
||||||
|
while read -p "Installieren? [Y/n] " answer; do
|
||||||
|
test -z "${answer}" && answer="y"
|
||||||
|
case "${answer}" in
|
||||||
|
n*|N*|*o|*O)
|
||||||
|
exit
|
||||||
|
;;
|
||||||
|
y*|Y*|j*|J*)
|
||||||
|
break
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
if grep -q -Pe '^(?!.*linux-).*^linux' <<< "${updatedpkgs}"; then
|
||||||
|
RESTART=1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "Lege Snapshot an."
|
||||||
|
void-snapshot update
|
||||||
|
|
||||||
|
echo "Entferne nicht benutzte Pakete."
|
||||||
|
xbps-remove -oy > /dev/null
|
||||||
|
|
||||||
|
echo "Räume den Cache auf."
|
||||||
|
xbps-remove -Oy > /dev/null
|
||||||
|
|
||||||
|
echo "Installiere Updates."
|
||||||
|
if ! xbps-install -uy; then
|
||||||
|
echo "Update failed."
|
||||||
|
exit
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "$RESTART" ]]; then
|
||||||
|
echo "Lösche alte Kernel."
|
||||||
|
vkpurge list | head -n -1 | xargs -r vkpurge rm
|
||||||
|
else
|
||||||
|
echo "Überprüfe ob neustart notwenidig ist."
|
||||||
|
if [[ "$(xcheckrestart)" ]]; then
|
||||||
|
RESTART=1
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [[ "${RESTART}" ]]; then
|
||||||
|
echo ""; echo "Bitte den Computer neu starten!"
|
||||||
|
else
|
||||||
|
echo ""; echo "Kein neustart notwendig!"
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo ""
|
||||||
|
echo "Update fertig."
|
||||||
|
|
78
srcpkgs/distr0/files/btrbk/btrbk.conf.void
Normal file
78
srcpkgs/distr0/files/btrbk/btrbk.conf.void
Normal file
@ -0,0 +1,78 @@
|
|||||||
|
transaction_syslog daemon
|
||||||
|
lockfile /tmp/btrbk.lock
|
||||||
|
incremental yes
|
||||||
|
btrfs_commit_delete after
|
||||||
|
timestamp_format long
|
||||||
|
noauto yes
|
||||||
|
backend btrfs-progs-sudo
|
||||||
|
|
||||||
|
# Update snapshots
|
||||||
|
volume /var/lib/backup/quelle/bootfs
|
||||||
|
group updateboot updatestats allstats snapshotstats
|
||||||
|
snapshot_dir system/snapshots/update
|
||||||
|
snapshot_preserve_min latest
|
||||||
|
snapshot_preserve no
|
||||||
|
subvolume bootfs
|
||||||
|
|
||||||
|
volume /var/lib/backup/quelle/rootfs
|
||||||
|
group updateroot updatestats allstats snapshotstats
|
||||||
|
snapshot_dir system/snapshots/update
|
||||||
|
snapshot_preserve_min latest
|
||||||
|
snapshot_preserve no
|
||||||
|
subvolume rootfs
|
||||||
|
|
||||||
|
|
||||||
|
# Regular snapshots
|
||||||
|
volume /var/lib/backup/quelle/bootfs
|
||||||
|
group regularboot regularstats allstats snapshotstats
|
||||||
|
snapshot_dir system/snapshots/regular
|
||||||
|
snapshot_preserve_min 4h
|
||||||
|
snapshot_preserve no
|
||||||
|
subvolume bootfs
|
||||||
|
|
||||||
|
volume /var/lib/backup/quelle/rootfs
|
||||||
|
group regularroot regularstats allstats snapshotstats
|
||||||
|
snapshot_dir system/snapshots/regular
|
||||||
|
snapshot_preserve_min 4h
|
||||||
|
snapshot_preserve no
|
||||||
|
subvolume rootfs
|
||||||
|
|
||||||
|
volume /var/lib/backup/quelle/rootfs
|
||||||
|
group regularhome regularstats allstats snapshotstats
|
||||||
|
snapshot_dir system/snapshots/regular
|
||||||
|
snapshot_preserve_min 4h
|
||||||
|
snapshot_preserve no
|
||||||
|
subvolume homefs
|
||||||
|
|
||||||
|
|
||||||
|
# Backup
|
||||||
|
volume /var/lib/backup/quelle/bootfs
|
||||||
|
group backupboot backupstats allstats
|
||||||
|
snapshot_dir system/backup
|
||||||
|
snapshot_preserve_min latest
|
||||||
|
snapshot_preserve no
|
||||||
|
target_preserve_min latest
|
||||||
|
target_preserve no
|
||||||
|
subvolume bootfs
|
||||||
|
target send-receive /var/lib/backup/ziel/void/bootfs
|
||||||
|
|
||||||
|
volume /var/lib/backup/quelle/rootfs
|
||||||
|
group backup backupstats allstats
|
||||||
|
snapshot_dir system/backup
|
||||||
|
snapshot_preserve_min latest
|
||||||
|
snapshot_preserve no
|
||||||
|
target_preserve_min latest
|
||||||
|
target_preserve no
|
||||||
|
subvolume rootfs
|
||||||
|
target send-receive /var/lib/backup/ziel/void/rootfs
|
||||||
|
|
||||||
|
volume /var/lib/backup/quelle/rootfs
|
||||||
|
group backup backupstats allstats
|
||||||
|
snapshot_dir system/backup
|
||||||
|
snapshot_preserve_min latest
|
||||||
|
snapshot_preserve no
|
||||||
|
target_preserve_min latest
|
||||||
|
target_preserve no
|
||||||
|
subvolume homefs
|
||||||
|
target send-receive /var/lib/backup/ziel/void/homefs
|
||||||
|
|
7
srcpkgs/distr0/files/gnupg/gpg-agent.conf
Executable file
7
srcpkgs/distr0/files/gnupg/gpg-agent.conf
Executable file
@ -0,0 +1,7 @@
|
|||||||
|
pinentry-program /usr/bin/pinentry-chooser
|
||||||
|
enable-ssh-support
|
||||||
|
|
||||||
|
default-cache-ttl 28800
|
||||||
|
max-cache-ttl 86400
|
||||||
|
ignore-cache-for-signing
|
||||||
|
|
19
srcpkgs/distr0/files/grub-btrfs/void.conf
Normal file
19
srcpkgs/distr0/files/grub-btrfs/void.conf
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
# Ignore specific path during run "grub-mkconfig".
|
||||||
|
# Only exact paths are ignored.
|
||||||
|
# e.g : if `specific path` = @, only `@` snapshot will be ignored.
|
||||||
|
# Default: ("@")
|
||||||
|
GRUB_BTRFS_IGNORE_SPECIFIC_PATH=("@" "rootfs" "bootfs" "homefs")
|
||||||
|
|
||||||
|
# Ignore prefix path during run "grub-mkconfig".
|
||||||
|
# Any path starting with the specified string will be ignored.
|
||||||
|
# e.g : if `prefix path` = @, all snapshots beginning with "@/..." will be ignored.
|
||||||
|
# Default: ("var/lib/docker" "@var/lib/docker" "@/var/lib/docker")
|
||||||
|
GRUB_BTRFS_IGNORE_PREFIX_PATH=("var/lib/docker" "@var/lib/docker" "@/var/lib/docker" "system/backup")
|
||||||
|
|
||||||
|
GRUB_BTRFS_SUBMENUNAME="Void Linux Snapshots"
|
||||||
|
GRUB_BTRFS_OVERRIDE_BOOT_PARTITION_DETECTION="true"
|
||||||
|
GRUB_BTRFS_DISPLAY_PATH_SNAPSHOT="false"
|
||||||
|
GRUB_BTRFS_TITLE_FORMAT="d"
|
||||||
|
GRUB_BTRFS_LIMIT="20"
|
21
srcpkgs/distr0/files/nm/30-wg0
Executable file
21
srcpkgs/distr0/files/nm/30-wg0
Executable file
@ -0,0 +1,21 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
INTERFACE=$1
|
||||||
|
ACTION=$2
|
||||||
|
|
||||||
|
if [ -f /etc/wireguard/wg0.conf ]; then
|
||||||
|
case "$INTERFACE" in
|
||||||
|
tun*|wg*)
|
||||||
|
exit 0
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
case "$ACTION" in
|
||||||
|
up)
|
||||||
|
wg-quick up wg0
|
||||||
|
;;
|
||||||
|
down)
|
||||||
|
wg-quick down wg0
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
;;
|
||||||
|
esac
|
||||||
|
fi
|
2
srcpkgs/distr0/files/nm/dns-servers.conf
Normal file
2
srcpkgs/distr0/files/nm/dns-servers.conf
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
[global-dns-domain-*]
|
||||||
|
servers=::1,159.69.114.157
|
3
srcpkgs/distr0/files/nm/unmanaged-tun.conf
Normal file
3
srcpkgs/distr0/files/nm/unmanaged-tun.conf
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
[keyfile]
|
||||||
|
unmanaged-devices=interface-name:wg*
|
||||||
|
|
3
srcpkgs/distr0/files/nm/unmanaged-wg.conf
Normal file
3
srcpkgs/distr0/files/nm/unmanaged-wg.conf
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
[keyfile]
|
||||||
|
unmanaged-devices=interface-name:wg*
|
||||||
|
|
8
srcpkgs/distr0/files/pipewire/start-pipewire-pulse.conf
Normal file
8
srcpkgs/distr0/files/pipewire/start-pipewire-pulse.conf
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
context.exec = [
|
||||||
|
# You can optionally start the pulseaudio-server here as well
|
||||||
|
# but it is better to start it as a systemd service.
|
||||||
|
# It can be interesting to start another daemon here that listens
|
||||||
|
# on another address with the -a option (eg. -a tcp:4713).
|
||||||
|
#
|
||||||
|
{ path = "/usr/bin/pipewire-pulse" args = "" }
|
||||||
|
]
|
16
srcpkgs/distr0/files/profile/append-path.sh
Normal file
16
srcpkgs/distr0/files/profile/append-path.sh
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
appendpath () {
|
||||||
|
case ":$PATH:" in
|
||||||
|
*:"$1":*)
|
||||||
|
;;
|
||||||
|
*)
|
||||||
|
PATH="${PATH:+$PATH:}$1"
|
||||||
|
esac
|
||||||
|
}
|
||||||
|
|
||||||
|
if [ $(id -u) -eq 0 ]; then
|
||||||
|
appendpath "/root/.local/bin"
|
||||||
|
else
|
||||||
|
appendpath "/home/$(id -un)/.local/bin"
|
||||||
|
fi
|
||||||
|
export PATH
|
||||||
|
|
9
srcpkgs/distr0/files/sudoers/10-common
Normal file
9
srcpkgs/distr0/files/sudoers/10-common
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
Defaults timestamp_timeout=15
|
||||||
|
Defaults !tty_tickets
|
||||||
|
Defaults umask = 022
|
||||||
|
Defaults passprompt="[sudo] Password: "
|
||||||
|
Defaults env_keep += "EDITOR"
|
||||||
|
Defaults env_keep += "SSH_CONNECTION"
|
||||||
|
Defaults env_keep += "TMUX"
|
||||||
|
|
||||||
|
%wheel ALL=(ALL) ALL
|
1
srcpkgs/distr0/files/udev/99-ioschedulers.rules
Normal file
1
srcpkgs/distr0/files/udev/99-ioschedulers.rules
Normal file
@ -0,0 +1 @@
|
|||||||
|
ACTION=="add|change", KERNEL=="sd[a-z]|mmcblk[0-9]*", ATTR{queue/rotational}=="0", ATTR{queue/scheduler}="mq-deadline"
|
1
srcpkgs/distr0/files/udev/99-mount-media.rules
Normal file
1
srcpkgs/distr0/files/udev/99-mount-media.rules
Normal file
@ -0,0 +1 @@
|
|||||||
|
ENV{ID_FS_USAGE}=="filesystem|other|crypto", ENV{UDISKS_FILESYSTEM_SHARED}="1"
|
2
srcpkgs/distr0/files/xbps/20-repo-rotce.de-pakete.conf
Normal file
2
srcpkgs/distr0/files/xbps/20-repo-rotce.de-pakete.conf
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
repository=https://rotce.de/pakete
|
||||||
|
|
1
srcpkgs/distr0/files/xbps/50-no-extract.conf
Normal file
1
srcpkgs/distr0/files/xbps/50-no-extract.conf
Normal file
@ -0,0 +1 @@
|
|||||||
|
noextract=/usr/bin/xq
|
9
srcpkgs/distr0/files/xdg/autostart/pipewire.desktop
Normal file
9
srcpkgs/distr0/files/xdg/autostart/pipewire.desktop
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Version=1.0
|
||||||
|
Name=PipeWire Media System
|
||||||
|
Comment=Start the PipeWire Media System
|
||||||
|
Exec=/sbin/dbus-launch --exit-with-session /usr/bin/pipewire
|
||||||
|
Terminal=false
|
||||||
|
Type=Application
|
||||||
|
X-GNOME-Autostart-Phase=Initialization
|
||||||
|
X-KDE-autostart-phase=1
|
8
srcpkgs/distr0/files/xorg/10-keyboard.conf
Normal file
8
srcpkgs/distr0/files/xorg/10-keyboard.conf
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
Section "InputClass"
|
||||||
|
Identifier "keyboard"
|
||||||
|
MatchIsKeyboard "yes"
|
||||||
|
Option "XkbLayout" "de"
|
||||||
|
Option "XkbVariant" "nodeadkeys"
|
||||||
|
#Option "XkbOptions" "grp:alt_shift_toggle"
|
||||||
|
EndSection
|
||||||
|
|
6
srcpkgs/distr0/files/xorg/dbus-launch.sh
Normal file
6
srcpkgs/distr0/files/xorg/dbus-launch.sh
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
if [ "$DESKTOP_SESSION" = "i3" ]; then
|
||||||
|
if which dbus-launch >/dev/null && test -z "$DBUS_SESSION_BUS_ADDRESS"; then
|
||||||
|
eval "$(dbus-launch --sh-syntax --exit-with-x11)"
|
||||||
|
fi
|
||||||
|
fi
|
||||||
|
|
85
srcpkgs/distr0/template
Normal file
85
srcpkgs/distr0/template
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
# Template file for 'distr0'
|
||||||
|
pkgname=distr0
|
||||||
|
version=0.4.4
|
||||||
|
revision=1
|
||||||
|
build_style=meta
|
||||||
|
depends="void-repo-multilib void-repo-multilib-nonfree
|
||||||
|
void-repo-nonfree lvm2 cronie socklog-void ntp xtools
|
||||||
|
wireguard-tools gnupg2 progress pwgen net-tools ncdu
|
||||||
|
nmap mtr iotop hdparm smartmontools htop git neovim
|
||||||
|
btrbk croc grub-btrfs nano mbuffer noto-fonts-emoji"
|
||||||
|
short_desc="Void Zero"
|
||||||
|
maintainer="teldra <teldra@rotce.de>"
|
||||||
|
license="GPL-3.0-or-later"
|
||||||
|
homepage="https://rotce.de"
|
||||||
|
make_dirs="/var/lib/backup/ziel 0750 root root
|
||||||
|
/var/lib/backup/quelle/bootfs 0750 root root
|
||||||
|
/var/lib/backup/quelle/rootfs 0750 root root"
|
||||||
|
conf_files="/etc/sudoers.d/10-common
|
||||||
|
/etc/bash/bashrc.d/xbps-aliase.sh
|
||||||
|
/etc/bash/bashrc.d/editor.sh
|
||||||
|
/usr/lib/udev/rules.d/99-mount-media.rules
|
||||||
|
/usr/lib/udev/rules.d/99-ioschedulers.rules
|
||||||
|
/etc/btrbk/btrbk.conf.void
|
||||||
|
/etc/xbps.d/50-no-extract.conf
|
||||||
|
/etc/xbps.d/20-repo-rotce.de-pakete.conf
|
||||||
|
/etc/default/grub-btrfs/void.conf
|
||||||
|
/etc/NetworkManager/conf.d/unmanaged-wg.conf
|
||||||
|
/etc/NetworkManager/conf.d/unmanaged-tun.conf
|
||||||
|
/etc/NetworkManager/dispatcher.d/30-wg0
|
||||||
|
/etc/profile.d/zz-append-path.sh
|
||||||
|
/etc/skel/gpg-agent.conf"
|
||||||
|
|
||||||
|
|
||||||
|
do_install() {
|
||||||
|
vbin "${FILESDIR}/bin/joinvpn"
|
||||||
|
vbin "${FILESDIR}/bin/void-update"
|
||||||
|
vbin "${FILESDIR}/bin/void-backup"
|
||||||
|
vbin "${FILESDIR}/bin/void-snapshot"
|
||||||
|
vbin "${FILESDIR}/bin/void-createbackupcontainer"
|
||||||
|
vbin "${FILESDIR}/bin/pinentry-chooser"
|
||||||
|
vbin "${FILESDIR}/bin/change_luks_pw"
|
||||||
|
vbin "${FILESDIR}/bin/helpme"
|
||||||
|
|
||||||
|
vmkdir etc/sudoers.d
|
||||||
|
vinstall "${FILESDIR}/sudoers/10-common" 700 etc/sudoers.d
|
||||||
|
|
||||||
|
vmkdir etc/bash/bashrc.d
|
||||||
|
vinstall "${FILESDIR}/bash/xbps-aliase.sh" 755 etc/bash/bashrc.d
|
||||||
|
vinstall "${FILESDIR}/bash/editor.sh" 755 etc/bash/bashrc.d
|
||||||
|
|
||||||
|
vmkdir usr/lib/udev/rules.d
|
||||||
|
vinstall "${FILESDIR}/udev/99-mount-media.rules" 644 usr/lib/udev/rules.d
|
||||||
|
vinstall "${FILESDIR}/udev/99-ioschedulers.rules" 644 usr/lib/udev/rules.d
|
||||||
|
|
||||||
|
vmkdir etc/btrbk
|
||||||
|
vinstall "${FILESDIR}/btrbk/btrbk.conf.void" 644 etc/btrbk
|
||||||
|
|
||||||
|
vmkdir etc/xbps.d
|
||||||
|
vinstall "${FILESDIR}/xbps/50-no-extract.conf" 755 etc/xbps.d
|
||||||
|
vinstall "${FILESDIR}/xbps/20-repo-rotce.de-pakete.conf" 755 etc/xbps.d
|
||||||
|
|
||||||
|
vmkdir etc/default/grub-btrfs
|
||||||
|
vinstall "${FILESDIR}/grub-btrfs/void.conf" 755 etc/default/grub-btrfs
|
||||||
|
|
||||||
|
vmkdir etc/NetworkManager/conf.d
|
||||||
|
vmkdir etc/NetworkManager/dispatcher.d
|
||||||
|
vinstall "${FILESDIR}/nm/unmanaged-wg.conf" 644 etc/NetworkManager/conf.d
|
||||||
|
vinstall "${FILESDIR}/nm/unmanaged-tun.conf" 644 etc/NetworkManager/conf.d
|
||||||
|
vinstall "${FILESDIR}/nm/30-wg0" 744 etc/NetworkManager/dispatcher.d
|
||||||
|
|
||||||
|
vmkdir etc/profile.d
|
||||||
|
vinstall "${FILESDIR}/profile/append-path.sh" 644 etc/profile.d zz-append-path.sh
|
||||||
|
|
||||||
|
vmkdir usr/share/X11/xorg.conf.d
|
||||||
|
vinstall "${FILESDIR}/xorg/10-keyboard.conf" 644 usr/share/X11/xorg.conf.d
|
||||||
|
|
||||||
|
vmkdir etc/X11/xinit/xinitrc.d
|
||||||
|
vinstall "${FILESDIR}/xorg/dbus-launch.sh" 755 etc/X11/xinit/xinitrc.d
|
||||||
|
|
||||||
|
vmkdir etc/skel
|
||||||
|
vinstall "${FILESDIR}/gnupg/gpg-agent.conf" 700 etc/skel
|
||||||
|
|
||||||
|
vmkdir etc/fonts/conf.d
|
||||||
|
ln -s /usr/share/fontconfig/conf.avail/70-no-bitmaps.conf "${DESTDIR}/etc/fonts/conf.d/70-no-bitmaps.conf"
|
||||||
|
}
|
BIN
srcpkgs/riseup-vpn/files/riseup-vpn.png
Normal file
BIN
srcpkgs/riseup-vpn/files/riseup-vpn.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 16 KiB |
14
srcpkgs/riseup-vpn/files/riseup-vpn_launcher.desktop
Normal file
14
srcpkgs/riseup-vpn/files/riseup-vpn_launcher.desktop
Normal file
@ -0,0 +1,14 @@
|
|||||||
|
[Desktop Entry]
|
||||||
|
Version=1.0
|
||||||
|
Type=Application
|
||||||
|
Name=RiseupVPN
|
||||||
|
Comment=Anonymous VPN
|
||||||
|
Comment[es]=VPN Anonima
|
||||||
|
Comment[de]=Anonymous VPN
|
||||||
|
Exec=riseup-vpn %U
|
||||||
|
Terminal=false
|
||||||
|
Icon=riseup-vpn
|
||||||
|
Categories=Network;Application;
|
||||||
|
StartupNotify=true
|
||||||
|
Keywords=VPN;Riseup;leap
|
||||||
|
|
54
srcpkgs/riseup-vpn/template
Normal file
54
srcpkgs/riseup-vpn/template
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
# Template file for 'riseup-vpn'
|
||||||
|
pkgname=riseup-vpn
|
||||||
|
version=0.21.11
|
||||||
|
revision=1
|
||||||
|
#archs="i686 x86_64"
|
||||||
|
wrksrc=bitmask-vpn-${version}
|
||||||
|
#create_wrksrc=yes
|
||||||
|
build_style=go
|
||||||
|
go_import_path=0xacab.org/leap/bitmask-vpn
|
||||||
|
#configure_args=""
|
||||||
|
#make_build_args=""
|
||||||
|
#make_install_args=""
|
||||||
|
#conf_files=""
|
||||||
|
#make_dirs="/var/log/dir 0755 root root"
|
||||||
|
hostmakedepends="python3 which git"
|
||||||
|
makedepends="qt5-devel qt5-tools-devel qt5-declarative-devel qt5-quickcontrols
|
||||||
|
qt5-quickcontrols2-devel pkgconf cmake qt5-host-tools"
|
||||||
|
depends="openvpn qt5-quickcontrols qt5-quickcontrols2 qt5-declarative hicolor-icon-theme"
|
||||||
|
short_desc="Anonymous encrypted VPN client powered by Bitmask"
|
||||||
|
maintainer="teldra <teldra@rotce.de>"
|
||||||
|
license="GPL-3.0-or-later"
|
||||||
|
homepage="https://riseup.net/en/vpn"
|
||||||
|
distfiles="https://0xacab.org/leap/bitmask-vpn/-/archive/${version}/bitmask-vpn-${version}.tar.gz"
|
||||||
|
checksum=e5b62d9812551dcd9c2a4adcdc4c8044ba1f081c4a9b1f7f45ca459cc2da36c2
|
||||||
|
|
||||||
|
post_extract() {
|
||||||
|
git init
|
||||||
|
git config user.email "larry@gentoo.org"
|
||||||
|
git config user.name "Larry the Cow"
|
||||||
|
git add .
|
||||||
|
git commit -m "init"
|
||||||
|
git tag -a "${version}" -m "${version}"
|
||||||
|
}
|
||||||
|
|
||||||
|
do_build() {
|
||||||
|
make generate
|
||||||
|
|
||||||
|
go build -buildmode=c-archive -o lib/libgoshim.a gui/backend.go
|
||||||
|
|
||||||
|
PROVIDER=riseup make build
|
||||||
|
}
|
||||||
|
|
||||||
|
do_install() {
|
||||||
|
vmkdir usr/share/polkit-1/actions
|
||||||
|
vmkdir usr/share/applications
|
||||||
|
vmkdir usr/share/icons/hicolor/128x128/apps
|
||||||
|
|
||||||
|
vinstall helpers/se.leap.bitmask.policy 644 usr/share/polkit-1/actions
|
||||||
|
vinstall "${FILESDIR}"/riseup-vpn_launcher.desktop 644 usr/share/applications
|
||||||
|
vinstall "${FILESDIR}"/riseup-vpn.png 644 usr/share/icons/hicolor/128x128/apps
|
||||||
|
|
||||||
|
vbin helpers/bitmask-root
|
||||||
|
vbin build/qt/release/riseup-vpn
|
||||||
|
}
|
Loading…
x
Reference in New Issue
Block a user