#!/bin/sh # This script will be executed at every VM startup, you can place your own # custom commands here. This includes overriding some configuration in /etc, # starting services etc. # Example for overriding the whole CUPS configuration: # rm -rf /etc/cups # ln -s /rw/config/cups /etc/cups # systemctl --no-block restart cups ## Download policies.json from gitlab wget https://gitlab.com/onequbesuser/qubes-stuffs/-/raw/master/policies.json -O /tmp/policies.json ## Copy policies.json to /usr/lib/firefox-esr/distribution/ folder cp /tmp/policies.json /usr/lib/firefox-esr/distribution/policies.json ## Download hostfiles/blocklists from Github mkdir /tmp/blocklists wget -P /tmp/blocklists -L https://raw.githubusercontent.com/lightswitch05/hosts/master/docs/lists/tracking-aggressive-extended.txt wget -P /tmp/blocklists -L https://raw.githubusercontent.com/StevenBlack/hosts/master/hosts ## Delete the localhosts rows from stevenblack/hosts sudo sed -i '14,29d' /tmp/blocklists/hosts ## Copy the outputs to 1 file touch /tmp/blocklists/hosts_4_dispvm cat /etc/hosts >> /tmp/blocklists/hosts_4_dispvm cat /tmp/blocklists/hosts >> /tmp/blocklists/hosts_4_dispvm cat /tmp/blocklists/tracking-aggressive-extended.txt >> /tmp/blocklists/hosts_4_dispvm ## Move /tmp/blocklists/hosts to /etc/hosts sudo rm /etc/hosts sudo cp /tmp/blocklists/hosts_4_dispvm /etc/hosts