mirror of
https://github.com/unman/shaker.git
synced 2025-03-24 16:16:30 -04:00
Salt - caching proxy - general tidy up
This commit is contained in:
parent
d45858fb64
commit
655d37e127
@ -6,13 +6,13 @@ Config files are included, which will work out of the box for Debian,Ubuntu and
|
||||
The cache and log directories are bind-mounted in /rw in the cacher qube.
|
||||
|
||||
Copy directory to /srv/salt, then run:
|
||||
qubesctl state.apply cacher.create.
|
||||
qubesctl state.apply cacher.create
|
||||
qubesctl --skip-dom0 --targets=template-cacher state.apply cacher.install
|
||||
qubesctl --skip-dom0 --targets=cacher state.apply cacher.configure
|
||||
|
||||
To automatically use the proxy run:
|
||||
qubesctl state.apply cacher.use
|
||||
This will configure /etc/qubes-rpc/policy/qubes.UpdatesProxy to use the cachingproxy be default.
|
||||
This will configure /etc/qubes/policy.d/30-user.policy to use the caching proxy be default.
|
||||
|
||||
apt-cacher-ng will cache HTTPS requests if you change https:// to http://HTTPS/// in repo source lists.
|
||||
To configure the templates to use the proxy in this way, run:
|
||||
|
@ -60,12 +60,12 @@ Port:8082
|
||||
# installation using information collected on the system.
|
||||
# Examples:
|
||||
#Remap-debrep: https://deb.debian.org http://deb.debian.org file:deb_mirrors.gz /debian ; file:backends_debian # Debian Archives
|
||||
Remap-alxrep: file:archlx_mirrors /archlinux # ; file:backend_archlx # Arch Linux
|
||||
Remap-debrep: https://deb.debian.org http://deb.debian.org file:deb_mirrors.gz /debian
|
||||
Remap-fedora: file:fedora_mirrors # Fedora Linux
|
||||
Remap-uburep: file:ubuntu_mirrors /ubuntu ; file:backends_ubuntu # Ubuntu Archives
|
||||
Remap-cygwin: file:cygwin_mirrors /cygwin # ; file:backends_cygwin # incomplete, please create this file or specify preferred mirrors here
|
||||
#Remap-sfnet: file:sfnet_mirrors # ; file:backends_sfnet # incomplete, please create this file or specify preferred mirrors here
|
||||
Remap-alxrep: file:archlx_mirrors /archlinux # ; file:backend_archlx # Arch Linux
|
||||
Remap-fedora: file:fedora_mirrors # Fedora Linux
|
||||
Remap-epel: file:epel_mirrors # Fedora EPEL
|
||||
Remap-slrep: file:sl_mirrors # Scientific Linux
|
||||
Remap-gentoo: file:gentoo_mirrors.gz /gentoo ; file:backends_gentoo # Gentoo Archives
|
||||
@ -93,6 +93,7 @@ ReportPage: acng-report.html
|
||||
# it's a convenience alias for the Debug option, see below for details.
|
||||
#
|
||||
# UnbufferLogs: 0
|
||||
UnbufferLogs: 1
|
||||
|
||||
# Enables extended client information in log entries. When set to 0, only
|
||||
# activity type, time and transfer sizes are logged.
|
||||
@ -217,9 +218,9 @@ ExThreshold: 4
|
||||
#
|
||||
# To see examples of the expected syntax, run: apt-cacher-ng -p debug=1
|
||||
#
|
||||
PfilePatternEx: .*xml.zck$|.*yaml.gz$|.*fedora.*arch=x86_64$|.*f30&arch=x86_64|.*29&arch=x86_64
|
||||
PfilePatternEx: .*xml.zck$|.*yaml.gz$|.*fedora.*arch=x86_64$|.*f35&arch=x86_64|.*f36&arch=x86_64
|
||||
# VfilePatternEx:
|
||||
VfilePatternEx: ^/\?release=[0-9]+&arch=.*|.*/RPM-GPG-KEY.*|.*\?repo=fedora
|
||||
VfilePatternEx: ^/\?release=[0-9]+&arch=.*|.*/RPM-GPG-KEY.*|.*\?repo=fedora|.*pkg.tar.zst.sig
|
||||
# SPfilePatternEx:
|
||||
# SVfilePatternEx:
|
||||
# WfilePatternEx:
|
||||
|
@ -1,5 +1,7 @@
|
||||
# vim: set syntax=yaml ts=2 sw=2 sts=2 et :
|
||||
|
||||
{% if grains['nodename'] != 'dom0' %}
|
||||
|
||||
/rw/config/rc.local:
|
||||
file.append:
|
||||
- text: |
|
||||
@ -18,3 +20,5 @@
|
||||
- user: root
|
||||
- group: root
|
||||
- makedirs: True
|
||||
|
||||
{% endif %}
|
||||
|
@ -2,4 +2,4 @@
|
||||
|
||||
base:
|
||||
cacher:
|
||||
- cacher.install
|
||||
- cacher.configure
|
||||
|
@ -2,6 +2,9 @@
|
||||
#
|
||||
#
|
||||
#
|
||||
|
||||
{% if grains['nodename'] != 'dom0' %}
|
||||
|
||||
allow-testing:
|
||||
file.uncomment:
|
||||
- name: /etc/apt/sources.list.d/qubes-r4.list
|
||||
@ -44,3 +47,12 @@ cp /lib/apt-cacher-ng/deb_mirrors.gz /etc/apt-cacher-ng/deb_mirrors.gz:
|
||||
- salt://cacher/fedora_mirrors
|
||||
- user: root
|
||||
- group: root
|
||||
|
||||
/etc/apt-cacher-ng/archlx_mirrors:
|
||||
file.managed:
|
||||
- source:
|
||||
- salt://cacher/archlx_mirrors
|
||||
- user: root
|
||||
- group: root
|
||||
|
||||
{% endif %}
|
||||
|
@ -6,4 +6,4 @@ qvm-present-id:
|
||||
|
||||
/etc/qubes/policy.d/30-user.policy:
|
||||
file.prepend:
|
||||
- text: "qubes.UpdatesProxy * @type:TemplateVM @default allow,target=cacher"
|
||||
- text: "qubes.UpdatesProxy * @type:TemplateVM @default allow target=cacher"
|
||||
|
Loading…
x
Reference in New Issue
Block a user