psf-salt icon indicating copy to clipboard operation
psf-salt copied to clipboard

hg: Add static files to salt backup state

Open JacobCoffee opened this issue 1 year ago • 0 comments

What

  1. Add /usr/share/mercurial/templates/static/ to pillar/prod/backup/hg.sls.
  2. We need to think about host migration instructions, because we rsync, but the parent directories will not exist unless the mercurial package is installed

Why

These files arent covered in the backup of /srv, and I would think the mercurial package that sets all that /usr/share/... stuff would contain these, but it either is buggy or doesnt anymore or never did.

We can just add that one static dir though, and apply the files with a requires: - pkg: mercurial so that the /usr/share/mercurial/templates/ exists.

This fixed it, but we probably need to back up this in salt?

coffee@hg:~$ sudo -E rsync -av -e "ssh -i /home/psf-users/coffee/.ssh/id_ed25519" --rsync-path="sudo rsync" [email protected]:/usr/share/mercurial/templates/static/ /usr/share/mercurial/templates/static

created directory /usr/share/mercurial/templates/static
./
background.png
coal-file.png
coal-folder.png
feed-icon-14x14.png
followlines.js
hgicon.png
hglogo.png
mercurial.js
style-extra-coal.css
style-gitweb.css
style-monoblue.css
style-paper.css
style.css

sent 274 bytes  received 65,209 bytes  26,193.20 bytes/sec
total size is 64,344  speedup is 0.9

Image

Originally posted by @JacobCoffee in #414

JacobCoffee avatar Aug 02 '24 15:08 JacobCoffee