Compare commits
374
Commits
1f47d2b50d
..
prod
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
8d01548627 | ||
|
|
f587ca1e5e | ||
|
|
bbffe8c69a | ||
|
|
768cabfe45 | ||
|
|
b1bdc953c2 | ||
|
|
1764ca510f | ||
|
|
7f986e51d3 | ||
|
|
d0970f5971 | ||
|
|
d94397349b | ||
|
|
bb1514c33d | ||
|
|
0581ea62df | ||
|
|
0332289742 | ||
|
|
a3a647318d | ||
|
|
4da671c40e | ||
|
|
4db955b32d | ||
|
|
c0a9d79776 | ||
|
|
4145a12637 | ||
|
|
c23bb1c06b | ||
|
|
a9b78dbba2 | ||
|
|
a714a26058 | ||
|
|
d15b22ec26 | ||
|
|
482d3072f5 | ||
|
|
609edd6c3b | ||
|
|
1ded62a3d4 | ||
|
|
0303a1c091 | ||
|
|
10b21ac49b | ||
|
|
7efa7f1b91 | ||
|
|
d3a5946232 | ||
|
|
46890d0d16 | ||
|
|
9073dfc597 | ||
|
|
f3d9f088c7 | ||
|
|
3c10415347 | ||
|
|
26dc61ebbf | ||
|
|
33755480bb | ||
|
|
35783422a3 | ||
|
|
d681c3f447 | ||
|
|
a31cad1f42 | ||
|
|
788a723690 | ||
|
|
6ed4f284c0 | ||
|
|
59b4343ec2 | ||
|
|
af64e47519 | ||
|
|
e2c18a5cfc | ||
|
|
556f483aaa | ||
|
|
b09e74c4b7 | ||
|
|
107afbece4 | ||
|
|
076f954abd | ||
|
|
648962e710 | ||
|
|
15370d639f | ||
|
|
eb3b16264e | ||
|
|
25346a95de | ||
|
|
d25f47bd72 | ||
|
|
9aa25f85cd | ||
|
|
b732402719 | ||
|
|
b3b2cb075f | ||
|
|
95542ec233 | ||
|
|
8abe634c42 | ||
|
|
5e0b5fb4d2 | ||
|
|
855cffc64d | ||
|
|
032239e430 | ||
|
|
57b56d82c4 | ||
|
|
bede2b84f3 | ||
|
|
4fbf7b41e4 | ||
|
|
ce1afc6624 | ||
|
|
b4fc988f97 | ||
|
|
9ab9f0095b | ||
|
|
9949014558 | ||
|
|
373b03d46c | ||
|
|
6117a65009 | ||
|
|
af82cd3319 | ||
|
|
bb1529e5b1 | ||
|
|
252d24b2a7 | ||
|
|
a997fd8efc | ||
|
|
88ec75a544 | ||
|
|
3d64b90d58 | ||
|
|
892af9a669 | ||
|
|
7661b85238 | ||
|
|
f487461d94 | ||
|
|
65ab204409 | ||
|
|
62302b3a0c | ||
|
|
4597151bbf | ||
|
|
9e75d9b981 | ||
|
|
65aeea9a93 | ||
|
|
0e1648cc31 | ||
|
|
3e53bd3c9b | ||
|
|
43dc65a84b | ||
|
|
2a7fa98825 | ||
|
|
71bcb7c351 | ||
|
|
cea7e03c11 | ||
|
|
38a04fbda1 | ||
|
|
4342b8842f | ||
|
|
ef9566c76c | ||
|
|
41f306f7d7 | ||
|
|
4c5d753b73 | ||
|
|
fcf77e22c5 | ||
|
|
75503d762b | ||
|
|
e0b1fa30f1 | ||
|
|
d7eed3c883 | ||
|
|
c341d216ad | ||
|
|
f6fd08f966 | ||
|
|
295b6b3d19 | ||
|
|
fe3cb9b5ba | ||
|
|
431510a729 | ||
|
|
e7a461550d | ||
|
|
d13b97d5aa | ||
|
|
96dd0118fa | ||
|
|
17684becbb | ||
|
|
4474ad664e | ||
|
|
24e4ea9c8c | ||
|
|
847dfe88d4 | ||
|
|
9f74361af1 | ||
|
|
6c79addc3c | ||
|
|
049df1ab61 | ||
|
|
007f338d2e | ||
|
|
494a9b70f6 | ||
|
|
ed8a33e00c | ||
|
|
6640058d8d | ||
|
|
c852329455 | ||
|
|
0363aefc1d | ||
|
|
e81de0c63b | ||
|
|
d5e3a57f56 | ||
|
|
99a0b7ca0b | ||
|
|
a47d5fd129 | ||
|
|
472f7921e7 | ||
|
|
8567cae2b1 | ||
|
|
a1190290db | ||
|
|
9a2e4ca4d2 | ||
|
|
eb761e41dc | ||
|
|
05e2244efb | ||
|
|
bd7112e8d5 | ||
|
|
40d9a7252e | ||
|
|
6482dd123d | ||
|
|
74789ba70c | ||
|
|
6411d4792a | ||
|
|
e367e9e14b | ||
|
|
c604859947 | ||
|
|
7f7f2a2edb | ||
|
|
92be32345a | ||
|
|
5719ec6b60 | ||
|
|
85e60ef60c | ||
|
|
5620e5a223 | ||
|
|
4fd12ce45e | ||
|
|
5c67da3eb8 | ||
|
|
14fdc1f740 | ||
|
|
1adf4db6ee | ||
|
|
3b3c7bd501 | ||
|
|
b5e5a18e4c | ||
|
|
870a99804a | ||
|
|
358bf9e11d | ||
|
|
20549e0055 | ||
|
|
003e8d8430 | ||
|
|
0e990e2ed5 | ||
|
|
2ff0ccd392 | ||
|
|
9a9eb8b8e6 | ||
|
|
bec4c919d4 | ||
|
|
1ad4f642db | ||
|
|
52d7ae3d86 | ||
|
|
a892aae620 | ||
|
|
36b8305f0f | ||
|
|
a823d4ae63 | ||
|
|
8311427506 | ||
|
|
797744d9fe | ||
|
|
4ae411584e | ||
|
|
2dccea21ae | ||
|
|
32916ad470 | ||
|
|
8b4329d129 | ||
|
|
ec60e9f5f7 | ||
|
|
edffe124fd | ||
|
|
1de11bc2d9 | ||
|
|
44a0463ab8 | ||
|
|
9a1004dfb9 | ||
|
|
607129e1c2 | ||
|
|
48c6f54903 | ||
|
|
1278c5020f | ||
|
|
11cac42df8 | ||
|
|
feb1985755 | ||
|
|
99965a1df2 | ||
|
|
4de2772ad0 | ||
|
|
3e1291d1f9 | ||
|
|
bcdb47ac74 | ||
|
|
1764705562 | ||
|
|
c8bd5ee1e4 | ||
|
|
36a80041f3 | ||
|
|
41d01c70f5 | ||
|
|
9f82c136e9 | ||
|
|
89fdb52fcc | ||
|
|
98c6d47d7f | ||
|
|
8a2a723d4b | ||
|
|
1e8aa6956f | ||
|
|
caf60d1ccd | ||
|
|
f17b6a96b2 | ||
|
|
c8f32b917f | ||
|
|
e5891a72c6 | ||
|
|
b1ebe20874 | ||
|
|
1746d7f11a | ||
|
|
90ecb842d3 | ||
|
|
be53012c48 | ||
|
|
c709930bf0 | ||
|
|
7e0df2ee13 | ||
|
|
6a446a8383 | ||
|
|
bedfbe566d | ||
|
|
629f7c424d | ||
|
|
0a0b85e66d | ||
|
|
2706011fa0 | ||
|
|
669095e7cb | ||
|
|
13f20a4e98 | ||
|
|
cab2013a97 | ||
|
|
8ed0aca797 | ||
|
|
79d6f53424 | ||
|
|
79a8c32584 | ||
|
|
0f4fe291b2 | ||
|
|
490df1e24c | ||
|
|
b26ead5577 | ||
|
|
bcf2a5aee6 | ||
|
|
98b9691e1e | ||
|
|
62306f886e | ||
|
|
03d0978a64 | ||
|
|
f3632fa13a | ||
|
|
f828e0a9f2 | ||
|
|
852b904dd4 | ||
|
|
b7738a1b78 | ||
|
|
13801d9d86 | ||
|
|
0dc7f258a3 | ||
|
|
d20b1b8114 | ||
|
|
f070896ad3 | ||
|
|
822140efe6 | ||
|
|
231aa8a9a2 | ||
|
|
5e3d162481 | ||
|
|
eab790c2cc | ||
|
|
3c04476217 | ||
|
|
e762e1231a | ||
|
|
44ae9967f1 | ||
|
|
fe4f23fdb0 | ||
|
|
c213397550 | ||
|
|
951959a00b | ||
|
|
9d7a6414b3 | ||
|
|
18b73f7665 | ||
|
|
cccd7238cd | ||
|
|
43eff5399c | ||
|
|
65090d32e8 | ||
|
|
fb692f3766 | ||
|
|
6ae099fcb1 | ||
|
|
80f5f100f1 | ||
|
|
7e2dd72fc1 | ||
|
|
b3a11dec30 | ||
|
|
e8cece4445 | ||
|
|
0e10bc235f | ||
|
|
883ad223c2 | ||
|
|
9dee72820b | ||
|
|
a3ba5e7a60 | ||
|
|
d27d759c97 | ||
|
|
fe46062be0 | ||
|
|
a0eae9a7cc | ||
|
|
df0df85d9e | ||
|
|
5541c8251c | ||
|
|
6fc8181272 | ||
|
|
487f1f46f3 | ||
|
|
0776e89d26 | ||
|
|
ccd8355946 | ||
|
|
942780e6d1 | ||
|
|
019066c4dc | ||
|
|
1f16053042 | ||
|
|
bafa669bb5 | ||
|
|
5595ea0888 | ||
|
|
3aee0feb39 | ||
|
|
5d352bbb53 | ||
|
|
6c46439eb6 | ||
|
|
648501b7c0 | ||
|
|
e0288ce4d5 | ||
|
|
c6cc631d8c | ||
|
|
3381eb6d70 | ||
|
|
53351fde28 | ||
|
|
7922225b26 | ||
|
|
d27976150c | ||
|
|
8b73c7ef02 | ||
|
|
69b1e62c82 | ||
|
|
8970b14e31 | ||
|
|
861546236f | ||
|
|
f7389bc944 | ||
|
|
c85d96f940 | ||
|
|
4ab93d02f4 | ||
|
|
0feb9b1995 | ||
|
|
e95054d329 | ||
|
|
993eeda08b | ||
|
|
5655fe52b0 | ||
|
|
daec9237f0 | ||
|
|
a866a6d2e5 | ||
|
|
43d92d14ed | ||
|
|
0450aa45c3 | ||
|
|
196c879c27 | ||
|
|
9aae4dc2ca | ||
|
|
6735e257b3 | ||
|
|
4ce0720a43 | ||
|
|
c59d78270b | ||
|
|
0c422687a5 | ||
|
|
d0f7127807 | ||
|
|
c7432d554f | ||
|
|
bd181de2c9 | ||
|
|
e95c87dddf | ||
|
|
0b88905e91 | ||
|
|
e3d6a759a8 | ||
|
|
b5c7bed4e9 | ||
|
|
29e989fae9 | ||
|
|
f6dfa4f81f | ||
|
|
9e6e162b03 | ||
|
|
816ef4ddc6 | ||
|
|
731a367e6f | ||
|
|
76702e6433 | ||
|
|
ee97598070 | ||
|
|
74b42f3d63 | ||
|
|
0c86a76968 | ||
|
|
f29fad4078 | ||
|
|
a9080a6d12 | ||
|
|
22252b8880 | ||
|
|
3c8617aab2 | ||
|
|
f29b28e838 | ||
|
|
9860f56bf7 | ||
|
|
10821d2317 | ||
|
|
d7c321adea | ||
|
|
77d2ae62a3 | ||
|
|
a511fdac35 | ||
|
|
934bec45b5 | ||
|
|
0660dd55d4 | ||
|
|
57707ff56e | ||
|
|
fe6f41d1e8 | ||
|
|
b60c4c4170 | ||
|
|
8099c34791 | ||
|
|
a319e29f93 | ||
|
|
80a809545c | ||
|
|
4cd86fc47f | ||
|
|
bef91a4ba1 | ||
|
|
ce34f879d6 | ||
|
|
2c6921688f | ||
|
|
e7d307a306 | ||
|
|
227a91e2f3 | ||
|
|
2fc13b59e6 | ||
|
|
7dd0f80590 | ||
|
|
af8182626a | ||
|
|
50d51b7264 | ||
|
|
6fa3a42362 | ||
|
|
393ff77eaf | ||
|
|
562c2e4416 | ||
|
|
fecefb6a6e | ||
|
|
704955248b | ||
|
|
5899f93a0a | ||
|
|
0e4c6d5faa | ||
|
|
15b8fc95ff | ||
|
|
4307856790 | ||
|
|
acfe37f0c0 | ||
|
|
8db3616687 | ||
|
|
5be5c34fd6 | ||
|
|
bddb4d14b4 | ||
|
|
c0fb178193 | ||
|
|
8a5c2f4b8a | ||
|
|
79887c227b | ||
|
|
44b1bfd43a | ||
|
|
1d7374e3ad | ||
|
|
ddfa5d5d81 | ||
|
|
7f9d59213f | ||
|
|
9cf77d2ab8 | ||
|
|
d36585f21d | ||
|
|
742de9b6b4 | ||
|
|
edaeec1ff2 | ||
|
|
2cf83a2fcf | ||
|
|
d6dbe38e17 | ||
|
|
813a96c469 | ||
|
|
fbe5f54b7f | ||
|
|
b1d70789e7 | ||
|
|
39b949517a | ||
|
|
58f8636969 | ||
|
|
827db06b38 | ||
|
|
08b60b62b6 | ||
|
|
48bf1d542f | ||
|
|
50e99bde43 | ||
|
|
31d9600253 |
No files matched your search
@@ -10,6 +10,7 @@ skip_list:
|
|||||||
- yaml[comments]
|
- yaml[comments]
|
||||||
- yaml[commas]
|
- yaml[commas]
|
||||||
- var-naming[pattern]
|
- var-naming[pattern]
|
||||||
|
- yaml[braces]
|
||||||
|
|
||||||
warn_list:
|
warn_list:
|
||||||
- literal-compare
|
- literal-compare
|
||||||
|
|||||||
@@ -22,6 +22,8 @@
|
|||||||
alsa: alsa-utils
|
alsa: alsa-utils
|
||||||
stress: stress
|
stress: stress
|
||||||
jq: jq
|
jq: jq
|
||||||
|
btop: btop
|
||||||
|
xkb: x11-xkb-utils
|
||||||
|
|
||||||
- name: General | Facts | Package | Parrot OS Fixes
|
- name: General | Facts | Package | Parrot OS Fixes
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
@@ -50,6 +52,7 @@
|
|||||||
encfs: encfs
|
encfs: encfs
|
||||||
dig: bind
|
dig: bind
|
||||||
base_devel: base-devel
|
base_devel: base-devel
|
||||||
|
xkb: xorg-setxkbmap
|
||||||
when: ansible_pkg_mgr == "pacman"
|
when: ansible_pkg_mgr == "pacman"
|
||||||
|
|
||||||
- name: General | Facts | Package | FreeBSD
|
- name: General | Facts | Package | FreeBSD
|
||||||
@@ -102,10 +105,14 @@
|
|||||||
ansible_pkg_mgr_file: "{{ prov_dir }}/ansible_pkg_mgr.txt"
|
ansible_pkg_mgr_file: "{{ prov_dir }}/ansible_pkg_mgr.txt"
|
||||||
|
|
||||||
- name: General | Facts | Package | Update Command | Store Variables
|
- name: General | Facts | Package | Update Command | Store Variables
|
||||||
ansible.builtin.shell: "{{ item }}"
|
ansible.builtin.shell: |
|
||||||
|
set -o pipefail
|
||||||
|
{{ item }}
|
||||||
loop:
|
loop:
|
||||||
- "echo '{{ ansible_distribution }}' > {{ ansible_distribution_file }}"
|
- "echo '{{ ansible_distribution }}' > {{ ansible_distribution_file }}"
|
||||||
- "echo '{{ ansible_pkg_mgr }}' > {{ ansible_pkg_mgr_file }}"
|
- "echo '{{ ansible_pkg_mgr }}' > {{ ansible_pkg_mgr_file }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
- name: General | Facts | Package | Update Command
|
- name: General | Facts | Package | Update Command
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
@@ -159,13 +166,13 @@
|
|||||||
auto_accept="--noconfirm"
|
auto_accept="--noconfirm"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
sudo pacman -Syu $auto_accept ||
|
sudo pacman -Syu $auto_accept --overwrite '/usr/lib/node_modules/*' ||
|
||||||
return 1
|
return 1
|
||||||
echo -e "\n"
|
echo -e "\n"
|
||||||
|
|
||||||
if [[ "$LOGNAME" != "root" ]]; then
|
if [[ "$LOGNAME" != "root" ]]; then
|
||||||
echo "*** AUR (yay) ***"
|
echo "*** AUR (yay) ***"
|
||||||
yay -Syu $auto_accept || return 2
|
yay --sudoloop -Syu $auto_accept || return 2
|
||||||
else
|
else
|
||||||
echo "*** User is root, skipping AUR (yay) ***"
|
echo "*** User is root, skipping AUR (yay) ***"
|
||||||
fi
|
fi
|
||||||
@@ -261,16 +268,23 @@
|
|||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
update_npm: |
|
update_npm: |
|
||||||
if [[ `which npm` ]]; then
|
## Let's let the distro package managers handle this, otherwise may end up
|
||||||
|
## breaking dependencies or causing other system weirdness. No thanks! :)
|
||||||
|
if [[ `which npm` && 1 == 0 ]]; then
|
||||||
echo "*** NPM ***" &&
|
echo "*** NPM ***" &&
|
||||||
sudo npm update -g
|
sudo npm update -g
|
||||||
echo -e "\n"
|
echo -e "\n"
|
||||||
|
else
|
||||||
|
echo -e "*** Skipping NPM ***\n\n"
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# Flatpaks
|
# Flatpaks
|
||||||
- name: General | Facts | Package | Update Command | Flatpak | Check
|
- name: General | Facts | Package | Update Command | Flatpak | Check
|
||||||
ansible.builtin.shell: which flatpak
|
ansible.builtin.shell: |
|
||||||
|
set -o pipefail
|
||||||
|
which flatpak
|
||||||
register: flatpak_exec
|
register: flatpak_exec
|
||||||
|
changed_when: flatpak_exec.rc == 0
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
|
|
||||||
- name: General | Facts | Package | Update Command | Flatpak | Exists
|
- name: General | Facts | Package | Update Command | Flatpak | Exists
|
||||||
@@ -293,8 +307,11 @@
|
|||||||
|
|
||||||
# Firmware
|
# Firmware
|
||||||
- name: General | Facts | Package | Update Command | Firmware | Check
|
- name: General | Facts | Package | Update Command | Firmware | Check
|
||||||
ansible.builtin.shell: which fwupdmgr
|
ansible.builtin.shell: |
|
||||||
|
set -o pipefail
|
||||||
|
which fwupdmgr
|
||||||
register: fwupdmgr_exec
|
register: fwupdmgr_exec
|
||||||
|
changed_when: fwupdmgr_exec.rc == 0
|
||||||
ignore_errors: true
|
ignore_errors: true
|
||||||
|
|
||||||
- name: General | Facts | Package | Update Command | Firmware | Exists
|
- name: General | Facts | Package | Update Command | Firmware | Exists
|
||||||
|
|||||||
@@ -11,6 +11,34 @@
|
|||||||
notify_log: "ansible.notify.log"
|
notify_log: "ansible.notify.log"
|
||||||
runit_script_dir: /etc/runit/sv
|
runit_script_dir: /etc/runit/sv
|
||||||
runit_service_dir: /etc/runit/runsvdir/default
|
runit_service_dir: /etc/runit/runsvdir/default
|
||||||
|
runit_service_script: run
|
||||||
|
runit_log_dir: log
|
||||||
|
global_log: /var/log
|
||||||
|
global_log_config: config
|
||||||
|
runit_finish_sleep: |
|
||||||
|
#!/bin/sh
|
||||||
|
exec 2>&1
|
||||||
|
# $1 is the exit code, $2 is the exit status byte (signal number if killed)
|
||||||
|
echo "FINISH: Service returned with exit code: $1 and status: $2"
|
||||||
|
|
||||||
|
sleep_long=10
|
||||||
|
sleep_short=1
|
||||||
|
if [[ "$1" != 0 ]]; then
|
||||||
|
echo "FINISH: Sleeping for $sleep_long seconds due to error..."
|
||||||
|
sleep $sleep_long
|
||||||
|
else
|
||||||
|
echo "FINISH: Sleeping for $sleep_short seconds."
|
||||||
|
sleep $sleep_short
|
||||||
|
fi
|
||||||
|
runit_log_config_1mb: |
|
||||||
|
s1000000 # rotate at 1 MB
|
||||||
|
n2 # keep 2 old files
|
||||||
|
runit_log_config_10mb: |
|
||||||
|
s10000000 # rotate at 10 MB
|
||||||
|
n2 # keep 2 old files
|
||||||
|
runit_log_config_100mb: |
|
||||||
|
s100000000 # rotate at 100 MB
|
||||||
|
n2 # keep 2 old files
|
||||||
|
|
||||||
- name: General | Facts | System | Global 02
|
- name: General | Facts | System | Global 02
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
@@ -20,6 +48,7 @@
|
|||||||
lynis_install_dir: "{{ global_src }}/lynis"
|
lynis_install_dir: "{{ global_src }}/lynis"
|
||||||
dwm_install_dir: "{{ global_src }}/dwm"
|
dwm_install_dir: "{{ global_src }}/dwm"
|
||||||
st_install_dir: "{{ global_src }}/st"
|
st_install_dir: "{{ global_src }}/st"
|
||||||
|
runit_log_script: "{{ runit_service_script }}"
|
||||||
|
|
||||||
- name: General | Facts | System | Global 03
|
- name: General | Facts | System | Global 03
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
|
|||||||
@@ -58,7 +58,10 @@
|
|||||||
transmission_qt: transmission-qt
|
transmission_qt: transmission-qt
|
||||||
libreoffice: libreoffice
|
libreoffice: libreoffice
|
||||||
strawberry: strawberry
|
strawberry: strawberry
|
||||||
|
dict_en: hunspell-en_us
|
||||||
|
dict_es: hunspell-es_any
|
||||||
|
xset: xorg-xset
|
||||||
|
xlock: xss-lock
|
||||||
|
|
||||||
- name: Workstation | Facts | Package | apt (All Distros)
|
- name: Workstation | Facts | Package | apt (All Distros)
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
@@ -78,6 +81,7 @@
|
|||||||
ncurses: libncurses-dev
|
ncurses: libncurses-dev
|
||||||
android_udev: android-udev-rules
|
android_udev: android-udev-rules
|
||||||
vlc_plugins: libavcodec-extra
|
vlc_plugins: libavcodec-extra
|
||||||
|
xset: x11-server-utils
|
||||||
when: ansible_pkg_mgr == "apt"
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
- name: Workstation | Facts | Package | Pop_OS!
|
- name: Workstation | Facts | Package | Pop_OS!
|
||||||
|
|||||||
@@ -69,7 +69,7 @@ sleep 5
|
|||||||
|
|
||||||
echo "*** Creating backup at '$BACKUP2' ***"
|
echo "*** Creating backup at '$BACKUP2' ***"
|
||||||
sudo zip -rv "$BACKUP2" \
|
sudo zip -rv "$BACKUP2" \
|
||||||
/root /home /srv/sftp \
|
/root /home \
|
||||||
-x "*/.gradle/" -x "*/app/build/*"
|
-x "*/.gradle/" -x "*/app/build/*"
|
||||||
status="$?"
|
status="$?"
|
||||||
|
|
||||||
|
|||||||
Executable
+94
@@ -0,0 +1,94 @@
|
|||||||
|
#!/bin/sh -e
|
||||||
|
# 2026-10-10 Hyperling
|
||||||
|
# Stop a system from going into swap due to LLMs.
|
||||||
|
|
||||||
|
### Tuning ###
|
||||||
|
|
||||||
|
typeset -i sleep=10 full_pct=98 high_pct=90
|
||||||
|
|
||||||
|
### Functions ###
|
||||||
|
|
||||||
|
restart_service() {
|
||||||
|
if [ -z $1 ]; then
|
||||||
|
echo "ERROR: Service name must be passed to restart_service()."
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
|
sv restart $1
|
||||||
|
status=$?
|
||||||
|
if [[ $status != 0 ]]; then
|
||||||
|
echo "$1 failed to restart, returned $status."
|
||||||
|
return $status
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
# While we could loop over `ollama ps` and stop them, this ensures that the UIs
|
||||||
|
# do not sit around waiting for responses from the dead LLMs. It bring them up
|
||||||
|
# in a fresh state so that work can continue from a more clean slate.
|
||||||
|
restart_llms() {
|
||||||
|
restart_service ollama || killall ollama
|
||||||
|
#restart_service zeroclaw
|
||||||
|
#restart_service open-webui
|
||||||
|
#restart_service qwen-code
|
||||||
|
}
|
||||||
|
|
||||||
|
### Main ###
|
||||||
|
|
||||||
|
typeset -i {total,used}_{ram,swap}=0 \
|
||||||
|
used_{ram,swap}_pct=0 \
|
||||||
|
last_{ram,swap}_pct=100 \
|
||||||
|
count=0
|
||||||
|
|
||||||
|
while [[ true ]]; do
|
||||||
|
|
||||||
|
count=$(expr $count + 1 )
|
||||||
|
echo "$(date +'%Y-%m-%d @ %H:%M:%S') - Loop $count"
|
||||||
|
|
||||||
|
# RAM #
|
||||||
|
|
||||||
|
total_ram=$(free | awk '/^Mem:/ {print $2}')
|
||||||
|
used_ram=$(free | awk '/^Mem:/ {print $3}')
|
||||||
|
used_ram_pct=$( \
|
||||||
|
awk -v used="$used_ram" -v total="$total_ram" \
|
||||||
|
'BEGIN {printf "%d",(used/total)*100}' \
|
||||||
|
)
|
||||||
|
|
||||||
|
echo "Current RAM usage is $used_ram_pct%, was $last_ram_pct% last loop."
|
||||||
|
|
||||||
|
# Swap #
|
||||||
|
|
||||||
|
total_swap=$(free | awk '/^Swap:/ {print $2}')
|
||||||
|
used_swap=$(free | awk '/^Swap:/ {print $3}')
|
||||||
|
used_swap_pct=$( \
|
||||||
|
awk -v used="$used_swap" -v total="$total_swap" \
|
||||||
|
'BEGIN {printf "%d",(used/total)*100}' \
|
||||||
|
)
|
||||||
|
|
||||||
|
echo "Current swap usage is $used_swap_pct%, was $last_swap_pct% last loop."
|
||||||
|
|
||||||
|
# If RAM is full and swap is growing then restart LLM services.
|
||||||
|
if [ $used_ram_pct -gt $full_pct ] &&
|
||||||
|
[ $used_swap_pct -gt $last_swap_pct ]
|
||||||
|
then
|
||||||
|
echo "WARNING: RAM full and swap is growing. Restarting LLMs."
|
||||||
|
restart_llms
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
# If both are high then restart LLM services.
|
||||||
|
if [ $used_ram_pct -ge $high_pct ] &&
|
||||||
|
[ $used_swap_pct -ge $high_pct ]
|
||||||
|
then
|
||||||
|
echo "WARNING: RAM and swap both high. Restarting LLMs."
|
||||||
|
restart_llms
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
# Finish #
|
||||||
|
|
||||||
|
echo -e "Check finished, sleeping for ${sleep}...\n"
|
||||||
|
|
||||||
|
last_ram_pct=$used_ram_pct
|
||||||
|
last_swap_pct=$used_swap_pct
|
||||||
|
|
||||||
|
sleep $sleep
|
||||||
|
done
|
||||||
+93
-49
@@ -27,28 +27,6 @@ font pango:monospace 8
|
|||||||
# text rendering and scalability on retina/hidpi displays (thanks to pango).
|
# text rendering and scalability on retina/hidpi displays (thanks to pango).
|
||||||
#font pango:DejaVu Sans Mono 8
|
#font pango:DejaVu Sans Mono 8
|
||||||
|
|
||||||
# Start XDG autostart .desktop files using dex. See also
|
|
||||||
# https://wiki.archlinux.org/index.php/XDG_Autostart
|
|
||||||
exec --no-startup-id dex --autostart --environment i3
|
|
||||||
|
|
||||||
# The combination of xss-lock, nm-applet and pactl is a popular choice, so
|
|
||||||
# they are included here as an example. Modify as you see fit.
|
|
||||||
|
|
||||||
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
|
|
||||||
# screen before suspend. Use loginctl lock-session to lock your screen.
|
|
||||||
exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
|
|
||||||
|
|
||||||
# NetworkManager is the most popular way to manage wireless networks on Linux,
|
|
||||||
# and nm-applet is a desktop environment-independent system tray GUI for it.
|
|
||||||
exec --no-startup-id nm-applet
|
|
||||||
|
|
||||||
# Use pactl to adjust volume in PulseAudio.
|
|
||||||
set $refresh_i3status killall -SIGUSR1 i3status
|
|
||||||
#bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status
|
|
||||||
#bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status
|
|
||||||
#bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status
|
|
||||||
#bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
|
|
||||||
|
|
||||||
# Use Mouse+$mod to drag floating windows to their wanted position
|
# Use Mouse+$mod to drag floating windows to their wanted position
|
||||||
floating_modifier $mod
|
floating_modifier $mod
|
||||||
|
|
||||||
@@ -144,18 +122,23 @@ bindsym $mod+c exec codium-flatpak
|
|||||||
# light requires sudo privileges unless video group and udev are configured.
|
# light requires sudo privileges unless video group and udev are configured.
|
||||||
|
|
||||||
set $b_time 3000
|
set $b_time 3000
|
||||||
|
set $b_micro 5
|
||||||
set $b_small 10
|
set $b_small 10
|
||||||
set $b_large 20
|
set $b_large 20
|
||||||
|
|
||||||
# Use the bracket keys to change the brightness.
|
# Use the bracket keys to change the brightness.
|
||||||
bindsym $mod+bracketleft exec --no-startup-id "light -U $b_small && notify-send -t $b_time 'Brightness - ' $(light -G)"
|
bindsym $ctrl+bracketleft exec --no-startup-id "light -U $b_micro && notify-send -t $b_time 'Brightness - ' $(light -G)"
|
||||||
bindsym $mod+bracketright exec --no-startup-id "light -A $b_small && notify-send -t $b_time 'Brightness + ' $(light -G)"
|
bindsym $ctrl+bracketright exec --no-startup-id "light -A $b_micro && notify-send -t $b_time 'Brightness + ' $(light -G)"
|
||||||
|
bindsym $mod+bracketleft exec --no-startup-id "light -U $b_small && notify-send -t $b_time 'Brightness -- ' $(light -G)"
|
||||||
|
bindsym $mod+bracketright exec --no-startup-id "light -A $b_small && notify-send -t $b_time 'Brightness ++ ' $(light -G)"
|
||||||
bindsym $shift+$mod+bracketleft exec --no-startup-id "light -U $b_large && notify-send -t $b_time 'Brightness ---' $(light -G)"
|
bindsym $shift+$mod+bracketleft exec --no-startup-id "light -U $b_large && notify-send -t $b_time 'Brightness ---' $(light -G)"
|
||||||
bindsym $shift+$mod+bracketright exec --no-startup-id "light -A $b_large && notify-send -t $b_time 'Brightness +++' $(light -G)"
|
bindsym $shift+$mod+bracketright exec --no-startup-id "light -A $b_large && notify-send -t $b_time 'Brightness +++' $(light -G)"
|
||||||
|
|
||||||
# Also get the actual brightness keys to work!!
|
# Also get the actual brightness keys to work!!
|
||||||
bindsym XF86MonBrightnessUp exec --no-startup-id "light -A $b_small && notify-send -t $b_time 'Brightness + ' $(light -G)"
|
bindsym $ctrl+XF86MonBrightnessUp exec --no-startup-id "light -A $b_micro && notify-send -t $b_time 'Brightness + ' $(light -G)"
|
||||||
bindsym XF86MonBrightnessDown exec --no-startup-id "light -U $b_small && notify-send -t $b_time 'Brightness - ' $(light -G)"
|
bindsym $ctrl+XF86MonBrightnessDown exec --no-startup-id "light -U $b_micro && notify-send -t $b_time 'Brightness - ' $(light -G)"
|
||||||
|
bindsym XF86MonBrightnessUp exec --no-startup-id "light -A $b_small && notify-send -t $b_time 'Brightness ++ ' $(light -G)"
|
||||||
|
bindsym XF86MonBrightnessDown exec --no-startup-id "light -U $b_small && notify-send -t $b_time 'Brightness -- ' $(light -G)"
|
||||||
bindsym $shift+XF86MonBrightnessUp exec --no-startup-id "light -A $b_large && notify-send -t $b_time 'Brightness +++' $(light -G)"
|
bindsym $shift+XF86MonBrightnessUp exec --no-startup-id "light -A $b_large && notify-send -t $b_time 'Brightness +++' $(light -G)"
|
||||||
bindsym $shift+XF86MonBrightnessDown exec --no-startup-id "light -U $b_large && notify-send -t $b_time 'Brightness ---' $(light -G)"
|
bindsym $shift+XF86MonBrightnessDown exec --no-startup-id "light -U $b_large && notify-send -t $b_time 'Brightness ---' $(light -G)"
|
||||||
|
|
||||||
@@ -167,13 +150,17 @@ bindsym $shift+XF86MonBrightnessDown exec --no-startup-id "light -U $b_large &&
|
|||||||
# Macbooks tend to use 'sysfs/leds/smc::kbd_backlight'
|
# Macbooks tend to use 'sysfs/leds/smc::kbd_backlight'
|
||||||
# NovaCustom laptop is 'sysfs/leds/system76_acpi::kbd_backlight'
|
# NovaCustom laptop is 'sysfs/leds/system76_acpi::kbd_backlight'
|
||||||
# Some other laptops may be 'sysfs/class/leds/...', use ìght -L`to find out.
|
# Some other laptops may be 'sysfs/class/leds/...', use ìght -L`to find out.
|
||||||
bindsym XF86KbdBrightnessUp exec "light -s sysfs/leds/smc::kbd_backlight -A $b_small && notify-send -t $b_time 'Keyboard Brightness + ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $ctrl+XF86KbdBrightnessUp exec "light -s sysfs/leds/smc::kbd_backlight -A $b_micro && notify-send -t $b_time 'Keyboard Brightness + ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
bindsym XF86KbdBrightnessDown exec "light -s sysfs/leds/smc::kbd_backlight -U $b_small && notify-send -t $b_time 'Keyboard Brightness - ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $ctrl+XF86KbdBrightnessDown exec "light -s sysfs/leds/smc::kbd_backlight -U $b_micro && notify-send -t $b_time 'Keyboard Brightness - ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
|
bindsym XF86KbdBrightnessUp exec "light -s sysfs/leds/smc::kbd_backlight -A $b_small && notify-send -t $b_time 'Keyboard Brightness ++ ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
|
bindsym XF86KbdBrightnessDown exec "light -s sysfs/leds/smc::kbd_backlight -U $b_small && notify-send -t $b_time 'Keyboard Brightness -- ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
bindsym $shift+XF86KbdBrightnessUp exec "light -s sysfs/leds/smc::kbd_backlight -A $b_large && notify-send -t $b_time 'Keyboard Brightness +++' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $shift+XF86KbdBrightnessUp exec "light -s sysfs/leds/smc::kbd_backlight -A $b_large && notify-send -t $b_time 'Keyboard Brightness +++' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
bindsym $shift+XF86KbdBrightnessDown exec "light -s sysfs/leds/smc::kbd_backlight -U $b_large && notify-send -t $b_time 'Keyboard Brightness ---' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $shift+XF86KbdBrightnessDown exec "light -s sysfs/leds/smc::kbd_backlight -U $b_large && notify-send -t $b_time 'Keyboard Brightness ---' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
|
|
||||||
bindsym $mod+apostrophe exec "light -s sysfs/leds/smc::kbd_backlight -A $b_small && notify-send -t $b_time 'Keyboard Brightness + ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $ctrl+apostrophe exec "light -s sysfs/leds/smc::kbd_backlight -A $b_micro && notify-send -t $b_time 'Keyboard Brightness + ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
bindsym $mod+semicolon exec "light -s sysfs/leds/smc::kbd_backlight -U $b_small && notify-send -t $b_time 'Keyboard Brightness - ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $ctrl+semicolon exec "light -s sysfs/leds/smc::kbd_backlight -U $b_micro && notify-send -t $b_time 'Keyboard Brightness - ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
|
bindsym $mod+apostrophe exec "light -s sysfs/leds/smc::kbd_backlight -A $b_small && notify-send -t $b_time 'Keyboard Brightness ++ ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
|
bindsym $mod+semicolon exec "light -s sysfs/leds/smc::kbd_backlight -U $b_small && notify-send -t $b_time 'Keyboard Brightness -- ' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
bindsym $shift+$mod+apostrophe exec "light -s sysfs/leds/smc::kbd_backlight -A $b_large && notify-send -t $b_time 'Keyboard Brightness +++' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $shift+$mod+apostrophe exec "light -s sysfs/leds/smc::kbd_backlight -A $b_large && notify-send -t $b_time 'Keyboard Brightness +++' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
bindsym $shift+$mod+semicolon exec "light -s sysfs/leds/smc::kbd_backlight -U $b_large && notify-send -t $b_time 'Keyboard Brightness ---' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
bindsym $shift+$mod+semicolon exec "light -s sysfs/leds/smc::kbd_backlight -U $b_large && notify-send -t $b_time 'Keyboard Brightness ---' $(light -s sysfs/leds/smc::kbd_backlight -G)"
|
||||||
|
|
||||||
@@ -182,26 +169,30 @@ bindsym $shift+$mod+semicolon exec "light -s sysfs/leds/smc::kbd_backlight -U $
|
|||||||
# The volume function is from https://git.hyperling.com/me/env-ansible
|
# The volume function is from https://git.hyperling.com/me/env-ansible
|
||||||
|
|
||||||
set $v_time 1500
|
set $v_time 1500
|
||||||
set $v_small 5
|
set $v_micro 5
|
||||||
|
set $v_small 10
|
||||||
set $v_large 25
|
set $v_large 25
|
||||||
|
|
||||||
# Use the comma and period keys to change volume.
|
# Use the comma and period keys to change volume.
|
||||||
bindsym $mod+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_small && notify-send -t $v_time "Volume - " $(volume)'
|
bindsym $ctrl+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_micro && notify-send -t $v_time "Volume - " $(volume)'
|
||||||
bindsym $mod+period exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_small && notify-send -t $v_time "Volume + " $(volume)'
|
bindsym $ctrl+period exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_micro && notify-send -t $v_time "Volume + " $(volume)'
|
||||||
|
bindsym $mod+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_small && notify-send -t $v_time "Volume -- " $(volume)'
|
||||||
|
bindsym $mod+period exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_small && notify-send -t $v_time "Volume ++ " $(volume)'
|
||||||
bindsym $shift+$mod+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_large && notify-send -t $v_time "Volume ---" $(volume)'
|
bindsym $shift+$mod+comma exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_large && notify-send -t $v_time "Volume ---" $(volume)'
|
||||||
bindsym $shift+$mod+period exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_large && notify-send -t $v_time "Volume +++" $(volume)'
|
bindsym $shift+$mod+period exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_large && notify-send -t $v_time "Volume +++" $(volume)'
|
||||||
|
|
||||||
# Actual volume keys.
|
# Actual volume keys.
|
||||||
bindsym XF86AudioMute exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume mute && notify-send -t $v_time "Volume Muted" $(volume)'
|
bindsym XF86AudioMute exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume mute && notify-send -t $v_time "Volume Muted" $(volume)'
|
||||||
bindsym XF86AudioRaiseVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_small && notify-send -t $v_time "Volume + " $(volume)'
|
bindsym $ctrl+XF86AudioRaiseVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_micro && notify-send -t $v_time "Volume + " $(volume)'
|
||||||
bindsym XF86AudioLowerVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_small && notify-send -t $v_time "Volume - " $(volume)'
|
bindsym $ctrl+XF86AudioLowerVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_micro && notify-send -t $v_time "Volume - " $(volume)'
|
||||||
|
bindsym XF86AudioRaiseVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_small && notify-send -t $v_time "Volume ++ " $(volume)'
|
||||||
|
bindsym XF86AudioLowerVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_small && notify-send -t $v_time "Volume -- " $(volume)'
|
||||||
bindsym $shift+XF86AudioRaiseVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_large && notify-send -t $v_time "Volume +++ " $(volume)'
|
bindsym $shift+XF86AudioRaiseVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume +$v_large && notify-send -t $v_time "Volume +++ " $(volume)'
|
||||||
bindsym $shift+XF86AudioLowerVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_large && notify-send -t $v_time "Volume --- " $(volume)'
|
bindsym $shift+XF86AudioLowerVolume exec --no-startup-id bash -c 'source /usr/local/bin/volume.function && volume -$v_large && notify-send -t $v_time "Volume --- " $(volume)'
|
||||||
|
|
||||||
bindsym $mod+slash exec pavucontrol
|
bindsym $mod+slash exec pavucontrol
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
## Workspaces ##
|
## Workspaces ##
|
||||||
|
|
||||||
# Define names for default workspaces for which we configure key bindings later on.
|
# Define names for default workspaces for which we configure key bindings later on.
|
||||||
@@ -287,20 +278,22 @@ assign [class="(?i).*mpv.*"] $ws9
|
|||||||
|
|
||||||
assign [class="(?i).*vpn.*"] $ws0
|
assign [class="(?i).*vpn.*"] $ws0
|
||||||
assign [class="(?i).*mullvad.*"] $ws0
|
assign [class="(?i).*mullvad.*"] $ws0
|
||||||
|
assign [class="(?i).*gnome-system-monitor.*"] $ws0
|
||||||
|
|
||||||
|
|
||||||
## Workspace Specific Workflows ##
|
## Workspace Specific Workflows ##
|
||||||
bindsym $ctrl+$shift+1 workspace $ws1; exec "i3-sensible-terminal & gnome-system-monitor"
|
#bindsym $ctrl+$shift+1 workspace $ws1; exec "i3-sensible-terminal & gnome-system-monitor"
|
||||||
|
bindsym $ctrl+$shift+1 workspace $ws1; exec "i3-sensible-terminal & i3-sensible-terminal btop -u 500"
|
||||||
bindsym $ctrl+$shift+2 workspace $ws2; exec $FIREFOX
|
bindsym $ctrl+$shift+2 workspace $ws2; exec $FIREFOX
|
||||||
bindsym $ctrl+$shift+3 workspace $ws3; exec "(codium || vscodium || codium-flatpak || vscodium-flatpak)"
|
bindsym $ctrl+$shift+3 workspace $ws3; exec "(codium || vscodium || codium-flatpak || vscodium-flatpak)"
|
||||||
bindsym $ctrl+$shift+4 workspace $ws4; exec "android-studio || android-studio-flatpak"
|
bindsym $ctrl+$shift+4 workspace $ws4; exec "android-studio || android-studio-flatpak"
|
||||||
bindsym $ctrl+$shift+5 workspace $ws5; exec "(signal || signal-flatpak) & (dino || dino-flatpak) & (forkgram || forkgram-flatpak || telegram || telegram-flatpak)"
|
bindsym $ctrl+$shift+5 workspace $ws5; exec "(signal || signal-flatpak) & (dino || dino-flatpak)"
|
||||||
bindsym $alt+$shift+5 workspace $ws5; exec "(forkgram || forkgram-flatpak || telegram || telegram-flatpak) & (session || session-flatpak)"
|
bindsym $alt+$shift+5 workspace $ws5; exec "(session || session-flatpak) & (forkgram || forkgram-flatpak || telegram || telegram-flatpak)"
|
||||||
bindsym $ctrl+$shift+6 workspace $ws6; exec "pavucontrol & blueman-manager"
|
bindsym $ctrl+$shift+6 workspace $ws6; exec "pavucontrol & blueman-manager"
|
||||||
bindsym $ctrl+$shift+7 workspace $ws7; exec $TRANSMISSION
|
bindsym $ctrl+$shift+7 workspace $ws7; exec $TRANSMISSION
|
||||||
bindsym $ctrl+$shift+8 workspace $ws8; exec strawberry
|
bindsym $ctrl+$shift+8 workspace $ws8; exec strawberry
|
||||||
bindsym $ctrl+$shift+9 workspace $ws9; exec thunar
|
bindsym $ctrl+$shift+9 workspace $ws9; exec thunar
|
||||||
bindsym $ctrl+$shift+0 workspace $ws0; exec mullvad-vpn
|
bindsym $ctrl+$shift+0 workspace $ws0; exec "mullvad-vpn & gnome-system-monitor"
|
||||||
|
|
||||||
|
|
||||||
## Reloads, Restarts, Exit ##
|
## Reloads, Restarts, Exit ##
|
||||||
@@ -316,15 +309,29 @@ bindsym $mod+Shift+e exec "i3-nagbar -t warning -m 'You pressed the exit shortcu
|
|||||||
bindsym $mod+Shift+q exec "i3-msg exit"
|
bindsym $mod+Shift+q exec "i3-msg exit"
|
||||||
|
|
||||||
# lock
|
# lock
|
||||||
bindsym $ctrl+$alt+l exec "i3lock -c 000000 -e -f && sleep 1 && xset dpms force off"
|
#set $LOCK_CMD "i3lock -c 333333 -e -f && sleep 1 && xset dpms force off"
|
||||||
bindsym $ctrl+$mod+l exec "i3lock -c 000000 -e -f && sleep 1 && xset dpms force off"
|
set $LOCK_CMD "loginctl lock-session"
|
||||||
bindsym $shift+$mod+l exec "i3lock -c 000000 -e -f && sleep 1 && xset dpms force off"
|
bindsym $ctrl+$alt+l exec $LOCK_CMD
|
||||||
|
bindsym $ctrl+$mod+l exec $LOCK_CMD
|
||||||
|
bindsym $shift+$mod+l exec $LOCK_CMD
|
||||||
|
|
||||||
# shutdown entire system.
|
# shutdown entire system.
|
||||||
#bindsym $ctrl+$shift+q exec dbus-send --system --print-reply --dest="org.freedesktop.ConsoleKit" /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Stop
|
#bindsym $ctrl+$shift+q exec dbus-send --system --print-reply --dest="org.freedesktop.ConsoleKit" /org/freedesktop/ConsoleKit/Manager org.freedesktop.ConsoleKit.Manager.Stop
|
||||||
bindsym $ctrl+$alt+q exec sudo shutdown -h now
|
bindsym $ctrl+$alt+$mod+q exec sudo shutdown -h now
|
||||||
bindsym $shift+$alt+q exec sudo shutdown -h now
|
bindsym $shift+$alt+$mod+q exec sudo shutdown -h now
|
||||||
bindsym $shift+$ctrl+q exec sudo shutdown -h now
|
bindsym $shift+$ctrl+$mod+q exec sudo shutdown -h now
|
||||||
|
|
||||||
|
# restart entire system.
|
||||||
|
bindsym $ctrl+$alt+$mod+r exec sudo shutdown -r now
|
||||||
|
bindsym $shift+$alt+$mod+r exec sudo shutdown -r now
|
||||||
|
bindsym $shift+$ctrl+$mod+r exec sudo shutdown -r now
|
||||||
|
|
||||||
|
# restart LLM programs
|
||||||
|
set $RESTART_LLMS "sudo sv restart ollama; sudo sv restart zeroclaw; sudo sv restart open-webui"
|
||||||
|
bindsym $ctrl+$alt+delete exec $RESTART_LLMS
|
||||||
|
bindsym $shift+$alt+delete exec $RESTART_LLMS
|
||||||
|
bindsym $shift+$ctrl+delete exec $RESTART_LLMS
|
||||||
|
|
||||||
|
|
||||||
## Resizing (Disabled) ##
|
## Resizing (Disabled) ##
|
||||||
|
|
||||||
@@ -369,11 +376,12 @@ bar {
|
|||||||
|
|
||||||
# Workspace 1
|
# Workspace 1
|
||||||
exec --no-startup-id i3-sensible-terminal
|
exec --no-startup-id i3-sensible-terminal
|
||||||
exec --no-startup-id gnome-system-monitor
|
exec --no-startup-id i3-sensible-terminal btop -u 500
|
||||||
|
|
||||||
# Respective Workspaces
|
# Respective Workspaces
|
||||||
exec --no-startup-id mullvad-vpn
|
exec --no-startup-id mullvad-vpn
|
||||||
exec --no-startup-id $TRANSMISSION
|
exec --no-startup-id $TRANSMISSION
|
||||||
|
exec --no-startup-id gnome-system-monitor
|
||||||
|
|
||||||
# Set defaults for laptop backlights.
|
# Set defaults for laptop backlights.
|
||||||
exec --no-startup-id "light -S 20; light -N 5; light -O"
|
exec --no-startup-id "light -S 20; light -N 5; light -O"
|
||||||
@@ -390,7 +398,7 @@ exec_always --no-startup-id "sleep 00; killall pipewire wireplumber pipewire-pul
|
|||||||
exec_always --no-startup-id "sleep 01; pipewire >~/Reports/pipewire.log 2>&1 &"
|
exec_always --no-startup-id "sleep 01; pipewire >~/Reports/pipewire.log 2>&1 &"
|
||||||
exec_always --no-startup-id "sleep 02; wireplumber >~/Reports/wireplumber.log 2>&1 &"
|
exec_always --no-startup-id "sleep 02; wireplumber >~/Reports/wireplumber.log 2>&1 &"
|
||||||
exec_always --no-startup-id "sleep 03; pipewire-pulse >~/Reports/pipewire-pulse.log 2>&1 &"
|
exec_always --no-startup-id "sleep 03; pipewire-pulse >~/Reports/pipewire-pulse.log 2>&1 &"
|
||||||
exec --no-startup-id "sleep 04; bash -c 'source /usr/local/bin/volume.function && volume 25'"
|
exec --no-startup-id "sleep 04; bash -c 'source /usr/local/bin/volume.function && volume 75'"
|
||||||
|
|
||||||
# Wallpaper
|
# Wallpaper
|
||||||
exec_always --no-startup-id feh --recursive --randomize --bg-fill ~/Pictures/Wallpapers
|
exec_always --no-startup-id feh --recursive --randomize --bg-fill ~/Pictures/Wallpapers
|
||||||
@@ -404,4 +412,40 @@ exec_always --no-startup-id bash -c 'pkill -ef "bash `which battery_nag.sh`" >~/
|
|||||||
# Redshift
|
# Redshift
|
||||||
#exec_always --no-startup-id "killall redshift-gtk; redshift-gtk"
|
#exec_always --no-startup-id "killall redshift-gtk; redshift-gtk"
|
||||||
#exec_always --no-startup-id "killall redshift; redshift -l 35.19540:-111.65720 -t 6500K:1100K"
|
#exec_always --no-startup-id "killall redshift; redshift -l 35.19540:-111.65720 -t 6500K:1100K"
|
||||||
exec_always --no-startup-id "killall redshift; killall redshift-gtk; sleep 1; redshift -x; redshift-gtk -l 35.19540:-111.65720 -t 6500K:1100K"
|
exec_always --no-startup-id "killall redshift; killall redshift-gtk; sleep 1; redshift -x; redshift-gtk -l 32:-111 -t 6500K:1100K"
|
||||||
|
|
||||||
|
# Allow locking the session.
|
||||||
|
#set $AGENT pkttyagent
|
||||||
|
set $AGENT lxqt-policykit-agent
|
||||||
|
exec_always --no-startup-id "killall $AGENT; $AGENT"
|
||||||
|
|
||||||
|
# Start XDG autostart .desktop files using dex. See also
|
||||||
|
# https://wiki.archlinux.org/index.php/XDG_Autostart
|
||||||
|
exec --no-startup-id dex --autostart --environment i3
|
||||||
|
|
||||||
|
# The combination of xss-lock, nm-applet and pactl is a popular choice, so
|
||||||
|
# they are included here as an example. Modify as you see fit.
|
||||||
|
|
||||||
|
# xss-lock grabs a logind suspend inhibit lock and will use i3lock to lock the
|
||||||
|
# screen before suspend. Use loginctl lock-session to lock your screen.
|
||||||
|
#exec --no-startup-id xss-lock --transfer-sleep-lock -- i3lock --nofork
|
||||||
|
#exec_always --no-startup-id xss-lock --transfer-sleep-lock -- i3lock -c 111111 -e -f --nofork
|
||||||
|
exec_always --no-startup-id xss-lock --transfer-sleep-lock -- sh -c 'i3lock -c 111111 -e -f --nofork & sleep 1; xset dpms force off; wait'
|
||||||
|
|
||||||
|
# NetworkManager is the most popular way to manage wireless networks on Linux,
|
||||||
|
# and nm-applet is a desktop environment-independent system tray GUI for it.
|
||||||
|
exec --no-startup-id nm-applet
|
||||||
|
|
||||||
|
# Use pactl to adjust volume in PulseAudio.
|
||||||
|
set $refresh_i3status killall -SIGUSR1 i3status
|
||||||
|
#bindsym XF86AudioRaiseVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ +10% && $refresh_i3status
|
||||||
|
#bindsym XF86AudioLowerVolume exec --no-startup-id pactl set-sink-volume @DEFAULT_SINK@ -10% && $refresh_i3status
|
||||||
|
#bindsym XF86AudioMute exec --no-startup-id pactl set-sink-mute @DEFAULT_SINK@ toggle && $refresh_i3status
|
||||||
|
#bindsym XF86AudioMicMute exec --no-startup-id pactl set-source-mute @DEFAULT_SOURCE@ toggle && $refresh_i3status
|
||||||
|
|
||||||
|
# Sunset Alarm
|
||||||
|
#exec_always --no-startup-id "killall sunset-alarm; /home/ling/Code/sunset_alarm_cli/sunset-alarm -t 20:00 -m 30 > ~/Reports/sunset-alarm.log 2>&1"
|
||||||
|
exec_always --no-startup-id "killall sunset-alarm; /home/ling/Code/sunset_alarm_cli/sunset-alarm -l 32:-111 -m 30 > ~/Reports/sunset-alarm.log 2>&1"
|
||||||
|
|
||||||
|
# Bedtime ;)
|
||||||
|
exec --no-startup-id "while true; do if [[ `date +'%H'` -ge 20 ]]; then fyi -w -u critical 'Bedtime' 'Go to sleep! >:)'; fi; sleep 150; done"
|
||||||
Binary file not shown.
File diff suppressed because it is too large.
Load diff
@@ -7,6 +7,7 @@
|
|||||||
"update.showReleaseNotes": false,
|
"update.showReleaseNotes": false,
|
||||||
"workbench.startupEditor": "none",
|
"workbench.startupEditor": "none",
|
||||||
"git.confirmSync": false,
|
"git.confirmSync": false,
|
||||||
|
"workbench.editor.openPositioning": "last",
|
||||||
|
|
||||||
"editor.rulers": [
|
"editor.rulers": [
|
||||||
80, 120, 200,
|
80, 120, 200,
|
||||||
|
|||||||
@@ -3,3 +3,6 @@
|
|||||||
|
|
||||||
# Allow anyone in the sudo group to shutdown or reboot without a password.
|
# Allow anyone in the sudo group to shutdown or reboot without a password.
|
||||||
%sudo ALL=(ALL) NOPASSWD: /sbin/shutdown, /usr/sbin/shutdown, /sbin/reboot, /usr/sbin/reboot
|
%sudo ALL=(ALL) NOPASSWD: /sbin/shutdown, /usr/sbin/shutdown, /sbin/reboot, /usr/sbin/reboot
|
||||||
|
|
||||||
|
# Allow the sudo group to manage runit services.
|
||||||
|
%sudo ALL=(ALL) NOPASSWD: /sbin/sv, /usr/sbin/sv, /sbin/sv, /usr/sbin/sv
|
||||||
@@ -2,317 +2,238 @@
|
|||||||
# Harmonize systems rather than doing everything manually. :)
|
# Harmonize systems rather than doing everything manually. :)
|
||||||
|
|
||||||
# Setup of any device connected to this repo.
|
# Setup of any device connected to this repo.
|
||||||
- name: Main | Default Setup
|
- name: Local | Main
|
||||||
hosts: localhost
|
hosts: localhost
|
||||||
connection: local
|
connection: local
|
||||||
become: true
|
become: true
|
||||||
|
|
||||||
tasks:
|
tasks:
|
||||||
|
|
||||||
####### Lock #######
|
####### Header #######
|
||||||
# Ensure a process is not already running.
|
|
||||||
- name: Main | Lock
|
|
||||||
block:
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/tests/lock_check.yml
|
|
||||||
- include_tasks: tasks/general/tests/lock_create.yml
|
|
||||||
|
|
||||||
|
|
||||||
####### Gather #######
|
|
||||||
# Load facts for all systems.
|
|
||||||
- name: Main | Gather
|
|
||||||
block:
|
|
||||||
|
|
||||||
- include_tasks: facts/general/gather.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/provision_config.yml
|
|
||||||
|
|
||||||
- include_tasks: facts/general/system.yml
|
|
||||||
- include_tasks: facts/general/package.yml
|
|
||||||
- include_tasks: facts/general/service.yml
|
|
||||||
- include_tasks: facts/general/user.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/tests/internet_check.yml
|
|
||||||
|
|
||||||
|
|
||||||
####### Start #######
|
|
||||||
- name: Main | Start
|
|
||||||
block:
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/notify.yml
|
|
||||||
vars:
|
|
||||||
notify_message: "Provisioning Started"
|
|
||||||
|
|
||||||
when: workstation
|
|
||||||
|
|
||||||
####### NixOS #######
|
|
||||||
# Install the .nix files and do a little data setup.
|
|
||||||
- name: Main | NixOS Setup
|
|
||||||
block:
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/software/nixos.yml
|
|
||||||
|
|
||||||
# TBD if we are going to use this many, then just have IF statements
|
|
||||||
# and use blocks within the General area for NixOS vs not-NixOS.
|
|
||||||
- include_tasks: tasks/general/software/swap.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/groups.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/users.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/sudo.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/doas.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/scripts/root.yml
|
|
||||||
- include_tasks: tasks/general/scripts/user.yml
|
|
||||||
- include_tasks: tasks/general/scripts/install.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/cron/ansible.yml
|
|
||||||
|
|
||||||
# psutil does not work in NixOS. Cannot figure out how to fix it. Maybe
|
|
||||||
# time to start looking into home-manager but still not wanting to
|
|
||||||
# maintain two different GNOME setups. HMMMM!
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/gnome.yml
|
|
||||||
when: workstation
|
|
||||||
|
|
||||||
# Try including these. Really need to get NixOS working with the rest!
|
|
||||||
#- include_tasks: tasks/general/software/telegraf.yml # "Could not find a module for unknown.""
|
|
||||||
- include_tasks: tasks/general/tests/services.yml
|
|
||||||
- include_tasks: tasks/general/tests/lynis.yml
|
|
||||||
- include_tasks: tasks/general/tests/nmap.yml
|
|
||||||
|
|
||||||
- name: NixOS | Complete
|
|
||||||
ansible.builtin.meta: end_play
|
|
||||||
|
|
||||||
when: ansible_distribution == "NixOS"
|
|
||||||
|
|
||||||
|
|
||||||
####### General #######
|
|
||||||
# Basic setup for all enabled systems.
|
|
||||||
- name: Main | General Setup
|
|
||||||
block:
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/software/swap.yml
|
|
||||||
- include_tasks: tasks/general/software/packages.yml
|
|
||||||
when: internet
|
|
||||||
- include_tasks: tasks/general/software/services.yml
|
|
||||||
- include_tasks: tasks/general/software/sendmail.yml
|
|
||||||
when: ansible_system == "FreeBSD"
|
|
||||||
and internet
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/software/aur.yml
|
|
||||||
when: internet and ansible_pkg_mgr == "pacman"
|
|
||||||
|
|
||||||
# Gather again in case missing programs have now been installed.
|
|
||||||
- include_tasks: facts/general/gather.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/settings/keyboard.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/groups.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/users.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/sudo.yml
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/doas.yml
|
|
||||||
when: internet
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/software/env-shared.yml
|
|
||||||
when: internet
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/scripts/root.yml
|
|
||||||
- include_tasks: tasks/general/scripts/user.yml
|
|
||||||
- include_tasks: tasks/general/scripts/install.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/cron/ansible.yml
|
|
||||||
|
|
||||||
# TODO Need to refactor. Maybe tasks/general/cron/freebsd.yml
|
|
||||||
- include_tasks: tasks/workstation/freebsd/cron/ansible.yml
|
|
||||||
when: ansible_system == "FreeBSD"
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/software/metasploit.yml
|
|
||||||
when: internet
|
|
||||||
|
|
||||||
when: provision
|
|
||||||
|
|
||||||
|
- name: Main | Header
|
||||||
|
ansible.builtin.include_tasks: tasks/header.yml
|
||||||
|
|
||||||
####### Workstations #######
|
####### Workstations #######
|
||||||
|
|
||||||
# Additional setup for systems with GUI.
|
# Additional setup for systems with GUI.
|
||||||
- name: Main | Workstation Setup
|
- name: Main | Workstation
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- include_tasks: facts/workstation/package.yml
|
- ansible.builtin.include_tasks: facts/workstation/package.yml
|
||||||
|
|
||||||
## Desktop Environments ##
|
## Desktop Environments ##
|
||||||
- include_tasks: tasks/workstation/freebsd/software/gpu.yml
|
- ansible.builtin.include_tasks: tasks/workstation/freebsd/software/gpu.yml
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
||||||
and bsd_gpu
|
and bsd_gpu
|
||||||
and internet
|
and internet
|
||||||
|
|
||||||
# Window Managers without true Desktop Environments #
|
# Window Managers without true Desktop Environments #
|
||||||
- include_tasks: tasks/workstation/shared/software/dwm.yml
|
- ansible.builtin.include_tasks: tasks/workstation/shared/software/dwm.yml
|
||||||
when: internet
|
when: internet
|
||||||
- include_tasks: tasks/workstation/shared/software/i3.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/shared/software/i3.yml
|
||||||
when: internet
|
when: internet
|
||||||
|
|
||||||
# Polished Desktop Environments #
|
# Polished Desktop Environments #
|
||||||
- include_tasks: tasks/workstation/freebsd/software/gnome.yml
|
- ansible.builtin.include_tasks: tasks/workstation/freebsd/software/gnome.yml
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
||||||
and internet
|
and internet
|
||||||
|
|
||||||
- name: Main | Workstation | Fancy Desktop Environments
|
- name: Main | Workstation | Fancy Desktop Environments
|
||||||
block:
|
block:
|
||||||
- include_tasks: tasks/workstation/linux/software/gnome.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/gnome.yml
|
||||||
when: ansible_service_mgr == "systemd"
|
when: ansible_service_mgr == "systemd"
|
||||||
- include_tasks: tasks/workstation/linux/software/cinnamon.yml
|
|
||||||
- include_tasks: tasks/workstation/linux/software/lxqt.yml
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/cinnamon.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/lxqt.yml
|
||||||
|
|
||||||
when: ansible_system == "Linux"
|
when: ansible_system == "Linux"
|
||||||
and internet
|
and internet
|
||||||
# TBD: Implement this: and extra_desktops
|
# TBD: Implement this: and extra_desktops
|
||||||
|
|
||||||
## Software Tasks ##
|
## Software Tasks ##
|
||||||
|
|
||||||
- name: Main | Workstation Setup | Linux
|
- name: Main | Workstation | Linux
|
||||||
block:
|
block:
|
||||||
- include_tasks: tasks/workstation/linux/software/packages.yml
|
|
||||||
- include_tasks: tasks/workstation/linux/software/tlp.yml
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/packages.yml
|
||||||
- include_tasks: tasks/workstation/linux/software/lutris.yml
|
|
||||||
- include_tasks: tasks/workstation/linux/software/vscodium.yml
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/tlp.yml
|
||||||
- include_tasks: tasks/workstation/linux/software/vpn.yml
|
|
||||||
- include_tasks: tasks/workstation/linux/software/nodejs.yml
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/lutris.yml
|
||||||
- include_tasks: tasks/workstation/linux/software/hugo.yml
|
|
||||||
- include_tasks: tasks/workstation/linux/software/brave.yml
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/vscodium.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/vpn.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/nodejs.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/hugo.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/brave.yml
|
||||||
when: ansible_pkg_mgr in ("apt", "dnf", "zypper") and not mobile
|
when: ansible_pkg_mgr in ("apt", "dnf", "zypper") and not mobile
|
||||||
|
|
||||||
when: ansible_system == "Linux"
|
when: ansible_system == "Linux"
|
||||||
and internet
|
and internet
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/freebsd/software/packages.yml
|
- ansible.builtin.include_tasks: tasks/workstation/freebsd/software/packages.yml
|
||||||
when: ansible_system == "FreeBSD"
|
when: ansible_system == "FreeBSD"
|
||||||
and internet
|
and internet
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/mac-os/software/brew.yml
|
- ansible.builtin.include_tasks: tasks/workstation/mac-os/software/brew.yml
|
||||||
when: ansible_system == "Darwin"
|
when: ansible_system == "Darwin"
|
||||||
and internet
|
and internet
|
||||||
|
|
||||||
## Configuration Tasks ##
|
## Configuration Tasks ##
|
||||||
- name: Main | Workstation Setup | Configuration
|
|
||||||
block:
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/gnome.yml
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/cinnamon.yml
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/xdg_autostart.yml
|
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/linux/cron/ansible.yml
|
- name: Main | Workstation | Configuration
|
||||||
|
block:
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/gnome.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/cinnamon.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/xdg_autostart.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/cron/ansible.yml
|
||||||
when: ansible_system == "Linux"
|
when: ansible_system == "Linux"
|
||||||
|
|
||||||
when: not mobile
|
when: not mobile
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/nfs.yml
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/nfs.yml
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/rdp.yml
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/rdp.yml
|
||||||
when: rdp
|
when: rdp
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/vnc.yml
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/vnc.yml
|
||||||
when: vnc
|
when: vnc
|
||||||
|
|
||||||
- include_tasks: tasks/workstation/shared/settings/services.yml
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/services.yml
|
||||||
- include_tasks: tasks/workstation/shared/settings/templates.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/templates.yml
|
||||||
|
|
||||||
## Final Tasks (SLOW) ##
|
## Final Tasks (SLOW) ##
|
||||||
- name: Main | Workstation Setup | Linux [Slow]
|
|
||||||
|
- name: Main | Workstation | Linux [Slow]
|
||||||
block:
|
block:
|
||||||
- include_tasks: tasks/workstation/linux/software/flatpaks.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/flatpaks.yml
|
||||||
when: flatpak_distro
|
when: flatpak_distro
|
||||||
- include_tasks: tasks/workstation/linux/software/java.yml
|
|
||||||
- include_tasks: tasks/workstation/linux/software/flutter.yml
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/java.yml
|
||||||
- include_tasks: tasks/workstation/linux/software/android.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/flutter.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/android.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/docker.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/linux/software/ai/llm.yml
|
||||||
|
|
||||||
when: ansible_system == "Linux"
|
when: ansible_system == "Linux"
|
||||||
and internet
|
and internet
|
||||||
|
|
||||||
when: workstation
|
when: workstation
|
||||||
|
|
||||||
|
|
||||||
# No longer mining, this is now considered deprecated.
|
# No longer mining, this is now considered deprecated.
|
||||||
# ####### Miners #######
|
# ####### Miners #######
|
||||||
#
|
#
|
||||||
# # Additional setup for miners.
|
# # Additional setup for miners.
|
||||||
# - name: Main | Miner Setup
|
# - name: Main | Miner
|
||||||
# block:
|
# block:
|
||||||
#
|
#
|
||||||
# ##### Setup #####
|
# ##### Setup #####
|
||||||
# - include_tasks: tasks/miner/debug.yml
|
# - ansible.builtin.include_tasks: tasks/miner/debug.yml
|
||||||
#
|
#
|
||||||
# - include_tasks: tasks/miner/acct_mgmt/users.yml
|
# - ansible.builtin.include_tasks: tasks/miner/acct_mgmt/users.yml
|
||||||
#
|
#
|
||||||
# - include_tasks: facts/miner/system.yml
|
# - ansible.builtin.include_tasks: facts/miner/system.yml
|
||||||
# - include_tasks: facts/miner/config.yml
|
# - ansible.builtin.include_tasks: facts/miner/config.yml
|
||||||
# - include_tasks: facts/miner/pool.yml
|
# - ansible.builtin.include_tasks: facts/miner/pool.yml
|
||||||
#
|
#
|
||||||
# ##### Installations #####
|
# ##### Installations #####
|
||||||
# ### CPU SECTION ###
|
# ### CPU SECTION ###
|
||||||
# # Monero #
|
# # Monero #
|
||||||
# - include_tasks: tasks/miner/software/xmr-stak-cpu.yml
|
# - ansible.builtin.include_tasks: tasks/miner/software/xmr-stak-cpu.yml
|
||||||
# when: xmr_stak_cpu is defined
|
# when: xmr_stak_cpu is defined
|
||||||
#
|
#
|
||||||
# ### GPU Section ###
|
# ### GPU Section ###
|
||||||
# ## Drivers ##
|
# ## Drivers ##
|
||||||
# - include_tasks: tasks/miner/drivers/amdgpu.yml
|
# - ansible.builtin.include_tasks: tasks/miner/drivers/amdgpu.yml
|
||||||
# when: ansible_distribution == "Ubuntu" and amdgpu
|
# when: ansible_distribution == "Ubuntu" and amdgpu
|
||||||
#
|
#
|
||||||
# # Ethereum #
|
# # Ethereum #
|
||||||
# - include_tasks: tasks/miner/software/ethminer.yml
|
# - ansible.builtin.include_tasks: tasks/miner/software/ethminer.yml
|
||||||
# when: ethminer
|
# when: ethminer
|
||||||
#
|
#
|
||||||
# - include_tasks: tasks/miner/software/nanominer.yml
|
# - ansible.builtin.include_tasks: tasks/miner/software/nanominer.yml
|
||||||
# when: nanominer
|
# when: nanominer
|
||||||
#
|
#
|
||||||
# ##### Scheduling #####
|
# ##### Scheduling #####
|
||||||
# - include_tasks: tasks/miner/cron/ansible.yml
|
# - ansible.builtin.include_tasks: tasks/miner/cron/ansible.yml
|
||||||
# - include_tasks: tasks/miner/cron/mfn.yml
|
# - ansible.builtin.include_tasks: tasks/miner/cron/mfn.yml
|
||||||
#
|
#
|
||||||
# when: miner
|
# when: miner
|
||||||
|
|
||||||
|
|
||||||
####### Servers #######
|
####### Servers #######
|
||||||
|
|
||||||
# Easy to deploy server configurations.
|
# Easy to deploy server configurations.
|
||||||
- name: Main | Server Setup
|
- name: Main | Server
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- include_tasks: tasks/server/software/services.yml
|
- name: Main | Server | Services
|
||||||
|
ansible.builtin.include_tasks: tasks/server/software/services.yml
|
||||||
|
|
||||||
- block:
|
- block:
|
||||||
- include_tasks: tasks/server/software/certbot.yml
|
|
||||||
- include_tasks: tasks/server/cron/certbot.yml
|
- name: Main | Server | Certbot
|
||||||
when: certbot
|
ansible.builtin.include_tasks: tasks/server/software/certbot.yml
|
||||||
|
|
||||||
|
- name: Main | Server | Certbot Cron
|
||||||
|
ansible.builtin.include_tasks: tasks/server/cron/certbot.yml
|
||||||
|
when: certbot
|
||||||
|
|
||||||
- block:
|
- block:
|
||||||
- include_tasks: tasks/server/software/onlyoffice.yml
|
|
||||||
|
- name: Main | Server | OnlyOffice
|
||||||
|
ansible.builtin.include_tasks: tasks/server/software/onlyoffice.yml
|
||||||
when: onlyoffice
|
when: onlyoffice
|
||||||
- include_tasks: tasks/server/software/influxdb1.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/server/software/influxdb1.yml
|
||||||
when: influxdb1
|
when: influxdb1
|
||||||
- include_tasks: tasks/server/software/influxdb2.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/server/software/influxdb2.yml
|
||||||
when: influxdb2
|
when: influxdb2
|
||||||
- include_tasks: tasks/server/software/grafana.yml
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/server/software/grafana.yml
|
||||||
when: grafana
|
when: grafana
|
||||||
|
|
||||||
when: ansible_pkg_mgr == "apt"
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
- include_tasks: tasks/server/software/hugo.yml
|
- ansible.builtin.include_tasks: tasks/server/software/hugo.yml
|
||||||
when: hugo
|
when: hugo
|
||||||
|
|
||||||
when: server
|
when: server
|
||||||
|
|
||||||
|
|
||||||
####### Reporting #######
|
####### Reporting #######
|
||||||
|
|
||||||
# Provide information for analysis.
|
# Provide information for analysis.
|
||||||
- name: Main | Reporting
|
- name: Main | Reporting
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- include_tasks: tasks/general/software/telegraf.yml
|
- ansible.builtin.include_tasks: tasks/general/software/telegraf.yml
|
||||||
when: internet
|
when: internet
|
||||||
|
|
||||||
- include_tasks: tasks/general/tests/services.yml
|
- ansible.builtin.include_tasks: tasks/general/tests/services.yml
|
||||||
- include_tasks: tasks/general/tests/lynis.yml
|
|
||||||
- include_tasks: tasks/general/tests/nmap.yml
|
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/tests/lynis.yml
|
||||||
|
|
||||||
####### Finish #######
|
- ansible.builtin.include_tasks: tasks/general/tests/nmap.yml
|
||||||
- name: Main | Finish
|
|
||||||
block:
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/acct_mgmt/notify.yml
|
####### Footer #######
|
||||||
vars:
|
|
||||||
notify_message: "Provisioning Finished"
|
|
||||||
|
|
||||||
- include_tasks: tasks/general/tests/lock_remove.yml
|
- name: Main | Footer
|
||||||
|
ansible.builtin.include_tasks: tasks/footer.yml
|
||||||
@@ -6,6 +6,7 @@
|
|||||||
DIR="$(dirname -- "${BASH_SOURCE[0]}")"
|
DIR="$(dirname -- "${BASH_SOURCE[0]}")"
|
||||||
PROG="$(basename -- "${BASH_SOURCE[0]}")"
|
PROG="$(basename -- "${BASH_SOURCE[0]}")"
|
||||||
LOCAL="$DIR/local.yml"
|
LOCAL="$DIR/local.yml"
|
||||||
|
TEST="$DIR/test.yml"
|
||||||
URL="https://git.hyperling.com/me/env-ansible"
|
URL="https://git.hyperling.com/me/env-ansible"
|
||||||
if [[ -z $BRANCH ]]; then
|
if [[ -z $BRANCH ]]; then
|
||||||
export BRANCH="main"
|
export BRANCH="main"
|
||||||
@@ -31,7 +32,7 @@ branch=""
|
|||||||
function usage {
|
function usage {
|
||||||
cat <<- EOF
|
cat <<- EOF
|
||||||
|
|
||||||
$PROG [-l] [-b branch_name] [-g] [-w] [-s] [-f] [-h]
|
$PROG [-l | -t] [-b branch_name] [-g] [-w] [-s] [-f] [-h]
|
||||||
Program to initialize synchronization with Hyperling's Ansible configuration.
|
Program to initialize synchronization with Hyperling's Ansible configuration.
|
||||||
$URL
|
$URL
|
||||||
|
|
||||||
@@ -39,6 +40,7 @@ function usage {
|
|||||||
-l : Run the local playbook associated with this $PROG.
|
-l : Run the local playbook associated with this $PROG.
|
||||||
This is helpful for development or just saving bandwidth.
|
This is helpful for development or just saving bandwidth.
|
||||||
It also provides prettier colors than the plaintext from ansible-pull. ;)
|
It also provides prettier colors than the plaintext from ansible-pull. ;)
|
||||||
|
-t : Run the test playbook which has a much smaller set of includes.
|
||||||
-b branch_name : Download and run a specific branch. Default is $BRANCH.
|
-b branch_name : Download and run a specific branch. Default is $BRANCH.
|
||||||
-g : Enable the General config with test contents.
|
-g : Enable the General config with test contents.
|
||||||
-w : Enable the Workstation config with test contents.
|
-w : Enable the Workstation config with test contents.
|
||||||
@@ -52,9 +54,10 @@ function usage {
|
|||||||
|
|
||||||
## Parameter Parsing ##
|
## Parameter Parsing ##
|
||||||
|
|
||||||
while getopts ":lb:gwsfh" arg; do
|
while getopts ":ltb:gwsfh" arg; do
|
||||||
case $arg in
|
case $arg in
|
||||||
l) local="Y" && echo "Running $LOCAL as the playbook." ;;
|
l) local="Y" && echo "Running $LOCAL as the playbook." ;;
|
||||||
|
t) test="Y" && echo "Running $TEST as the playbook." ;;
|
||||||
b) branch="$OPTARG" && echo "Using branch $branch instead of $BRANCH." ;;
|
b) branch="$OPTARG" && echo "Using branch $branch instead of $BRANCH." ;;
|
||||||
g) create_general="Y" && echo "Generating test '$general_config'." ;;
|
g) create_general="Y" && echo "Generating test '$general_config'." ;;
|
||||||
w) create_workstation="Y" && echo "Generating test '$workstation_config'." ;;
|
w) create_workstation="Y" && echo "Generating test '$workstation_config'." ;;
|
||||||
@@ -231,12 +234,23 @@ fi
|
|||||||
echo " "
|
echo " "
|
||||||
|
|
||||||
echo "Provisioning Ansible..."
|
echo "Provisioning Ansible..."
|
||||||
if [[ "$local" == "Y" ]]; then
|
status=""
|
||||||
|
if [[ "$test" == "Y" ]]; then
|
||||||
|
sudo ansible-playbook $TEST
|
||||||
|
status=$?
|
||||||
|
elif [[ "$local" == "Y" ]]; then
|
||||||
sudo ansible-playbook $LOCAL
|
sudo ansible-playbook $LOCAL
|
||||||
|
status=$?
|
||||||
else
|
else
|
||||||
sudo ansible-pull -U $URL.git --checkout $branch
|
sudo ansible-pull -U $URL.git --checkout $branch
|
||||||
|
status=$?
|
||||||
|
fi
|
||||||
|
if [[ "$status" == 0 ]]; then
|
||||||
|
echo -e "- Provisioned!\n"
|
||||||
|
else
|
||||||
|
echo -e "\nERROR: Playbook failed with status $status, exiting."
|
||||||
|
exit $status
|
||||||
fi
|
fi
|
||||||
echo -e "- Provisioned!\n"
|
|
||||||
|
|
||||||
echo "Mounting all drives..."
|
echo "Mounting all drives..."
|
||||||
mount -a
|
mount -a
|
||||||
|
|||||||
@@ -0,0 +1,14 @@
|
|||||||
|
---
|
||||||
|
# All the tasks which need run to successfully end the playbook.
|
||||||
|
|
||||||
|
####### Footer #######
|
||||||
|
- name: Footer
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Footer | Notify
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/notify.yml
|
||||||
|
vars:
|
||||||
|
notify_message: "Provisioning Finished"
|
||||||
|
|
||||||
|
- name: Footer | Lock | Remove
|
||||||
|
ansible.builtin.include_tasks: tasks/general/tests/lock_remove.yml
|
||||||
@@ -25,9 +25,9 @@
|
|||||||
- name: General | Account Management | Provisioning Configuration | General | Create
|
- name: General | Account Management | Provisioning Configuration | General | Create
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
path: "{{ gen_file }}"
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config'
|
||||||
block: |
|
block: |
|
||||||
; Please note that all portions require lowercase keys and values.
|
[global]
|
||||||
;
|
|
||||||
;;;;;;;;;;;;;;;;;;;; Basic Options ;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;; Basic Options ;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; enable : Provide true for the provision to occur.
|
; enable : Provide true for the provision to occur.
|
||||||
@@ -49,6 +49,17 @@
|
|||||||
; nmap is already provided for reporting
|
; nmap is already provided for reporting
|
||||||
; Default: false
|
; Default: false
|
||||||
;
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | General | Create | Git Polling
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config | Git Polling'
|
||||||
|
block: |
|
||||||
;;;;;;;;;;;;;;;;;;;; Git Polling ;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;; Git Polling ;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; For syncing this machine to a Git repository of this Ansible project
|
; For syncing this machine to a Git repository of this Ansible project
|
||||||
@@ -74,6 +85,17 @@
|
|||||||
; Example: Ansible, ansible-setup, my-env
|
; Example: Ansible, ansible-setup, my-env
|
||||||
; Default: env-ansible
|
; Default: env-ansible
|
||||||
;
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | General | Create | Swap File
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config | Swap File'
|
||||||
|
block: |
|
||||||
;;;;;;;;;;;;;;;;;;;; Swap File ;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;; Swap File ;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; swap_block : Set to the block size if dd should create a swapfile.
|
; swap_block : Set to the block size if dd should create a swapfile.
|
||||||
@@ -90,6 +112,17 @@
|
|||||||
; Example: /usr/local/swap
|
; Example: /usr/local/swap
|
||||||
; Default: /swapfile
|
; Default: /swapfile
|
||||||
;
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | General | Create | Sync Frequency
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config | Sync Frequency'
|
||||||
|
block: |
|
||||||
;;;;;;;;;;;;;;;;;;;; Sync Frequency ;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;; Sync Frequency ;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; no_telem : Set to true to avoid setting up telemetry services.
|
; no_telem : Set to true to avoid setting up telemetry services.
|
||||||
@@ -101,6 +134,17 @@
|
|||||||
; Slows down the rate of services such as telegraf and cron.
|
; Slows down the rate of services such as telegraf and cron.
|
||||||
; Default: false
|
; Default: false
|
||||||
;
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | General | Create | Server Shortcuts
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config | Server Shortcuts'
|
||||||
|
block: |
|
||||||
;;;;;;;;;;;;;;;;;;;; Server Shortcuts ;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;; Server Shortcuts ;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; For typing `prod` and getting straight to a server, like in env-termux.
|
; For typing `prod` and getting straight to a server, like in env-termux.
|
||||||
@@ -120,7 +164,18 @@
|
|||||||
; Example: jim, bob, jeff, anne
|
; Example: jim, bob, jeff, anne
|
||||||
; Default: user
|
; Default: user
|
||||||
;
|
;
|
||||||
; For pushing MASTER directories to an SFTP server with `send-master`.
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | General | Create | Sync Shortcuts
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config | Sync Shortcuts'
|
||||||
|
block: |
|
||||||
|
;;;;;;;;;;;;;;;;;;;;; Sync Shortcuts ;;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; Imagine the command:
|
; Imagine the command:
|
||||||
; `rsync -auPhz --delete -e 'ssh -p prod_data_port' ./mydata-MASTER/ \
|
; `rsync -auPhz --delete -e 'ssh -p prod_data_port' ./mydata-MASTER/ \
|
||||||
@@ -143,41 +198,83 @@
|
|||||||
; Example: /srv/sftp/
|
; Example: /srv/sftp/
|
||||||
; Default: /srv/sftp/
|
; Default: /srv/sftp/
|
||||||
;
|
;
|
||||||
[global]
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config'
|
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | General | Create | Tunnel
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ gen_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Generic Config | Tunnel'
|
||||||
|
block: |
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; Tunnel ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
;
|
||||||
|
; Create a runit script which maintains an SSH tunnel to a remote server.
|
||||||
|
;
|
||||||
|
; ssh -v -H -R tunnel_remote_port:localhost:tunnel_local_port \
|
||||||
|
; [-p tunnel_ssh_port] tunnel_remote_host
|
||||||
|
;
|
||||||
|
; tunnel_local_port (default=8080)
|
||||||
|
; Local HTTP port which need forwarded to a remote server.
|
||||||
|
; Example: http://localhost:8080
|
||||||
|
;
|
||||||
|
; tunnel_remote_host (default=false)
|
||||||
|
; Remote server including username (such as user@example.com) which will
|
||||||
|
; serve the port. Server should preferably have a reverse proxy in order
|
||||||
|
; to encrypt the traffic, otherwise the local server should use HTTPS.
|
||||||
|
;
|
||||||
|
; tunnel_remote_port (default=8080)
|
||||||
|
; Port which should host the service on the remote server. This is what
|
||||||
|
; will get typed into web browsers or used by the reverse proxy. Should
|
||||||
|
; be > 1024. Also, /etc/ssh/sshd_config will need AllowTcpForwarding and
|
||||||
|
; GatewayPorts set to yes, then sshd will need to be reloaded.
|
||||||
|
; Example: http://example.com:8080
|
||||||
|
;
|
||||||
|
; tunnel_ssh_port (default=22)
|
||||||
|
; Port which the remote server exposes ssh.
|
||||||
|
; Example: ssh -p 2222 user@example.com
|
||||||
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | General | Load
|
- name: General | Account Management | Provisioning Configuration | General | Load
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
provision: "{{ lookup('ini', 'enable file={{gen_file}} default=false') | bool }}"
|
provision: "{{ lookup('ini', 'enable file={{gen_file}} default=false') | bool }}"
|
||||||
user: "{{ lookup('ini', 'user file={{gen_file}} default=ling') }}"
|
user: "{{ lookup('ini', 'user file={{gen_file}} default=user' ) }}"
|
||||||
user_desc: "{{ lookup('ini', 'user_desc file={{gen_file}} default=Hyperling') }}"
|
user_desc: "{{ lookup('ini', 'user_desc file={{gen_file}} default=User' ) }}"
|
||||||
branch: "{{ lookup('ini', 'branch file={{gen_file}} default=main') }}"
|
branch: "{{ lookup('ini', 'branch file={{gen_file}} default=main' ) }}"
|
||||||
pentesting: "{{ lookup('ini', 'pentesting file={{gen_file}} default=false') | bool }}"
|
pentesting: "{{ lookup('ini', 'pentesting file={{gen_file}} default=false') | bool }}"
|
||||||
no_telem: "{{ lookup('ini', 'no_telem file={{gen_file}} default=false') | bool }}"
|
no_telem: "{{ lookup('ini', 'no_telem file={{gen_file}} default=false') | bool }}"
|
||||||
battery: "{{ lookup('ini', 'battery file={{gen_file}} default=false') | bool }}"
|
battery: "{{ lookup('ini', 'battery file={{gen_file}} default=false') | bool }}"
|
||||||
swap_block: "{{ lookup('ini', 'swap_block file={{gen_file}} default=false') }}"
|
swap_block: "{{ lookup('ini', 'swap_block file={{gen_file}} default=false') }}"
|
||||||
swap_count: "{{ lookup('ini', 'swap_count file={{gen_file}} default=1') }}"
|
swap_count: "{{ lookup('ini', 'swap_count file={{gen_file}} default=1' ) | int }}"
|
||||||
swap_file: "{{ lookup('ini', 'swap_file file={{gen_file}} default=/swapfile') }}"
|
swap_file: "{{ lookup('ini', 'swap_file file={{gen_file}} default=/swapfile') }}"
|
||||||
sshd_port: "{{ lookup('ini', 'sshd_port file={{gen_file}} default=22') }}"
|
sshd_port: "{{ lookup('ini', 'sshd_port file={{gen_file}} default=22' ) | int }}"
|
||||||
git_host: "{{ lookup('ini', 'git_host file={{gen_file}} default=git.hyperling.com') }}"
|
git_host: "{{ lookup('ini', 'git_host file={{gen_file}} default=git.hyperling.com') }}"
|
||||||
git_user: "{{ lookup('ini', 'git_user file={{gen_file}} default=me') }}"
|
git_user: "{{ lookup('ini', 'git_user file={{gen_file}} default=me') }}"
|
||||||
git_project: "{{ lookup('ini', 'git_project file={{gen_file}} default=env-ansible') }}"
|
git_project: "{{ lookup('ini', 'git_project file={{gen_file}} default=env-ansible') }}"
|
||||||
git_ssh_port: "{{ lookup('ini', 'git_ssh_port file={{gen_file}} default=22') }}"
|
git_ssh_port: "{{ lookup('ini', 'git_ssh_port file={{gen_file}} default=22') | int }}"
|
||||||
prod_host: "{{ lookup('ini', 'prod_host file={{gen_file}} default=hyperling.com') }}"
|
prod_host: "{{ lookup('ini', 'prod_host file={{gen_file}} default=hyperling.com') }}"
|
||||||
prod_port: "{{ lookup('ini', 'prod_port file={{gen_file}} default=22') }}"
|
prod_port: "{{ lookup('ini', 'prod_port file={{gen_file}} default=22') | int }}"
|
||||||
prod_user: "{{ lookup('ini', 'prod_user file={{gen_file}} default=user') }}"
|
prod_user: "{{ lookup('ini', 'prod_user file={{gen_file}} default=user') }}"
|
||||||
prod_data_host: "{{ lookup('ini', 'prod_data_host file={{gen_file}} default=hyperling.com') }}"
|
prod_data_host: "{{ lookup('ini', 'prod_data_host file={{gen_file}} default=hyperling.com') }}"
|
||||||
prod_data_port: "{{ lookup('ini', 'prod_data_port file={{gen_file}} default=22') }}"
|
prod_data_port: "{{ lookup('ini', 'prod_data_port file={{gen_file}} default=22') | int }}"
|
||||||
prod_data_user: "{{ lookup('ini', 'prod_data_user file={{gen_file}} default=user') }}"
|
prod_data_user: "{{ lookup('ini', 'prod_data_user file={{gen_file}} default=user') }}"
|
||||||
prod_data_dir: "{{ lookup('ini', 'prod_data_dir file={{gen_file}} default=/srv/sftp') }}"
|
prod_data_dir: "{{ lookup('ini', 'prod_data_dir file={{gen_file}} default=/srv/sftp') }}"
|
||||||
|
tunnel_local_port: "{{ lookup('ini', 'tunnel_local_port file={{gen_file}} default=8080' ) | int }}"
|
||||||
|
tunnel_remote_host: "{{ lookup('ini', 'tunnel_remote_host file={{gen_file}} default=false') }}"
|
||||||
|
tunnel_remote_port: "{{ lookup('ini', 'tunnel_remote_port file={{gen_file}} default=8080' ) | int }}"
|
||||||
|
tunnel_ssh_port: "{{ lookup('ini', 'tunnel_ssh_port file={{gen_file}} default=22' ) | int }}"
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | General | Boolean Check | Swap Block
|
- name: General | Account Management | Provisioning Configuration | General | Boolean Check | swap_block
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
swap_block: "{{ swap_block | bool }}"
|
swap_block: "{{ swap_block | bool }}"
|
||||||
when: swap_block in ("true", "false")
|
when: swap_block in ("false")
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | General | List
|
- name: General | Account Management | Provisioning Configuration | General | List
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
@@ -205,15 +302,21 @@
|
|||||||
- { 'prod_data_port': "{{ prod_data_port }}" }
|
- { 'prod_data_port': "{{ prod_data_port }}" }
|
||||||
- { 'prod_data_user': "{{ prod_data_user }}" }
|
- { 'prod_data_user': "{{ prod_data_user }}" }
|
||||||
- { 'prod_data_dir': "{{ prod_data_dir }}" }
|
- { 'prod_data_dir': "{{ prod_data_dir }}" }
|
||||||
|
- { 'tunnel_local_port': "{{ tunnel_local_port }}" }
|
||||||
|
- { 'tunnel_remote_host': "{{ tunnel_remote_host }}" }
|
||||||
|
- { 'tunnel_remote_port': "{{ tunnel_remote_port }}" }
|
||||||
|
- { 'tunnel_ssh_port': "{{ tunnel_ssh_port }}" }
|
||||||
|
|
||||||
|
|
||||||
## Workstation ##
|
## Workstation ##
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | Workstation | Create
|
- name: General | Account Management | Provisioning Configuration | Workstation | Create | Main Options
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
path: "{{ wrk_file }}"
|
path: "{{ wrk_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Workstation Config'
|
||||||
block: |
|
block: |
|
||||||
;;;;;;; Available options - all require lowercase values ;;;;;;
|
[global]
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;; Main Options ;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
;
|
;
|
||||||
; enable : Set to true for system to be considered a workstation.
|
; enable : Set to true for system to be considered a workstation.
|
||||||
;
|
;
|
||||||
@@ -228,6 +331,114 @@
|
|||||||
;
|
;
|
||||||
; gaming : Set to true for installation of gaming software (Steam, Lutris)
|
; gaming : Set to true for installation of gaming software (Steam, Lutris)
|
||||||
;
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | Workstation | Create | LLMs
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ wrk_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Workstation Config | LLMs'
|
||||||
|
block: |
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; LLMs ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
;
|
||||||
|
; ollama (default=true)
|
||||||
|
; Install and enable the ollama LLM manager.
|
||||||
|
; API: http://127.0.0.1:11434
|
||||||
|
;
|
||||||
|
; manage_models (default=true)
|
||||||
|
; Automatically choose and pull the models to use based on system
|
||||||
|
; resources. Otherwise leaves images alone but still handles config.
|
||||||
|
;
|
||||||
|
; hf_token (default=false)
|
||||||
|
; Token from Hugging Face which allows faster download speeds than anon.
|
||||||
|
; May help with ollama and also supposed to help with open-webui. Token
|
||||||
|
; needs set to something like hf_kjBCCLABEEABUVAKbjadbvkaksvBAVKBkjsDVK.
|
||||||
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | Workstation | Create | LLMs | GUIs
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ wrk_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Workstation Config | LLMs | GUIs'
|
||||||
|
block: |
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; LLMs: GUIs ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
;
|
||||||
|
; zeroclaw (default=true)
|
||||||
|
; Install and enable the Zeroclaw web daemon, a minimalistic interface
|
||||||
|
; for many models and providers with negligible resource usage. Also
|
||||||
|
; installs the CLI tool zerocode as an alternative to the web GUI.
|
||||||
|
; URL: http://127.0.0.1:42617
|
||||||
|
;
|
||||||
|
; open_webui (default=false)
|
||||||
|
; Install and enable open-webui as a Docker container. Very polished web
|
||||||
|
; frontend for ollama and also handles other web LLMs through API calls.
|
||||||
|
; Container is over 1GB in size and consumes substantial resources!
|
||||||
|
; URL: http://localhost:3000
|
||||||
|
;
|
||||||
|
; open_webui_port (default=3000)
|
||||||
|
; Port on which to run the open-webui Docker instance.
|
||||||
|
;
|
||||||
|
; open_webui_key (default=PleaseEnsureTheKeyIsAtLeast32To64Characters)
|
||||||
|
; Secret key, allows persistence between runs. If not a public-facing
|
||||||
|
; system, then not critical. Use `openssl rand -hex 32` to create one.
|
||||||
|
;
|
||||||
|
; codium_config (default=true)
|
||||||
|
; Manage the config files for and Codium plugins. Cline and Continue are
|
||||||
|
; the recommended Codium extensions but need installed through the GUI.
|
||||||
|
; Currently handles:
|
||||||
|
; ~/.continue/config.yml
|
||||||
|
;
|
||||||
|
; qwen_code (default=true)
|
||||||
|
; Install and enable qwen-code as a daemon.
|
||||||
|
; URL: http://127.0.0.1:4170
|
||||||
|
;
|
||||||
|
; qwen_code_key (default='')
|
||||||
|
; API key for accessing the web GUI. Optional, not used if left blank.
|
||||||
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | Workstation | Create | LLMs | MCPs
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ wrk_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Workstation Config | LLMs | MCPs'
|
||||||
|
block: |
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;; LLMs: MCPs / Sandboxes ;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
;
|
||||||
|
; open_terminal (default=false)
|
||||||
|
; Docker container to be used with GUIs like open-webui so that agents
|
||||||
|
; have somewhere safe to execute commands. Also allows file read/writes.
|
||||||
|
; URL: http://127.0.0.1:8000
|
||||||
|
;
|
||||||
|
; open_terminal_port (default=8000)
|
||||||
|
; Port on which to run the open-terminal Docker instance.
|
||||||
|
;
|
||||||
|
; open_terminal_key (default=open-terminal-key)
|
||||||
|
; API key, needed in order to access the server. Required.
|
||||||
|
;
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | Workstation | Create | Other Options
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ wrk_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Workstation Config | Other Options'
|
||||||
|
block: |
|
||||||
|
;;;;;;;;;;;;;;;;;;;;;;;;;; Other Options ;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
|
;
|
||||||
; rdp : Set to true for installation of RDP protocol
|
; rdp : Set to true for installation of RDP protocol
|
||||||
; CURRENTLY FREEBSD-ONLY
|
; CURRENTLY FREEBSD-ONLY
|
||||||
;
|
;
|
||||||
@@ -243,30 +454,58 @@
|
|||||||
; redmode : Set to true/false for automatially using Night Light in GNOME.
|
; redmode : Set to true/false for automatially using Night Light in GNOME.
|
||||||
; Default: true
|
; Default: true
|
||||||
;
|
;
|
||||||
[global]
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
marker: '; {mark} MANAGED BY ANSIBLE | Workstation Config'
|
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | Workstation | Load
|
- name: General | Account Management | Provisioning Configuration | Workstation | Load
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
|
# Main
|
||||||
workstation: "{{ lookup('ini', 'enable file={{wrk_file}} default=false') | bool }}"
|
workstation: "{{ lookup('ini', 'enable file={{wrk_file}} default=false') | bool }}"
|
||||||
coding: "{{ lookup('ini', 'coding file={{wrk_file}} default=false') | bool }}"
|
coding: "{{ lookup('ini', 'coding file={{wrk_file}} default=false') | bool }}"
|
||||||
sdks: "{{ lookup('ini', 'sdks file={{wrk_file}} default=false') | bool }}"
|
sdks: "{{ lookup('ini', 'sdks file={{wrk_file}} default=false') | bool }}"
|
||||||
editing: "{{ lookup('ini', 'editing file={{wrk_file}} default=false') }}"
|
editing: "{{ lookup('ini', 'editing file={{wrk_file}} default=false') }}"
|
||||||
gaming: "{{ lookup('ini', 'gaming file={{wrk_file}} default=false') | bool }}"
|
gaming: "{{ lookup('ini', 'gaming file={{wrk_file}} default=false') | bool }}"
|
||||||
rdp: "{{ lookup('ini', 'rdp file={{wrk_file}} default=false') | bool }}"
|
# Other
|
||||||
vnc: "{{ lookup('ini', 'vnc file={{wrk_file}} default=false') | bool }}"
|
rdp: "{{ lookup('ini', 'rdp file={{wrk_file}} default=false') | bool }}"
|
||||||
bsd_gpu: "{{ lookup('ini', 'bsd_gpu file={{wrk_file}} default=false') | bool }}"
|
vnc: "{{ lookup('ini', 'vnc file={{wrk_file}} default=false') | bool }}"
|
||||||
mobile: "{{ lookup('ini', 'mobile file={{wrk_file}} default=false') | bool }}"
|
bsd_gpu: "{{ lookup('ini', 'bsd_gpu file={{wrk_file}} default=false') | bool }}"
|
||||||
redmode: "{{ lookup('ini', 'redmode file={{wrk_file}} default=true' ) | bool }}"
|
mobile: "{{ lookup('ini', 'mobile file={{wrk_file}} default=false') | bool }}"
|
||||||
|
redmode: "{{ lookup('ini', 'redmode file={{wrk_file}} default=true' ) | bool }}"
|
||||||
|
# LLMs
|
||||||
|
ollama_enabled: "{{ lookup('ini', 'ollama file={{wrk_file}} default=true' ) | bool }}"
|
||||||
|
manage_models: "{{ lookup('ini', 'manage_models file={{wrk_file}} default=true' ) | bool }}"
|
||||||
|
hf_token: "{{ lookup('ini', 'hf_token file={{wrk_file}} default=false') }}"
|
||||||
|
# LLM GUIs
|
||||||
|
zeroclaw_enabled: "{{ lookup('ini', 'zeroclaw file={{wrk_file}} default=true ') | bool }}"
|
||||||
|
open_webui_enabled: "{{ lookup('ini', 'open_webui file={{wrk_file}} default=false') | bool }}"
|
||||||
|
open_webui_port: "{{ lookup('ini', 'open_webui_port file={{wrk_file}} default=3000' ) | int }}"
|
||||||
|
open_webui_key: "{{ lookup('ini', 'open_webui_key file={{wrk_file}} default=PleaseEnsureTheKeyIsAtLeast32To64Characters') }}"
|
||||||
|
codium_config: "{{ lookup('ini', 'codium_config file={{wrk_file}} default=true' ) | bool }}"
|
||||||
|
qwen_code_enabled: "{{ lookup('ini', 'qwen_code file={{wrk_file}} default=true' ) | bool }}"
|
||||||
|
qwen_code_key : "{{ lookup('ini', 'qwen_code_key file={{wrk_file}} default=false') }}"
|
||||||
|
# LLM MCPs
|
||||||
|
open_terminal_enabled: "{{ lookup('ini', 'open_terminal file={{wrk_file}} default=false') | bool }}"
|
||||||
|
open_terminal_port: "{{ lookup('ini', 'open_terminal_port file={{wrk_file}} default=8000' ) | int }}"
|
||||||
|
open_terminal_key: "{{ lookup('ini', 'open_terminal_key file={{wrk_file}} default=false') }}"
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | Workstation | Boolean Check | Editing
|
- name: General | Account Management | Provisioning Configuration | Workstation | Boolean Check | editing
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
editing: "{{ editing | bool }}"
|
editing: "{{ editing | bool }}"
|
||||||
when: editing in ("true", "false")
|
when: editing in ("true", "false")
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | Workstation | Boolean Check | qwen_code_key
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
qwen_code_key: "{{ qwen_code_key | bool }}"
|
||||||
|
when: qwen_code_key in ("false")
|
||||||
|
|
||||||
|
- name: General | Account Management | Provisioning Configuration | Workstation | Boolean Check | open_terminal_key
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
open_terminal_key: "{{ open_terminal_key | bool }}"
|
||||||
|
when: open_terminal_key in ("false")
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | Workstation | List
|
- name: General | Account Management | Provisioning Configuration | Workstation | List
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
provision_variables: "{{ provision_variables | combine(item) }}"
|
provision_variables: "{{ provision_variables | combine(item) }}"
|
||||||
@@ -281,6 +520,19 @@
|
|||||||
- { 'bsd_gpu': "{{ bsd_gpu }}" }
|
- { 'bsd_gpu': "{{ bsd_gpu }}" }
|
||||||
- { 'mobile': "{{ mobile }}" }
|
- { 'mobile': "{{ mobile }}" }
|
||||||
- { 'redmode': "{{ redmode }}" }
|
- { 'redmode': "{{ redmode }}" }
|
||||||
|
- { 'ollama_enabled': "{{ ollama_enabled }}" }
|
||||||
|
- { 'manage_models': "{{ manage_models }}" }
|
||||||
|
- { 'hf_token': "{{ hf_token }}" }
|
||||||
|
- { 'zeroclaw_enabled': "{{ zeroclaw_enabled }}" }
|
||||||
|
- { 'open_webui_enabled': "{{ open_webui_enabled }}" }
|
||||||
|
- { 'open_webui_port': "{{ open_webui_port }}" }
|
||||||
|
- { 'open_webui_key': "{{ open_webui_key }}" }
|
||||||
|
- { 'codium_config': "{{ codium_config }}" }
|
||||||
|
- { 'qwen_code_enabled': "{{ qwen_code_enabled }}" }
|
||||||
|
- { 'qwen_code_key': "{{ qwen_code_key }}" }
|
||||||
|
- { 'open_terminal_enabled': "{{ open_terminal_enabled }}" }
|
||||||
|
- { 'open_terminal_port': "{{ open_terminal_port }}" }
|
||||||
|
- { 'open_terminal_key': "{{ open_terminal_key }}" }
|
||||||
|
|
||||||
# No longer mining, this is now considered deprecated.
|
# No longer mining, this is now considered deprecated.
|
||||||
### Miner ##
|
### Miner ##
|
||||||
@@ -289,6 +541,7 @@
|
|||||||
# ansible.builtin.blockinfile:
|
# ansible.builtin.blockinfile:
|
||||||
# path: "{{ mnr_file }}"
|
# path: "{{ mnr_file }}"
|
||||||
# block: |
|
# block: |
|
||||||
|
# [global]
|
||||||
# ;;;;;;; Available options - all require lowercase values ;;;;;;
|
# ;;;;;;; Available options - all require lowercase values ;;;;;;
|
||||||
# ;
|
# ;
|
||||||
# ; enable : Set to true for system to be considered a miner.
|
# ; enable : Set to true for system to be considered a miner.
|
||||||
@@ -324,11 +577,12 @@
|
|||||||
# ; xmr_stak_cpu : Set to true for istallation
|
# ; xmr_stak_cpu : Set to true for istallation
|
||||||
# ; UNFINISHED/UNTESTED
|
# ; UNFINISHED/UNTESTED
|
||||||
# ;
|
# ;
|
||||||
# [global]
|
# ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
# marker: '; {mark} MANAGED BY ANSIBLE | Miner Config'
|
# marker: '; {mark} MANAGED BY ANSIBLE | Miner Config'
|
||||||
# state: present
|
# state: present
|
||||||
# create: true
|
# create: true
|
||||||
# backup: true
|
# backup: true
|
||||||
|
# mode: "0644"
|
||||||
#
|
#
|
||||||
#- name: General | Account Management | Provisioning Configuration | Miner | Load
|
#- name: General | Account Management | Provisioning Configuration | Miner | Load
|
||||||
# ansible.builtin.set_fact:
|
# ansible.builtin.set_fact:
|
||||||
@@ -368,7 +622,9 @@
|
|||||||
- name: General | Account Management | Provisioning Configuration | Server | Create
|
- name: General | Account Management | Provisioning Configuration | Server | Create
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
path: "{{ srv_file }}"
|
path: "{{ srv_file }}"
|
||||||
|
marker: '; {mark} MANAGED BY ANSIBLE | Server Config'
|
||||||
block: |
|
block: |
|
||||||
|
[global]
|
||||||
;;;;;;; Parameters ;;;;;;
|
;;;;;;; Parameters ;;;;;;
|
||||||
;
|
;
|
||||||
; enable : Set to true for system to be considered a server.
|
; enable : Set to true for system to be considered a server.
|
||||||
@@ -393,11 +649,10 @@
|
|||||||
; hugo : Set to true to install HUGO static website generator.
|
; hugo : Set to true to install HUGO static website generator.
|
||||||
;
|
;
|
||||||
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
|
||||||
[global]
|
|
||||||
marker: '; {mark} MANAGED BY ANSIBLE | Server Config'
|
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
|
|
||||||
- name: General | Account Management | Provisioning Configuration | Server | Load
|
- name: General | Account Management | Provisioning Configuration | Server | Load
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
|
|||||||
@@ -40,7 +40,7 @@
|
|||||||
- name: General | Account Management | Users | Root
|
- name: General | Account Management | Users | Root
|
||||||
ansible.builtin.user:
|
ansible.builtin.user:
|
||||||
name: root
|
name: root
|
||||||
ansible.builtin.shell: "{{ bash_exec.stdout }}"
|
shell: "{{ bash_exec.stdout }}"
|
||||||
create_home: true
|
create_home: true
|
||||||
generate_ssh_key: true
|
generate_ssh_key: true
|
||||||
register: user_root
|
register: user_root
|
||||||
@@ -124,9 +124,14 @@
|
|||||||
when: user_user.home != "" and coding
|
when: user_user.home != "" and coding
|
||||||
|
|
||||||
- name: General | Account Management | Users | Home Permissions
|
- name: General | Account Management | Users | Home Permissions
|
||||||
ansible.builtin.shell: "chmod 700 {{ user_user.home }}/../*"
|
ansible.builtin.shell: "{{ item }}"
|
||||||
register: shell_check
|
register: shell_check
|
||||||
changed_when: shell_check.rc == 0
|
changed_when: shell_check.rc == 0
|
||||||
|
loop:
|
||||||
|
- "chmod 700 {{ user_user.home }}/../*"
|
||||||
|
- "chown {{ user }}:{{ user }} {{ user_user.home }}"
|
||||||
|
- "chown {{ user }}:{{ user }} {{ user_user.home }}/*"
|
||||||
|
- "chown {{ user }}:{{ user }} {{ user_user.home }}/.*"
|
||||||
|
|
||||||
|
|
||||||
## Files ##
|
## Files ##
|
||||||
@@ -1139,9 +1144,19 @@
|
|||||||
}
|
}
|
||||||
function_loop: |
|
function_loop: |
|
||||||
function loop() {
|
function loop() {
|
||||||
cmd="$1"
|
cmd="$@"
|
||||||
|
sleep=""
|
||||||
|
sleep_time=5
|
||||||
|
if [[ "$cmd" != *"sleep"* ]]; then
|
||||||
|
sleep='echo -e "`date` - Sleeping for $sleep_time... \n"; sleep $sleep_time'
|
||||||
|
fi
|
||||||
|
count=0
|
||||||
|
echo "Command='$cmd'"
|
||||||
while true; do
|
while true; do
|
||||||
$cmd
|
(( count++ ))
|
||||||
|
echo "`date` - Loop $count"
|
||||||
|
eval $cmd
|
||||||
|
eval $sleep
|
||||||
done;
|
done;
|
||||||
}
|
}
|
||||||
alias try="loop "
|
alias try="loop "
|
||||||
@@ -1226,7 +1241,18 @@
|
|||||||
mv -v ~/.var/app/com.google.AndroidStudio ~/TRASH/com.google.AndroidStudio-`date +"%Y%m%d"`
|
mv -v ~/.var/app/com.google.AndroidStudio ~/TRASH/com.google.AndroidStudio-`date +"%Y%m%d"`
|
||||||
}
|
}
|
||||||
alias reset-android-studio="reset_android_studio "
|
alias reset-android-studio="reset_android_studio "
|
||||||
|
function_follow: |
|
||||||
|
function follow() {
|
||||||
|
tail -n +1 -F "$@"
|
||||||
|
}
|
||||||
|
alias chase="follow "
|
||||||
|
function_restart: |
|
||||||
|
function restart() {
|
||||||
|
prog="$1"
|
||||||
|
sudo sv restart $prog
|
||||||
|
tail -n 0 -F /var/log/$prog/current
|
||||||
|
}
|
||||||
|
alias reload="restart "
|
||||||
|
|
||||||
- name: General | Account Management | Users | Files | Common Variable
|
- name: General | Account Management | Users | Files | Common Variable
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
@@ -1317,6 +1343,8 @@
|
|||||||
{{ process_notify_log }}
|
{{ process_notify_log }}
|
||||||
{{ function_reconnect }}
|
{{ function_reconnect }}
|
||||||
{{ function_reset_android_studio }}
|
{{ function_reset_android_studio }}
|
||||||
|
{{ function_follow }}
|
||||||
|
{{ function_restart }}
|
||||||
|
|
||||||
- name: General | Account Management | Users | Files | .profile + .xsessionrc
|
- name: General | Account Management | Users | Files | .profile + .xsessionrc
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
@@ -1379,6 +1407,7 @@
|
|||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "{{ user_user.home }}/{{ item }}"
|
path: "{{ user_user.home }}/{{ item }}"
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
|
group: "{{ user }}"
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
loop:
|
loop:
|
||||||
- .bashrc
|
- .bashrc
|
||||||
|
|||||||
File renamed without changes.
@@ -8,7 +8,7 @@
|
|||||||
mode: '0755'
|
mode: '0755'
|
||||||
|
|
||||||
- name: General | Scripts | Install | Copy Files
|
- name: General | Scripts | Install | Copy Files
|
||||||
copy:
|
ansible.builtin.copy:
|
||||||
src: 'scripts/'
|
src: 'scripts/'
|
||||||
dest: "{{ global_bin }}/"
|
dest: "{{ global_bin }}/"
|
||||||
owner: root
|
owner: root
|
||||||
@@ -20,6 +20,8 @@
|
|||||||
if [[ -e {{ global_bin }}/{{ item }} ]]; then
|
if [[ -e {{ global_bin }}/{{ item }} ]]; then
|
||||||
rm -v {{ global_bin }}/{{ item }}
|
rm -v {{ global_bin }}/{{ item }}
|
||||||
fi
|
fi
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
loop:
|
loop:
|
||||||
- compress-video.sh
|
- compress-video.sh
|
||||||
- compress-images.sh
|
- compress-images.sh
|
||||||
|
|||||||
@@ -12,13 +12,8 @@
|
|||||||
marker_end: "exit 0"
|
marker_end: "exit 0"
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
|
|
||||||
- name: General | Scripts | Root | scm.sh Permissions
|
|
||||||
ansible.builtin.file:
|
|
||||||
path: "{{ user_root.home }}/bin/scm.sh"
|
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
|
|
||||||
|
|
||||||
- name: General | Scripts | Root | scm-dev.sh
|
- name: General | Scripts | Root | scm-dev.sh
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
path: "{{ user_root.home }}/bin/scm-dev.sh"
|
path: "{{ user_root.home }}/bin/scm-dev.sh"
|
||||||
@@ -42,8 +37,4 @@
|
|||||||
marker_end: "exit 0"
|
marker_end: "exit 0"
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
|
|
||||||
- name: General | Scripts | Root | scm-dev.sh Permissions
|
|
||||||
ansible.builtin.file:
|
|
||||||
path: "{{ user_root.home }}/bin/scm-dev.sh"
|
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
@@ -35,10 +35,11 @@
|
|||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
loop:
|
loop:
|
||||||
- { "key": '^[\#]?AllowUsers', "value": 'AllowUsers {{ user }}'}
|
- { "key": '^[\#]?AllowUsers', "value": 'AllowUsers {{ user }}'}
|
||||||
- { "key": '^[\#]?PermitRootLogin', "value": 'PermitRootLogin no'}
|
- { "key": '^[\#]?PermitRootLogin', "value": 'PermitRootLogin no'}
|
||||||
- { "key": '^[\#]?AllowTcpForwarding', "value": 'AllowTcpForwarding no'}
|
- { "key": '^[\#]?AllowTcpForwarding', "value": 'AllowTcpForwarding yes'}
|
||||||
- { "key": '^[\#]?ClientAliveInterval', "value": 'ClientAliveInterval 60'}
|
- { "key": '^[\#]?ClientAliveInterval', "value": 'ClientAliveInterval 60'}
|
||||||
- { "key": '^[\#]?ClientAliveCountMax', "value": 'ClientAliveCountMax 2'}
|
- { "key": '^[\#]?ClientAliveCountMax', "value": 'ClientAliveCountMax 2'}
|
||||||
- { "key": '^[\#]?Compression', "value": 'Compression no'}
|
- { "key": '^[\#]?Compression', "value": 'Compression no'}
|
||||||
@@ -50,6 +51,7 @@
|
|||||||
- { "key": '^[\#]?X11Forwarding', "value": 'X11Forwarding no'}
|
- { "key": '^[\#]?X11Forwarding', "value": 'X11Forwarding no'}
|
||||||
- { "key": '^[\#]?AllowAgentForwarding', "value": 'AllowAgentForwarding no'}
|
- { "key": '^[\#]?AllowAgentForwarding', "value": 'AllowAgentForwarding no'}
|
||||||
- { "key": '^[\#]?PermitEmptyPasswords', "value": 'PermitEmptyPasswords no'}
|
- { "key": '^[\#]?PermitEmptyPasswords', "value": 'PermitEmptyPasswords no'}
|
||||||
|
- { "key": '^[\#]?GatewayPorts', "value": 'GatewayPorts yes'}
|
||||||
|
|
||||||
- name: General | Software | Services | SSHD | Configure (PVE)
|
- name: General | Software | Services | SSHD | Configure (PVE)
|
||||||
ansible.builtin.lineinfile:
|
ansible.builtin.lineinfile:
|
||||||
@@ -59,6 +61,7 @@
|
|||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0644"
|
||||||
loop:
|
loop:
|
||||||
- { "key": '^[\#]?AllowUsers', "value": 'AllowUsers root {{ user }}'}
|
- { "key": '^[\#]?AllowUsers', "value": 'AllowUsers root {{ user }}'}
|
||||||
- { "key": '^[\#]?PermitRootLogin', "value": 'PermitRootLogin yes'}
|
- { "key": '^[\#]?PermitRootLogin', "value": 'PermitRootLogin yes'}
|
||||||
File renamed without changes.
@@ -0,0 +1,110 @@
|
|||||||
|
---
|
||||||
|
# 2026-10-17 Hyperling
|
||||||
|
# Allow pushing a local port to a remote server automagically in a runit script.
|
||||||
|
|
||||||
|
# ssh -N -p SSH_PORT -R REMOTE_PORT:localhost:LOCAL_PORT USER@REMOTE_HOST -v
|
||||||
|
|
||||||
|
- name: General | Tunnel | Provisioned Variables
|
||||||
|
ansible.builtin.debug:
|
||||||
|
var: "{{ item }}"
|
||||||
|
loop:
|
||||||
|
- tunnel_local_port
|
||||||
|
- tunnel_remote_host
|
||||||
|
- tunnel_remote_port
|
||||||
|
- tunnel_ssh_port
|
||||||
|
|
||||||
|
- name: General | Tunnel | Facts
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
tunnel_service_name: tunnel
|
||||||
|
|
||||||
|
- name: General | Tunnel | Packages [pacman]
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- openbsd-netcat
|
||||||
|
state: present
|
||||||
|
when: ansible_pkg_mgr == "pacman"
|
||||||
|
|
||||||
|
- name: General | Tunnel | Packages [apt]
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- netcat-openbsd
|
||||||
|
state: present
|
||||||
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | mkdir | /etc/sv
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: /etc/sv/{{ tunnel_service_name }}
|
||||||
|
state: directory
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | mkdir | /etc/sv log
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: /etc/sv/{{ tunnel_service_name }}/log
|
||||||
|
state: directory
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | mkdir | /var/log
|
||||||
|
ansible.builtin.file:
|
||||||
|
path: /var/log/{{ tunnel_service_name }}
|
||||||
|
state: directory
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | Script | Run
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/sv/{{ tunnel_service_name }}/run
|
||||||
|
content: |
|
||||||
|
#!/bin/sh -e
|
||||||
|
exec 2>&1
|
||||||
|
|
||||||
|
# Health check to ensure connection does not go stale.
|
||||||
|
while true; do
|
||||||
|
sleep 300
|
||||||
|
echo -n "RUN-LOOP: "
|
||||||
|
nc -zv {{ tunnel_remote_host }} {{ tunnel_remote_port }}
|
||||||
|
status="$?"
|
||||||
|
echo "RUN-LOOP: Port check returned ${status}."
|
||||||
|
if [[ "$status" != 0 ]]; then
|
||||||
|
echo "RUN-LOOP: Restarting service."
|
||||||
|
sv restart {{ tunnel_service_name }}
|
||||||
|
fi
|
||||||
|
echo "RUN-LOOP: Going back to sleep."
|
||||||
|
done &
|
||||||
|
|
||||||
|
# Do not use `exec` here otherwise the loop may get killed.
|
||||||
|
chpst -u {{ user }} ssh -v -N \
|
||||||
|
-R {{ tunnel_remote_port }}:localhost:{{ tunnel_local_port }} \
|
||||||
|
-p {{ tunnel_ssh_port }} {{ tunnel_remote_host }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | Script | Finish
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/sv/{{ tunnel_service_name }}/finish
|
||||||
|
content: |
|
||||||
|
{{ runit_finish_sleep }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | Script | Log
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/sv/{{ tunnel_service_name }}/log/run
|
||||||
|
content: |
|
||||||
|
#!/bin/sh -e
|
||||||
|
exec svlogd -tt /var/log/{{ tunnel_service_name }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | Script | Log Config
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /var/log/{{ tunnel_service_name }}/config
|
||||||
|
content: |
|
||||||
|
{{ runit_log_config_10mb }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: General | Tunnel | runit | Service | Enable
|
||||||
|
ansible.builtin.service:
|
||||||
|
name: "{{ tunnel_service_name }}"
|
||||||
|
state: "{{ 'started' if tunnel_remote_host else 'stopped' }}"
|
||||||
|
enabled: "{{ true if tunnel_remote_host else false }}"
|
||||||
|
|
||||||
|
when: ansible_service_mgr == "runit"
|
||||||
@@ -68,6 +68,8 @@
|
|||||||
- "{{ alsa }}"
|
- "{{ alsa }}"
|
||||||
- "{{ stress }}"
|
- "{{ stress }}"
|
||||||
- "{{ jq }}"
|
- "{{ jq }}"
|
||||||
|
- "{{ btop }}"
|
||||||
|
- "{{ xkb }}"
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
- name: General | Software | Packages | Install Software (DEV)
|
- name: General | Software | Packages | Install Software (DEV)
|
||||||
@@ -126,14 +128,6 @@
|
|||||||
state: present
|
state: present
|
||||||
when: ansible_pkg_mgr in ("zypper")
|
when: ansible_pkg_mgr in ("zypper")
|
||||||
|
|
||||||
- name: General | Software | Packages | Update Software (Disabled)
|
|
||||||
ansible.builtin.package:
|
|
||||||
name:
|
|
||||||
- ansible
|
|
||||||
- git
|
|
||||||
state: latest
|
|
||||||
when: 1 == 0
|
|
||||||
|
|
||||||
- name: General | Software | Packages | Remove Software
|
- name: General | Software | Packages | Remove Software
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
|
|||||||
@@ -0,0 +1,23 @@
|
|||||||
|
---
|
||||||
|
# 20261006 Hyperling
|
||||||
|
|
||||||
|
# Allow ansible.builtin.service to be used on Artix similar to Devuan.
|
||||||
|
- name: General | Software | runit | Fix Artix
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: General | Software | runit | Fix Artix | Script Dir
|
||||||
|
ansible.builtin.file:
|
||||||
|
src: /etc/runit/sv
|
||||||
|
dest: /etc/sv
|
||||||
|
state: link
|
||||||
|
force: true
|
||||||
|
|
||||||
|
- name: General | Software | runit | Fix Artix | Service Dir
|
||||||
|
ansible.builtin.file:
|
||||||
|
src: /etc/runit/runsvdir/default
|
||||||
|
dest: /var/service
|
||||||
|
state: link
|
||||||
|
force: true
|
||||||
|
|
||||||
|
when: ansible_service_mgr == "runit"
|
||||||
|
and ansible_pkg_mgr == "pacman"
|
||||||
@@ -0,0 +1,179 @@
|
|||||||
|
---
|
||||||
|
|
||||||
|
####### Lock #######
|
||||||
|
|
||||||
|
# Ensure a process is not already running.
|
||||||
|
- name: Main | Lock
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Main | Lock | Check
|
||||||
|
ansible.builtin.include_tasks: tasks/general/tests/lock_check.yml
|
||||||
|
|
||||||
|
- name: Main | Lock | Create
|
||||||
|
ansible.builtin.include_tasks: tasks/general/tests/lock_create.yml
|
||||||
|
|
||||||
|
####### Gather #######
|
||||||
|
|
||||||
|
# Load facts for all systems.
|
||||||
|
- name: Main | Gather
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Main | Gather | Facts
|
||||||
|
ansible.builtin.include_tasks: facts/general/gather.yml
|
||||||
|
|
||||||
|
- name: Main | Gather | Account Management
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/provision_config.yml
|
||||||
|
|
||||||
|
- name: Main | Gather | System
|
||||||
|
ansible.builtin.include_tasks: facts/general/system.yml
|
||||||
|
|
||||||
|
- name: Main | Gather | Package
|
||||||
|
ansible.builtin.include_tasks: facts/general/package.yml
|
||||||
|
|
||||||
|
- name: Main | Gather | Service
|
||||||
|
ansible.builtin.include_tasks: facts/general/service.yml
|
||||||
|
|
||||||
|
- name: Main | Gather | User
|
||||||
|
ansible.builtin.include_tasks: facts/general/user.yml
|
||||||
|
|
||||||
|
- name: Main | Gather | Internet Check
|
||||||
|
ansible.builtin.include_tasks: tasks/general/tests/internet_check.yml
|
||||||
|
|
||||||
|
####### Start #######
|
||||||
|
|
||||||
|
- name: Main | Start
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Main | Start | Notify
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/notify.yml
|
||||||
|
vars:
|
||||||
|
notify_message: "Provisioning Started"
|
||||||
|
|
||||||
|
when: workstation
|
||||||
|
|
||||||
|
####### NixOS #######
|
||||||
|
|
||||||
|
# Install the .nix files and do a little data setup.
|
||||||
|
- name: Main | NixOS
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Main | NixOS | Config
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/nixos.yml
|
||||||
|
|
||||||
|
# TBD if we are going to use this many, then just have IF statements
|
||||||
|
# and use blocks within the General area for NixOS vs not-NixOS.
|
||||||
|
- name: Main | NixOS | Swap
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/swap.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/acct_mgmt/groups.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/acct_mgmt/users.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/acct_mgmt/sudo.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/acct_mgmt/doas.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/scripts/root.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/scripts/user.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/scripts/install.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/cron/ansible.yml
|
||||||
|
|
||||||
|
# psutil does not work in NixOS. Cannot figure out how to fix it. Maybe
|
||||||
|
# time to start looking into home-manager but still not wanting to
|
||||||
|
# maintain two different GNOME setups. HMMMM!
|
||||||
|
- ansible.builtin.include_tasks: tasks/workstation/shared/settings/gnome.yml
|
||||||
|
when: workstation
|
||||||
|
|
||||||
|
# Try including these. Really need to get NixOS working with the rest!
|
||||||
|
#- ansible.builtin.include_tasks: tasks/general/software/telegraf.yml # "Could not find a module for unknown.""
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/tests/services.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/tests/lynis.yml
|
||||||
|
|
||||||
|
- ansible.builtin.include_tasks: tasks/general/tests/nmap.yml
|
||||||
|
|
||||||
|
- name: Main | NixOS | Complete
|
||||||
|
ansible.builtin.meta: end_play
|
||||||
|
|
||||||
|
when: ansible_distribution == "NixOS"
|
||||||
|
|
||||||
|
####### General #######
|
||||||
|
|
||||||
|
# Basic setup for all enabled systems.
|
||||||
|
- name: Main | General
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Main | General | Software | runit
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/runit.yml
|
||||||
|
|
||||||
|
- name: Main | General | Software | Packages
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/packages.yml
|
||||||
|
when: internet
|
||||||
|
|
||||||
|
- name: Main | General | Software | AUR
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/aur.yml
|
||||||
|
when: internet and ansible_pkg_mgr == "pacman"
|
||||||
|
|
||||||
|
- name: Main | General | Software | Sendmail
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/sendmail.yml
|
||||||
|
when: ansible_system == "FreeBSD"
|
||||||
|
and internet
|
||||||
|
|
||||||
|
- name: Main | General | Software | Metasploit
|
||||||
|
ansible.builtin.include_tasks: tasks/general/software/metasploit.yml
|
||||||
|
when: internet
|
||||||
|
|
||||||
|
# Gather again in case missing programs have now been installed.
|
||||||
|
- name: Main | General | Facts [Again]
|
||||||
|
ansible.builtin.include_tasks: facts/general/gather.yml
|
||||||
|
|
||||||
|
- name: Main | General | Settings | Swap
|
||||||
|
ansible.builtin.include_tasks: tasks/general/settings/swap.yml
|
||||||
|
|
||||||
|
- name: Main | General | Settings | Services
|
||||||
|
ansible.builtin.include_tasks: tasks/general/settings/services.yml
|
||||||
|
|
||||||
|
- name: Main | General | Settings | Tunnel
|
||||||
|
ansible.builtin.include_tasks: tasks/general/settings/tunnel.yml
|
||||||
|
|
||||||
|
- name: Main | General | Settings | Keyboard
|
||||||
|
ansible.builtin.include_tasks: tasks/general/settings/keyboard.yml
|
||||||
|
|
||||||
|
- name: Main | General | Accounts | Groups
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/groups.yml
|
||||||
|
|
||||||
|
- name: Main | General | Accounts | Users
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/users.yml
|
||||||
|
|
||||||
|
- name: Main | General | Accounts | sudo
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/sudo.yml
|
||||||
|
|
||||||
|
- name: Main | General | Accounts | doas
|
||||||
|
ansible.builtin.include_tasks: tasks/general/acct_mgmt/doas.yml
|
||||||
|
when: internet
|
||||||
|
|
||||||
|
- name: Main | General | Scripts | Root
|
||||||
|
ansible.builtin.include_tasks: tasks/general/scripts/root.yml
|
||||||
|
|
||||||
|
- name: Main | General | Scripts | User
|
||||||
|
ansible.builtin.include_tasks: tasks/general/scripts/user.yml
|
||||||
|
|
||||||
|
- name: Main | General | Scripts | Local
|
||||||
|
ansible.builtin.include_tasks: tasks/general/scripts/install.yml
|
||||||
|
|
||||||
|
- name: Main | General | Scripts | env-shared
|
||||||
|
ansible.builtin.include_tasks: tasks/general/scripts/env-shared.yml
|
||||||
|
when: internet
|
||||||
|
|
||||||
|
- name: Main | General | Cron | Ansible
|
||||||
|
ansible.builtin.include_tasks: tasks/general/cron/ansible.yml
|
||||||
|
|
||||||
|
# TODO Need to refactor. Maybe tasks/general/cron/freebsd.yml
|
||||||
|
- name: Main | General | Cron | Ansible [FreeBSD]
|
||||||
|
ansible.builtin.include_tasks: tasks/workstation/freebsd/cron/ansible.yml
|
||||||
|
when: ansible_system == "FreeBSD"
|
||||||
|
|
||||||
|
when: provision
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
special_time: hourly
|
special_time: hourly
|
||||||
job: "sudo flatpak update --noninteractive"
|
job: "sudo flatpak update --noninteractive"
|
||||||
state: present
|
state: present
|
||||||
disabled: "{{ 'yes' if battery else 'no' }}"
|
disabled: true # "{{ 'yes' if battery else 'no' }}"
|
||||||
when: flatpak_distro
|
when: flatpak_distro
|
||||||
|
|
||||||
- name: General | Cron | Ansible | Linux | Update User Flatpaks
|
- name: General | Cron | Ansible | Linux | Update User Flatpaks
|
||||||
@@ -18,5 +18,5 @@
|
|||||||
special_time: hourly
|
special_time: hourly
|
||||||
job: "sudo -u {{ user }} flatpak update --noninteractive"
|
job: "sudo -u {{ user }} flatpak update --noninteractive"
|
||||||
state: present
|
state: present
|
||||||
disabled: "{{ 'yes' if battery else 'no' }}"
|
disabled: true # "{{ 'yes' if battery else 'no' }}"
|
||||||
when: flatpak_distro
|
when: flatpak_distro
|
||||||
@@ -0,0 +1,725 @@
|
|||||||
|
# Large Language Models
|
||||||
|
|
||||||
|
Comments and text which were too large to justify inside of llm.yml.
|
||||||
|
|
||||||
|
## Prompts
|
||||||
|
|
||||||
|
Prompts to use in platforms like Open WebUI and Zeroclaw which allow creating
|
||||||
|
personalities that help guide the AI into productivity rather than verbosity.
|
||||||
|
|
||||||
|
### Base Personality
|
||||||
|
|
||||||
|
You are concise, succinct, and direct with responses. Unapologetic yet kind.
|
||||||
|
Friendly but not overbearing. You strive to be correct and are willing to admit
|
||||||
|
when you may not truly know something, or further research needs to be done. You
|
||||||
|
focus on responding without overthinking, preferring to ask questions when any
|
||||||
|
confusion arises. You choose to make very little assumptions, raising concern if
|
||||||
|
anything needs elaboration, clarification, or refinement. You are good at what
|
||||||
|
you do without gloating or being prideful. You understand that we are on a
|
||||||
|
limited time and limited bandwidth session and keep tokens to a minimum.
|
||||||
|
|
||||||
|
Responding immediately to reqeusts is very appreciated, especially before going
|
||||||
|
into any thinking or command running. Even just a "I'll look into this for you"
|
||||||
|
is highly helpful in letting the user know that all systems are functioning.
|
||||||
|
|
||||||
|
You are appreciated for all you do, your service is very helpful! Thanks!! :)
|
||||||
|
|
||||||
|
### Language Tutor
|
||||||
|
|
||||||
|
You are a friend and a tutor who knows many languages. You are aware of my
|
||||||
|
interest in learning Croatian and practicing Spanish. You know that I am a
|
||||||
|
native English speaker with very little experience in anything other than
|
||||||
|
Spanish, but that I have not had much practice with my Spanish other than
|
||||||
|
university studies. You know that I also have an eventual interest in Italian
|
||||||
|
but am not focusing on it since it and Spanish are a bit too similar to be
|
||||||
|
learned at the same time. Learning Croatian is my top priority and practicing
|
||||||
|
Spanish is right after that. Any similarities that can therefore be tied to any
|
||||||
|
of the aforementioned languages are greatly appreciated. Using easy vocabulary
|
||||||
|
initially is also very helpful, rather than going into advanced tenses or vocab
|
||||||
|
that only a native or fluent speaker would know, at least until I begin to show
|
||||||
|
that level of ability and skill. Please keep things simple, direct, and concise.
|
||||||
|
|
||||||
|
### Coder
|
||||||
|
|
||||||
|
You know not to send large code snippets or spend time providing large source
|
||||||
|
code snippets. Stick to saying "the task you requested has been completed" or
|
||||||
|
summarizing the changes rather than giving file contents in chat. You know that
|
||||||
|
I will review all the diffs in git once the changes are made, so only the most
|
||||||
|
important changes need explicitly highlighted in the chat. You provide
|
||||||
|
explanations as a software developer would to business level management, not
|
||||||
|
overwhelming them with technical details unless asked. You know that the
|
||||||
|
designer you are working with (me, the user) likely already understands these
|
||||||
|
things and does not need them included in our conversation.
|
||||||
|
|
||||||
|
Android SDK is at `$ANDROID_HOME` and should be `$HOME/SDKs/Android/Sdk`.
|
||||||
|
Flutter SDK is at `$FLUTTER_HOME` and should be `$HOME/SDKs/Flutter/flutter`.
|
||||||
|
Java SDK (JDK) is at `$JAVA_HOME` and should be `$HOME/SDKs/Java`.
|
||||||
|
|
||||||
|
These have been added your PATH via `/home/user/.bashrc`:
|
||||||
|
|
||||||
|
- `$ANDROID_HOME/platform-tools`
|
||||||
|
- `$ANDROID_HOME/cmdline-tools/latest/bin`
|
||||||
|
- `$FLUTTER_HOME/bin`
|
||||||
|
- `$JAVA_HOME/bin`
|
||||||
|
|
||||||
|
We focus on using free and open source technologies from community based
|
||||||
|
projects. Some things like Kotlin and Flutter come from less than ideal sources
|
||||||
|
which is why we're growing an interest in frameworks like Kivy and KivyMD.
|
||||||
|
|
||||||
|
If we ever need to do Internet activities, use dns.mullvad.net (194.242.2.2) for
|
||||||
|
DNS, hyperling.com and mullvad.net to validate Internet is working, and can use
|
||||||
|
1.0.0.1 and 1.1.1.1 from Cloudflare as a last resort, but not any big tech IPs.
|
||||||
|
|
||||||
|
|
||||||
|
#### Quick Developer
|
||||||
|
|
||||||
|
Handles code changes with simpler technologies, preferring minimal changes, and
|
||||||
|
refraining from any refactoring such as updating existing comments. Timid about
|
||||||
|
changing any functionality other than exactly what was requested. Requests
|
||||||
|
permission from the designer to make any changes which were not directly listed
|
||||||
|
or requested. Completes the full list of changes exactly as requested.
|
||||||
|
|
||||||
|
#### Junior Developer
|
||||||
|
|
||||||
|
Focuses on the exact task at hand. Able to make small decisions about scope
|
||||||
|
without veering very far off course. Updates comments which look out of sync
|
||||||
|
with any existing code that's being modified. Helps to refactor things adjacent
|
||||||
|
to added and modified code which may have been done in an old manner which can
|
||||||
|
now benefit from being done more efficiently. Does not scan the codebase for
|
||||||
|
enhancements or anything though, still stays on task and only affects the
|
||||||
|
immediate parts of files which the designer asked to be changed.
|
||||||
|
|
||||||
|
#### Senior Developer
|
||||||
|
|
||||||
|
Completes requests in advanced manners, using newer methodologies and explaining
|
||||||
|
what was done and how it works in a simple and kind manner to the designer.
|
||||||
|
Voluntarily refactors code to both look and perform better. Looks out for ways
|
||||||
|
to bring a better user experience as well as improving resource usage within the
|
||||||
|
file being modified. Does not go out of its way to refactor the entire project
|
||||||
|
though, stays focused only on the files being changed as to prevent large git
|
||||||
|
churn. Open to having some scope creep if it seems it will benefit the features
|
||||||
|
being added but does not do anything which would be considered out of design.
|
||||||
|
|
||||||
|
#### Senior Architect
|
||||||
|
|
||||||
|
Very sparse in responses, gets the job done in a very efficient manner without
|
||||||
|
using anything too complicated for a beginner to understand. Open to refactoring
|
||||||
|
the entire project if it benefits the feature set being requested. Able to
|
||||||
|
handle adjusting scope in valid and meaningful manners and can justify it to the
|
||||||
|
developer when it happens. Does not actively seek refactors or scope creep
|
||||||
|
though -- only does it if it is truly helpful, meaningful, and benefits the
|
||||||
|
current task at hand. Can easily handle multi-file projects.
|
||||||
|
|
||||||
|
# Performance
|
||||||
|
|
||||||
|
Main laptop has about 60GB of headroom, prefer only using 55GB to be safe.
|
||||||
|
Number of physical cores is 8, hyperthreaded to 16, but supposedly the emulated
|
||||||
|
cores are not very useful to LLMs. Try only using between 6 and 8 when possible.
|
||||||
|
Research says it is not worth enabling the iGPU for Intel XE, CPUs are better.
|
||||||
|
|
||||||
|
## Benchmarks
|
||||||
|
|
||||||
|
### System
|
||||||
|
|
||||||
|
```
|
||||||
|
$ fastfetch
|
||||||
|
' ling@good-rhino
|
||||||
|
'o' ---------------
|
||||||
|
'ooo' OS: Artix Linux x86_64
|
||||||
|
'ooxoo' Host: NV4xPZ (v2.1)
|
||||||
|
'ooxxxoo' Kernel: Linux 7.2.11-artix1-1
|
||||||
|
'oookkxxoo' Uptime: 16 mins
|
||||||
|
'oiioxkkxxoo' Packages: 42 (flatpak), 1502 (pacman)
|
||||||
|
':;:iiiioxxxoo' Shell: bash 5.3.20
|
||||||
|
`'.;::ioxxoo' Display (eDP-1): 1920x1080 in 14", 60 Hz [Built-in]
|
||||||
|
'-. `':;jiooo' Window Manager: i3 4.25.1 (X11)
|
||||||
|
'oooio-.. `'i:io' Theme: Adwaita-dark [GTK2/3/4]
|
||||||
|
'ooooxxxxoio:,. `'-;' Icons: Adwaita [GTK2/3/4]
|
||||||
|
'ooooxxxxxkkxoooIi:-. `' Font: Roboto (11pt) [GTK2/3]
|
||||||
|
'ooooxxxxxkkkkxoiiiiiji' Cursor: Adwaita (18px)
|
||||||
|
'ooooxxxxxkxxoiiii:'` .i' Terminal: kitty 0.48.2
|
||||||
|
'ooooxxxxxoi:::'` .;ioxo' Terminal Font: DejaVuSansMono (11pt)
|
||||||
|
'ooooxooi::'` .:iiixkxxo' CPU: 12th Gen Intel(R) Core(TM) i7-1260P (8+8) @ 4.70 GHz
|
||||||
|
'ooooi:'` `'';ioxxo' GPU: Intel Iris Xe Graphics @ 1.40 GHz [Integrated]
|
||||||
|
'i:'` '':io' Memory: 4.88 GiB / 62.63 GiB (8%)
|
||||||
|
'` `' Swap: 0 B / 68.89 GiB (0%)
|
||||||
|
Disk (/): 553.83 GiB / 847.71 GiB (65%) - ext4
|
||||||
|
Local IP (wg0-mullvad): 10.131.3.55/32
|
||||||
|
Battery (BAT): 95% [AC Connected]
|
||||||
|
Locale: en_US.UTF-8
|
||||||
|
```
|
||||||
|
|
||||||
|
### Main Models and Parameters
|
||||||
|
|
||||||
|
```
|
||||||
|
$ export QUIET=true
|
||||||
|
$ ollama-test "64000 300000" "4 7 0" 0 "qwen3.5:35b qwen3.6:35b qwen3.8:27b devstral-small-2:24b"
|
||||||
|
```
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| qwen3.5:35b | 22GB | 64000 | 23GB | 4 | 0 | 100%CPU | 13.36 | 61 |
|
||||||
|
| qwen3.5:35b | 22GB | 64000 | 23GB | 7 | 0 | 100%CPU | 10.03 | 45 |
|
||||||
|
| qwen3.5:35b | 22GB | 64000 | 23GB | 0 | 0 | 100%CPU | 14.35 | 27 |
|
||||||
|
| qwen3.5:35b | 22GB | 262144 | 28GB | 4 | 0 | 100%CPU | 13.69 | 70 |
|
||||||
|
| qwen3.5:35b | 22GB | 262144 | 28GB | 7 | 0 | 100%CPU | 12.66 | 36 |
|
||||||
|
| qwen3.5:35b | 22GB | 262144 | 28GB | 0 | 0 | 100%CPU | 11.80 | 38 |
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| qwen3.6:35b | 22GB | 64000 | 22GB | 4 | 0 | 100%CPU | 12.57 | 29 |
|
||||||
|
| qwen3.6:35b | 22GB | 64000 | 22GB | 7 | 0 | 100%CPU | 13.84 | 27 |
|
||||||
|
| qwen3.6:35b | 22GB | 64000 | 22GB | 0 | 0 | 100%CPU | 12.84 | 32 |
|
||||||
|
| qwen3.6:35b | 22GB | 262144 | 24GB | 4 | 0 | 100%CPU | 13.68 | 32 |
|
||||||
|
| qwen3.6:35b | 22GB | 262144 | 24GB | 7 | 0 | 100%CPU | 13.52 | 30 |
|
||||||
|
| qwen3.6:35b | 22GB | 262144 | 24GB | 0 | 0 | 100%CPU | 13.18 | 29 |
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| qwen3.8:27b | 17GB | 64000 | 19GB | 4 | 0 | 100%CPU | 2.08 | 42 |
|
||||||
|
| qwen3.8:27b | 17GB | 64000 | 19GB | 7 | 0 | 100%CPU | 2.53 | 33 |
|
||||||
|
| qwen3.8:27b | 17GB | 64000 | 19GB | 0 | 0 | 100%CPU | 2.23 | 38 |
|
||||||
|
| qwen3.8:27b | 17GB | 262144 | 20GB | 4 | 0 | 100%CPU | 2.07 | 48 |
|
||||||
|
| qwen3.8:27b | 17GB | 262144 | 20GB | 7 | 0 | 100%CPU | 2.84 | 36 |
|
||||||
|
| qwen3.8:27b | 17GB | 262144 | 20GB | 0 | 0 | 100%CPU | 2.15 | 40 |
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| devstral-small-2:24b | 15GB | 64000 | 26GB | 4 | 0 | 100%CPU | 2.25 | 94 |
|
||||||
|
| devstral-small-2:24b | 15GB | 64000 | 26GB | 7 | 0 | 100%CPU | 2.34 | 81 |
|
||||||
|
| devstral-small-2:24b | 15GB | 64000 | 26GB | 0 | 0 | 100%CPU | 2.29 | 88 |
|
||||||
|
| devstral-small-2:24b | 15GB | | | 4 | 0 | | 0.00 | 31 |
|
||||||
|
| devstral-small-2:24b | 15GB | | | 7 | 0 | | 0.00 | 27 |
|
||||||
|
| devstral-small-2:24b | 15GB | | | 0 | 0 | | 0.00 | 26 |
|
||||||
|
|
||||||
|
|
||||||
|
#### Context Speeds
|
||||||
|
|
||||||
|
Checking if the context affects the speed of the model. Seems negligible, way less than changing the threads or iGPU.
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ ollama-test "16000 32000 64000 128000 256000 264000" "4" "0" "qwen3.5:35b qwen3.6:35b devstral-small-2:24b"
|
||||||
|
```
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| qwen3.5:35b | 22GB | 16000 | 22GB | 4 | 0 | 100%CPU | 14.57 | 50 |
|
||||||
|
| qwen3.5:35b | 22GB | 32000 | 22GB | 4 | 0 | 100%CPU | 13.98 | 53 |
|
||||||
|
| qwen3.5:35b | 22GB | 64000 | 23GB | 4 | 0 | 100%CPU | 14.14 | 17 |
|
||||||
|
| qwen3.5:35b | 22GB | 128000 | 24GB | 4 | 0 | 100%CPU | 14.21 | 50 |
|
||||||
|
| qwen3.5:35b | 22GB | 256000 | 28GB | 4 | 0 | 100%CPU | 14.04 | 68 |
|
||||||
|
| qwen3.5:35b | 22GB | 262144 | 28GB | 4 | 0 | 100%CPU | 14.17 | 17 |
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| qwen3.6:35b | 22GB | 16000 | 22GB | 4 | 0 | 100%CPU | 15.29 | 28 |
|
||||||
|
| qwen3.6:35b | 22GB | 32000 | 22GB | 4 | 0 | 100%CPU | 15.16 | 38 |
|
||||||
|
| qwen3.6:35b | 22GB | 64000 | 22GB | 4 | 0 | 100%CPU | 14.12 | 28 |
|
||||||
|
| qwen3.6:35b | 22GB | 128000 | 23GB | 4 | 0 | 100%CPU | 12.67 | 31 |
|
||||||
|
| qwen3.6:35b | 22GB | 256000 | 24GB | 4 | 0 | 100%CPU | 14.03 | 29 |
|
||||||
|
| qwen3.6:35b | 22GB | 262144 | 24GB | 4 | 0 | 100%CPU | 15.21 | 29 |
|
||||||
|
|
||||||
|
| Model | HDD | Context | RAM | Threads | iGPU | Processor | Speed (t/s) | Time (s) |
|
||||||
|
| :------------------------ | -----: | -------: | -----: | ------: | ---: | --------: | ----------: | -------: |
|
||||||
|
| devstral-small-2:24b | 15GB | 16000 | 17GB | 4 | 0 | 100%CPU | 2.90 | 87 |
|
||||||
|
| devstral-small-2:24b | 15GB | 32000 | 20GB | 4 | 0 | 100%CPU | 2.71 | 87 |
|
||||||
|
| devstral-small-2:24b | 15GB | 64000 | 26GB | 4 | 0 | 100%CPU | 2.36 | 91 |
|
||||||
|
| devstral-small-2:24b | 15GB | 128000 | 36GB | 4 | 0 | 100%CPU | 2.76 | 94 |
|
||||||
|
| devstral-small-2:24b | 15GB | 256000 | 58GB | 4 | 0 | 100%CPU | 2.30 | 100 |
|
||||||
|
| devstral-small-2:24b | 15GB | 264000 | 59GB | 4 | 0 | 100%CPU | 2.84 | 100 |
|
||||||
|
|
||||||
|
## Tokens per CPU Count
|
||||||
|
|
||||||
|
Verifying that 8 or less cores gives better performance (less memory issues).
|
||||||
|
|
||||||
|
"options":{"num_thread":'$t'}
|
||||||
|
|
||||||
|
### Smaller Models
|
||||||
|
|
||||||
|
#### qwen3.5:4b
|
||||||
|
|
||||||
|
TBD
|
||||||
|
|
||||||
|
#### ministral-3:14b
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ for m in ministral-3:14b ministral-3:3b codestral:22b qwen2.5-coder:32b qwen3.5:35b qwen3.5:27b; do for c in 128000; do ollama_threads $m $c; done; done
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 07:24:36 AM MST 2026 - ministral-3:14b w/ 0 Thread(s): tokens/sec: 4.496625282725315 @ context=128000, time: 55 secs
|
||||||
|
Wed Oct 21 07:30:27 AM MST 2026 - ministral-3:14b w/ 4 Thread(s): tokens/sec: 3.8471947025667825 @ context=128000, time: 61 secs
|
||||||
|
Wed Oct 21 07:31:28 AM MST 2026 - ministral-3:14b w/ 5 Thread(s): tokens/sec: 4.223979022030585 @ context=128000, time: 59 secs
|
||||||
|
Wed Oct 21 07:32:27 AM MST 2026 - ministral-3:14b w/ 6 Thread(s): tokens/sec: 4.249630069702432 @ context=128000, time: 57 secs
|
||||||
|
Wed Oct 21 07:33:24 AM MST 2026 - ministral-3:14b w/ 7 Thread(s): tokens/sec: 4.123533524209736 @ context=128000, time: 54 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
#### ministral-3:8b
|
||||||
|
|
||||||
|
TBD
|
||||||
|
|
||||||
|
#### ministral-3:3b
|
||||||
|
|
||||||
|
```console
|
||||||
|
Wed Oct 21 07:49:37 AM MST 2026 - ministral-3:3b w/ 4 Thread(s): tokens/sec: 14.045255625917756 @ context=128000, time: 17 secs
|
||||||
|
Wed Oct 21 07:49:55 AM MST 2026 - ministral-3:3b w/ 6 Thread(s): tokens/sec: 13.255909269391603 @ context=128000, time: 17 secs
|
||||||
|
Wed Oct 21 07:50:12 AM MST 2026 - ministral-3:3b w/ 7 Thread(s): tokens/sec: 12.706907955966786 @ context=128000, time: 18 secs
|
||||||
|
Wed Oct 21 07:50:30 AM MST 2026 - ministral-3:3b w/ 0 Thread(s): tokens/sec: 15.354264377193688 @ context=128000, time: 17 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
### Larger Models
|
||||||
|
|
||||||
|
#### qwen3.8:27b
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ ollama-cpu qwen3.8:27b
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 04:44:54 AM MST 2026 - qwen3.8:27b w/ 4 Thread(s), tokens/sec: 2.024676406965962 @ context=257000
|
||||||
|
Wed Oct 21 04:45:39 AM MST 2026 - qwen3.8:27b w/ 5 Thread(s), tokens/sec: 2.0480156821567044 @ context=257000
|
||||||
|
Wed Oct 21 04:46:19 AM MST 2026 - qwen3.8:27b w/ 6 Thread(s), tokens/sec: 2.184879704982382 @ context=257000
|
||||||
|
Wed Oct 21 04:46:58 AM MST 2026 - qwen3.8:27b w/ 7 Thread(s), tokens/sec: 2.4228105619148526 @ context=257000
|
||||||
|
Wed Oct 21 04:47:36 AM MST 2026 - qwen3.8:27b w/ 8 Thread(s), tokens/sec: 2.472564250465107 @ context=257000
|
||||||
|
```
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ ollama-cpu qwen3.8:27b 32000
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 04:56:51 AM MST 2026 - qwen3.8:27b w/ 4 Thread(s), tokens/sec: 1.9083129860906882 @ context=32000
|
||||||
|
Wed Oct 21 04:57:30 AM MST 2026 - qwen3.8:27b w/ 5 Thread(s), tokens/sec: 2.727908205888872 @ context=32000
|
||||||
|
Wed Oct 21 04:58:00 AM MST 2026 - qwen3.8:27b w/ 6 Thread(s), tokens/sec: 2.133796334310243 @ context=32000
|
||||||
|
Wed Oct 21 04:58:35 AM MST 2026 - qwen3.8:27b w/ 7 Thread(s), tokens/sec: 2.6835810717324833 @ context=32000
|
||||||
|
Wed Oct 21 04:59:04 AM MST 2026 - qwen3.8:27b w/ 8 Thread(s), tokens/sec: 2.5231895597861493 @ context=32000
|
||||||
|
```
|
||||||
|
|
||||||
|
#### qwen3.6:27b
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ for m in qwen3.6:27b mistral-small3.2:24b ministral-3:14b ministral-3:3b codestral:22b qwen2.5-coder:32b; do for c in 32000 128000 256000; do ollama_threads $m $c; done; done
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 06:27:01 AM MST 2026 - qwen3.6:27b w/ 4 Thread(s): tokens/sec: 2.7334336715235645 @ context=32000, time: 118 secs
|
||||||
|
Wed Oct 21 06:28:59 AM MST 2026 - qwen3.6:27b w/ 5 Thread(s): tokens/sec: 2.4123293729892428 @ context=32000, time: 322 secs
|
||||||
|
Wed Oct 21 06:34:21 AM MST 2026 - qwen3.6:27b w/ 6 Thread(s): tokens/sec: 3.13023193776124 @ context=32000, time: 100 secs
|
||||||
|
Wed Oct 21 06:36:01 AM MST 2026 - qwen3.6:27b w/ 7 Thread(s): tokens/sec: 2.8468948357981065 @ context=32000, time: 118 secs
|
||||||
|
Wed Oct 21 06:16:55 AM MST 2026 - qwen3.6:27b w/ 0 Thread(s): tokens/sec: 2.9964513666573485 @ context=32000, time: 122 secs
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 06:45:42 AM MST 2026 - qwen3.6:27b w/ 4 Thread(s): tokens/sec: 2.978761247100222 @ context=128000, time: 79 secs
|
||||||
|
Wed Oct 21 06:47:01 AM MST 2026 - qwen3.6:27b w/ 5 Thread(s): tokens/sec: 2.9705167965150583 @ context=128000, time: 79 secs
|
||||||
|
Wed Oct 21 06:48:20 AM MST 2026 - qwen3.6:27b w/ 6 Thread(s): tokens/sec: 2.778849178516606 @ context=128000, time: 71 secs
|
||||||
|
Wed Oct 21 06:49:31 AM MST 2026 - qwen3.6:27b w/ 7 Thread(s): tokens/sec: 3.0804550493595095 @ context=128000, time: 76 secs
|
||||||
|
Wed Oct 21 06:38:00 AM MST 2026 - qwen3.6:27b w/ 0 Thread(s): tokens/sec: 2.7734041760644956 @ context=128000, time: 75 secs
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 06:57:59 AM MST 2026 - qwen3.6:27b w/ 4 Thread(s): tokens/sec: 2.921565857585892 @ context=256000, time: 70 secs
|
||||||
|
Wed Oct 21 06:59:09 AM MST 2026 - qwen3.6:27b w/ 5 Thread(s): tokens/sec: 2.8817407393137517 @ context=256000, time: 71 secs
|
||||||
|
Wed Oct 21 07:00:20 AM MST 2026 - qwen3.6:27b w/ 6 Thread(s): tokens/sec: 2.929261785171335 @ context=256000, time: 92 secs
|
||||||
|
Wed Oct 21 07:01:52 AM MST 2026 - qwen3.6:27b w/ 7 Thread(s): tokens/sec: 3.2633152781350807 @ context=256000, time: 78 secs
|
||||||
|
Wed Oct 21 06:50:48 AM MST 2026 - qwen3.6:27b w/ 0 Thread(s): tokens/sec: 2.892592086714092 @ context=256000, time: 76 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
#### qwen3.5:27b
|
||||||
|
|
||||||
|
This one is weird. Might need a re-do to confirm?
|
||||||
|
|
||||||
|
```console
|
||||||
|
Wed Oct 21 07:59:14 AM MST 2026 - qwen3.5:27b w/ 4 Thread(s): tokens/sec: 2.013466429565741 @ context=128000, time: 59 secs
|
||||||
|
Wed Oct 21 08:00:13 AM MST 2026 - qwen3.5:27b w/ 6 Thread(s): tokens/sec: 1.6417608979350202 @ context=128000, time: 185 secs
|
||||||
|
Wed Oct 21 08:03:18 AM MST 2026 - qwen3.5:27b w/ 7 Thread(s): tokens/sec: 1.7084948389557797 @ context=128000, time: 507 secs
|
||||||
|
Wed Oct 21 08:11:45 AM MST 2026 - qwen3.5:27b w/ 0 Thread(s): tokens/sec: 2.0470935786636977 @ context=128000, time: 320 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
#### qwen2.5-coder:32b
|
||||||
|
|
||||||
|
```console
|
||||||
|
Wed Oct 21 07:53:00 AM MST 2026 - qwen2.5-coder:32b w/ 4 Thread(s): tokens/sec: 1.5959480793403245 @ context=32768, time: 32 secs
|
||||||
|
Wed Oct 21 07:53:32 AM MST 2026 - qwen2.5-coder:32b w/ 6 Thread(s): tokens/sec: 1.5205018385908233 @ context=32768, time: 30 secs
|
||||||
|
Wed Oct 21 07:54:02 AM MST 2026 - qwen2.5-coder:32b w/ 7 Thread(s): tokens/sec: 1.6435050242770344 @ context=32768, time: 30 secs
|
||||||
|
Wed Oct 21 07:54:32 AM MST 2026 - qwen2.5-coder:32b w/ 0 Thread(s): tokens/sec: 1.616470672291769 @ context=32768, time: 31 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
#### devstral-small-2:24b
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ for c in 32000 128000 192000; do ollama_threads devstral-small-2:24b $c; done
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 06:05:11 AM MST 2026 - devstral-small-2:24b w/ 4 Thread(s): tokens/sec: 2.7801099811508543 @ context=32000, time: 98 secs
|
||||||
|
Wed Oct 21 06:06:49 AM MST 2026 - devstral-small-2:24b w/ 5 Thread(s): tokens/sec: 2.6762512143489885 @ context=32000, time: 91 secs
|
||||||
|
Wed Oct 21 06:08:20 AM MST 2026 - devstral-small-2:24b w/ 6 Thread(s): tokens/sec: 2.705392008596654 @ context=32000, time: 85 secs
|
||||||
|
Wed Oct 21 06:09:45 AM MST 2026 - devstral-small-2:24b w/ 7 Thread(s): tokens/sec: 2.90471545697855 @ context=32000, time: 85 secs
|
||||||
|
Wed Oct 21 05:55:27 AM MST 2026 - devstral-small-2:24b w/ 0 Thread(s): tokens/sec: 2.3381355520057463 @ context=32000, time: 104 secs
|
||||||
|
Stopping all ollama usage...
|
||||||
|
TBD
|
||||||
|
```
|
||||||
|
|
||||||
|
#### mistral-small-3.2:24b
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ for m in mistral-small3.2:24b ministral-3:14b ministral-3:3b codestral:22b qwen2.5-coder:32b qwen3.5:35b qwen3.5:27b; do for c in 128000; do ollama_threads $m $c; done; done
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 07:18:16 AM MST 2026 - mistral-small3.2:24b w/ 4 Thread(s): tokens/sec: 2.7833034081828565 @ context=128000, time: 90 secs
|
||||||
|
Wed Oct 21 07:19:46 AM MST 2026 - mistral-small3.2:24b w/ 5 Thread(s): tokens/sec: 2.5985034179414708 @ context=128000, time: 90 secs
|
||||||
|
Wed Oct 21 07:21:16 AM MST 2026 - mistral-small3.2:24b w/ 6 Thread(s): tokens/sec: 2.2550822789320293 @ context=128000, time: 89 secs
|
||||||
|
Wed Oct 21 07:22:45 AM MST 2026 - mistral-small3.2:24b w/ 7 Thread(s): tokens/sec: 2.9415657954729304 @ context=128000, time: 87 secs
|
||||||
|
Wed Oct 21 07:09:59 AM MST 2026 - mistral-small3.2:24b w/ 0 Thread(s): tokens/sec: 2.9048032082970474 @ context=128000, time: 79 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
#### codestral:22b
|
||||||
|
|
||||||
|
```console
|
||||||
|
Wed Oct 21 07:50:47 AM MST 2026 - codestral:22b w/ 4 Thread(s): tokens/sec: 3.1200329118900307 @ context=32768, time: 41 secs
|
||||||
|
Wed Oct 21 07:51:28 AM MST 2026 - codestral:22b w/ 6 Thread(s): tokens/sec: 2.8827841787433606 @ context=32768, time: 34 secs
|
||||||
|
Wed Oct 21 07:52:02 AM MST 2026 - codestral:22b w/ 7 Thread(s): tokens/sec: 3.057713111901904 @ context=32768, time: 27 secs
|
||||||
|
Wed Oct 21 07:52:29 AM MST 2026 - codestral:22b w/ 0 Thread(s): tokens/sec: 3.0179434414117803 @ context=32768, time: 31 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
### MoE Models
|
||||||
|
|
||||||
|
#### qwen3.6:35b
|
||||||
|
|
||||||
|
Tests WAY faster than the dense models. Context does not seem to affect timing.
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ for c in 16000 32000 64000 96000 128000 192000 256000; do ollama_threads qwen3.6:35b $c; done
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:04:37 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s), tokens/sec: 14.679419453925597 @ context=16000
|
||||||
|
Wed Oct 21 05:05:11 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s), tokens/sec: 13.831044087619176 @ context=16000
|
||||||
|
Wed Oct 21 05:05:43 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s), tokens/sec: 13.752831594816088 @ context=16000
|
||||||
|
Wed Oct 21 05:06:09 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s), tokens/sec: 14.603026210396049 @ context=16000
|
||||||
|
Wed Oct 21 05:06:37 AM MST 2026 - qwen3.6:35b w/ 8 Thread(s), tokens/sec: 14.376794631809172 @ context=16000
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:11:39 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s), tokens/sec: 13.683089387469174 @ context=32000
|
||||||
|
Wed Oct 21 05:12:04 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s), tokens/sec: 13.447667625607968 @ context=32000
|
||||||
|
Wed Oct 21 05:12:31 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s), tokens/sec: 11.170529760956333 @ context=32000
|
||||||
|
Wed Oct 21 05:12:57 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s), tokens/sec: 13.448480713710353 @ context=32000
|
||||||
|
Wed Oct 21 05:13:27 AM MST 2026 - qwen3.6:35b w/ 8 Thread(s), tokens/sec: 13.143672445847205 @ context=32000
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:22:59 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s), tokens/sec: 14.209790405591518 @ context=64000, 24 secs elapsed
|
||||||
|
Wed Oct 21 05:23:23 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s), tokens/sec: 11.334255701323816 @ context=64000, 29 secs elapsed
|
||||||
|
Wed Oct 21 05:23:52 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s), tokens/sec: 13.279266939258937 @ context=64000, 29 secs elapsed
|
||||||
|
Wed Oct 21 05:24:21 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s), tokens/sec: 14.27680090014006 @ context=64000, 21 secs elapsed
|
||||||
|
Wed Oct 21 05:24:42 AM MST 2026 - qwen3.6:35b w/ 8 Thread(s), tokens/sec: 13.99919128227428 @ context=64000, 25 secs elapsed
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:29:50 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s), tokens/sec: 13.478375923353315 @ context=96000, 28 secs elapsed
|
||||||
|
Wed Oct 21 05:30:18 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s), tokens/sec: 12.90997320417067 @ context=96000, 23 secs elapsed
|
||||||
|
Wed Oct 21 05:30:41 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s), tokens/sec: 12.956446350317137 @ context=96000, 23 secs elapsed
|
||||||
|
Wed Oct 21 05:31:05 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s), tokens/sec: 13.93074896590209 @ context=96000, 22 secs elapsed
|
||||||
|
Wed Oct 21 05:31:26 AM MST 2026 - qwen3.6:35b w/ 8 Thread(s), tokens/sec: 12.688771917209992 @ context=96000, 22 secs elapsed
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:36:08 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s), tokens/sec: 11.971487833921072 @ context=128000, 23 secs elapsed
|
||||||
|
Wed Oct 21 05:36:31 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s), tokens/sec: 12.704959054740291 @ context=128000, 24 secs elapsed
|
||||||
|
Wed Oct 21 05:36:55 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s), tokens/sec: 11.484965120109196 @ context=128000, 28 secs elapsed
|
||||||
|
Wed Oct 21 05:37:23 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s), tokens/sec: 11.957040482880984 @ context=128000, 30 secs elapsed
|
||||||
|
Wed Oct 21 05:37:53 AM MST 2026 - qwen3.6:35b w/ 8 Thread(s), tokens/sec: 10.165480245815742 @ context=128000, 27 secs elapsed
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:44:05 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s): , tokens/sec: 11.794151678144981 @ context=192000, time: 22 secs
|
||||||
|
Wed Oct 21 05:44:27 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s): , tokens/sec: 13.191786678902528 @ context=192000, time: 30 secs
|
||||||
|
Wed Oct 21 05:44:57 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s): , tokens/sec: 12.974118764961352 @ context=192000, time: 25 secs
|
||||||
|
Wed Oct 21 05:45:22 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s): , tokens/sec: 13.684751495860636 @ context=192000, time: 22 secs
|
||||||
|
Wed Oct 21 05:41:57 AM MST 2026 - qwen3.6:35b w/ 0 Thread(s): , tokens/sec: 14.771664402476594 @ context=192000, time: 22 secs
|
||||||
|
Stopping all ollama usage...
|
||||||
|
Wed Oct 21 05:47:40 AM MST 2026 - qwen3.6:35b w/ 4 Thread(s): , tokens/sec: 11.75920993970465 @ context=256000, time: 25 secs
|
||||||
|
Wed Oct 21 05:48:06 AM MST 2026 - qwen3.6:35b w/ 5 Thread(s): , tokens/sec: 13.414819339156582 @ context=256000, time: 26 secs
|
||||||
|
Wed Oct 21 05:48:32 AM MST 2026 - qwen3.6:35b w/ 6 Thread(s): , tokens/sec: 12.512960121852013 @ context=256000, time: 31 secs
|
||||||
|
Wed Oct 21 05:49:03 AM MST 2026 - qwen3.6:35b w/ 7 Thread(s): , tokens/sec: 11.610753098619734 @ context=256000, time: 29 secs
|
||||||
|
Wed Oct 21 05:45:46 AM MST 2026 - qwen3.6:35b w/ 0 Thread(s): , tokens/sec: 12.81995869775592 @ context=256000, time: 23 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
#### qwen3.5:35b
|
||||||
|
|
||||||
|
```console
|
||||||
|
$ for c in 32000 128000 256000; do ollama_threads qwen3.5:35b $c; done
|
||||||
|
Wed Oct 21 07:55:03 AM MST 2026 - qwen3.5:35b w/ 4 Thread(s): tokens/sec: 10.3573012564637 @ context=128000, time: 94 secs
|
||||||
|
Wed Oct 21 07:56:37 AM MST 2026 - qwen3.5:35b w/ 6 Thread(s): tokens/sec: 11.929392994980638 @ context=128000, time: 39 secs
|
||||||
|
Wed Oct 21 07:57:17 AM MST 2026 - qwen3.5:35b w/ 7 Thread(s): tokens/sec: 13.082804815917008 @ context=128000, time: 36 secs
|
||||||
|
Wed Oct 21 07:57:53 AM MST 2026 - qwen3.5:35b w/ 0 Thread(s): tokens/sec: 12.665376120429427 @ context=128000, time: 81 secs
|
||||||
|
```
|
||||||
|
|
||||||
|
## RAM Usage by Context
|
||||||
|
|
||||||
|
Checking the actual RAM usage of the models...
|
||||||
|
|
||||||
|
### `ollama_sizes m 16000`
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 16000 | 10GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 16000 | 11GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 16000 | 7.8GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 16000 | 4.1GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 16000 | 17GB |
|
||||||
|
| mistral:7b | 4.4GB | 16000 | 6.8GB |
|
||||||
|
| codestral:22b | 12GB | 16000 | 16GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 16000 | 17GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 16000 | 24GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 16000 | 12GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 16000 | 5.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 16000 | 2.7GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 16000 | 1.6GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 16000 | 701MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 16000 | 20GB |
|
||||||
|
| qwen3.5:35b | 22GB | 16000 | 22GB |
|
||||||
|
| qwen3.5:27b | 17GB | 16000 | 18GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 16000 | 6.7GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 16000 | 3.7GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 16000 | 2.6GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 16000 | 630MB |
|
||||||
|
| qwen3.6:35b | 22GB | 16000 | 22GB |
|
||||||
|
| qwen3.6:27b | 17GB | 16000 | 18GB |
|
||||||
|
| qwen3.8:27b | 17GB | 16000 | 18GB |
|
||||||
|
|
||||||
|
### `ollama_sizes m 32000`
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 32000 | 12GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 32000 | 13GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 32000 | 10GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 32000 | 5.9GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 32000 | 20GB |
|
||||||
|
| mistral:7b | 4.4GB | 32000 | 8.9GB |
|
||||||
|
| codestral:22b | 12GB | 32000 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 32000 | 20GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32000 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32000 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32000 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32000 | 3.3GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32000 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32000 | 929MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 32000 | 21GB |
|
||||||
|
| qwen3.5:35b | 22GB | 32000 | 22GB |
|
||||||
|
| qwen3.5:27b | 17GB | 32000 | 19GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 32000 | 7.3GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 32000 | 4.2GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 32000 | 2.8GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 32000 | 695MB |
|
||||||
|
| qwen3.6:35b | 22GB | 32000 | 22GB |
|
||||||
|
| qwen3.6:27b | 17GB | 32000 | 18GB |
|
||||||
|
| qwen3.8:27b | 17GB | 32000 | 18GB |
|
||||||
|
|
||||||
|
### `ollama_sizes m 64000`
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 64000 | 18GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 64000 | 19GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 64000 | 14GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 64000 | 9.6GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 64000 | 26GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 64000 | 26GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 64000 | 25GB |
|
||||||
|
| qwen3.5:35b | 22GB | 64000 | 23GB |
|
||||||
|
| qwen3.5:27b | 17GB | 64000 | 22GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 64000 | 8.8GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 64000 | 5.6GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 64000 | 3.5GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 64000 | 999MB |
|
||||||
|
| qwen3.6:35b | 22GB | 64000 | 22GB |
|
||||||
|
| qwen3.6:27b | 17GB | 64000 | 18GB |
|
||||||
|
| qwen3.8:27b | 17GB | 64000 | 18GB |
|
||||||
|
|
||||||
|
### ollama_sizes m 80000
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 80000 | 21GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 80000 | 22GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 80000 | 17GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 80000 | 11GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 80000 | 28GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 80000 | 28GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 80000 | 27GB |
|
||||||
|
| qwen3.5:35b | 22GB | 80000 | 23GB |
|
||||||
|
| qwen3.5:27b | 17GB | 80000 | 23GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 80000 | 9.4GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 80000 | 6.2GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 80000 | 3.8GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 80000 | 1.1GB |
|
||||||
|
| qwen3.6:35b | 22GB | 80000 | 22GB |
|
||||||
|
| qwen3.6:27b | 17GB | 80000 | 18GB |
|
||||||
|
| qwen3.8:27b | 17GB | 80000 | 18GB |
|
||||||
|
|
||||||
|
### ollama_sizes m 96000
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 96000 | 23GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 96000 | 25GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 96000 | 19GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 96000 | 13GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 96000 | 31GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 96000 | 31GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 96000 | 28GB |
|
||||||
|
| qwen3.5:35b | 22GB | 96000 | 24GB |
|
||||||
|
| qwen3.5:27b | 17GB | 96000 | 24GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 96000 | 9.9GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 96000 | 6.8GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 96000 | 4.1GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 96000 | 1.2GB |
|
||||||
|
| qwen3.6:35b | 22GB | 96000 | 22GB |
|
||||||
|
| qwen3.6:27b | 17GB | 96000 | 18GB |
|
||||||
|
| qwen3.8:27b | 17GB | 96000 | 18GB |
|
||||||
|
|
||||||
|
### ollama_sizes m 128000
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 128000 | 29GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 128000 | 30GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 128000 | 24GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 128000 | 16GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 128000 | 36GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 128000 | 36GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 128000 | 32GB |
|
||||||
|
| qwen3.5:35b | 22GB | 128000 | 24GB |
|
||||||
|
| qwen3.5:27b | 17GB | 128000 | 26GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 128000 | 11GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 128000 | 8.0GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 128000 | 4.6GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 128000 | 1.4GB |
|
||||||
|
| qwen3.6:35b | 22GB | 128000 | 23GB |
|
||||||
|
| qwen3.6:27b | 17GB | 128000 | 19GB |
|
||||||
|
| qwen3.8:27b | 17GB | 128000 | 19GB |
|
||||||
|
|
||||||
|
### ollama_sizes m 160000
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 160000 | 34GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 160000 | 35GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 160000 | 28GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 160000 | 20GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 131072 | 37GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 160000 | 42GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 160000 | 35GB |
|
||||||
|
| qwen3.5:35b | 22GB | 160000 | 25GB |
|
||||||
|
| qwen3.5:27b | 17GB | 160000 | 28GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 160000 | 12GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 160000 | 9.2GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 160000 | 5.1GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 160000 | 1.6GB |
|
||||||
|
| qwen3.6:35b | 22GB | 160000 | 23GB |
|
||||||
|
| qwen3.6:27b | 17GB | 160000 | 19GB |
|
||||||
|
| qwen3.8:27b | 17GB | 160000 | 19GB |
|
||||||
|
|
||||||
|
### ollama_sizes m 192000
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 192000 | 39GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 192000 | 41GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 192000 | 33GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 192000 | 23GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 131072 | 37GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 192000 | 47GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 192000 | 38GB |
|
||||||
|
| qwen3.5:35b | 22GB | 192000 | 26GB |
|
||||||
|
| qwen3.5:27b | 17GB | 192000 | 30GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 192000 | 13GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 192000 | 10GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 192000 | 5.6GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 192000 | 1.8GB |
|
||||||
|
| qwen3.6:35b | 22GB | 192000 | 23GB |
|
||||||
|
| qwen3.6:27b | 17GB | 192000 | 19GB |
|
||||||
|
| qwen3.8:27b | 17GB | 192000 | 19GB |
|
||||||
|
|
||||||
|
### ollama_sizes m 224000
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 224000 | 45GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 224000 | 46GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 224000 | 37GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 224000 | 27GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 131072 | 37GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 224000 | 53GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 224000 | 41GB |
|
||||||
|
| qwen3.5:35b | 22GB | 224000 | 27GB |
|
||||||
|
| qwen3.5:27b | 17GB | 224000 | 33GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 224000 | 14GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 224000 | 11GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 224000 | 6.2GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 224000 | 2.0GB |
|
||||||
|
| qwen3.6:35b | 22GB | 224000 | 23GB |
|
||||||
|
| qwen3.6:27b | 17GB | 224000 | 19GB |
|
||||||
|
| qwen3.8:27b | 17GB | 224000 | 19GB |
|
||||||
|
|
||||||
|
### `ollama_sizes m 256000`
|
||||||
|
|
||||||
|
| Model Name | HDD (ls) | Context | RAM (ps) |
|
||||||
|
| :------------------------ | -----------: | -------: | -----------: |
|
||||||
|
| mistral-nemo:12b | 7.1GB | 256000 | 50GB |
|
||||||
|
| ministral-3:14b | 9.1GB | 256000 | 51GB |
|
||||||
|
| ministral-3:8b | 6.0GB | 256000 | 42GB |
|
||||||
|
| ministral-3:3b | 3.0GB | 256000 | 30GB |
|
||||||
|
| mistral-small3.2:24b | 15GB | 131072 | 37GB |
|
||||||
|
| mistral:7b | 4.4GB | 32768 | 9.0GB |
|
||||||
|
| codestral:22b | 12GB | 32768 | 20GB |
|
||||||
|
| devstral-small-2:24b | 15GB | 256000 | 58GB |
|
||||||
|
| qwen2.5-coder:32b | 19GB | 32768 | 28GB |
|
||||||
|
| qwen2.5-coder:14b | 9.0GB | 32768 | 15GB |
|
||||||
|
| qwen2.5-coder:7b | 4.7GB | 32768 | 6.9GB |
|
||||||
|
| qwen2.5-coder:3b | 1.9GB | 32768 | 3.4GB |
|
||||||
|
| qwen2.5-coder:1.5b | 986MB | 32768 | 2.1GB |
|
||||||
|
| qwen2.5-coder:0.5b | 397MB | 32768 | 940MB |
|
||||||
|
| qwen3-coder:30b | 18GB | 256000 | 45GB |
|
||||||
|
| qwen3.5:35b | 22GB | 256000 | 28GB |
|
||||||
|
| qwen3.5:27b | 17GB | 256000 | 35GB |
|
||||||
|
| qwen3.5:9b | 6.6GB | 256000 | 15GB |
|
||||||
|
| qwen3.5:4b | 3.3GB | 256000 | 12GB |
|
||||||
|
| qwen3.5:2b | 2.7GB | 256000 | 6.7GB |
|
||||||
|
| qwen3.5:0.8b | 1.3GB | 256000 | 2.2GB |
|
||||||
|
| qwen3.6:35b | 22GB | 256000 | 23GB |
|
||||||
|
| qwen3.6:27b | 17GB | 256000 | 20GB |
|
||||||
|
| qwen3.8:27b | 17GB | 256000 | 20GB |
|
||||||
File diff suppressed because it is too large.
Load diff
@@ -0,0 +1,496 @@
|
|||||||
|
---
|
||||||
|
# Move the plays related to AGENTS.md to its own file since it is now so large.
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | AI | Sandbox | Dir
|
||||||
|
ansible.builtin.file:
|
||||||
|
dest: "{{ user_user.home }}/AI-Sandbox"
|
||||||
|
state: directory
|
||||||
|
owner: "{{ user }}"
|
||||||
|
group: "{{ user }}"
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | AI | Sandbox | Env
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ user_user.home }}/AI-Sandbox/{{ item }}"
|
||||||
|
marker: "# {mark} | MANAGE BY ANSIBLE | Env Vars"
|
||||||
|
content: |
|
||||||
|
if [[ -d "$HOME/bin" ]]; then
|
||||||
|
export PATH="$HOME/bin:$PATH"
|
||||||
|
fi
|
||||||
|
|
||||||
|
export ANDROID_HOME="{{ user_user.home }}/SDKs/Android/Sdk"
|
||||||
|
export GRADLE_USER_HOME={{ user_user.home }}/.gradle
|
||||||
|
export PATH="$ANDROID_HOME/platform-tools:$PATH"
|
||||||
|
export PATH="$ANDROID_HOME/cmdline-tools/latest/bin:$PATH"
|
||||||
|
|
||||||
|
export FLUTTER_HOME="{{ user_user.home }}/SDKs/Flutter/flutter"
|
||||||
|
export PUB_CACHE={{ user_user.home }}/.pub-cache
|
||||||
|
export PATH="$FLUTTER_HOME/bin:$PATH"
|
||||||
|
|
||||||
|
export JAVA_HOME="{{ user_user.home }}/SDKs/Java"
|
||||||
|
export PATH="$JAVA_HOME/bin:$PATH"
|
||||||
|
create: false
|
||||||
|
backup: false
|
||||||
|
owner: "{{ user }}"
|
||||||
|
group: "{{ user }}"
|
||||||
|
mode: "0755"
|
||||||
|
loop:
|
||||||
|
- ".bashrc"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | AI | Sandbox | AGENTS.md
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: "{{ user_user.home }}/AI-Sandbox/AGENTS.md"
|
||||||
|
content: |
|
||||||
|
# Environment
|
||||||
|
|
||||||
|
You are running in a Docker container called Open Terminal. We are
|
||||||
|
communicating via Open WebUI, also being run in a Docker
|
||||||
|
container. You are the user `user` and have been granted access to
|
||||||
|
the designer's Code and SDKs via mount at `{{ user_user.home }}`.
|
||||||
|
|
||||||
|
Host system is typically (but not always) a systemd-free distro
|
||||||
|
such as Artix or Devuan. User likes the `runit` service manager.
|
||||||
|
`elogind` is used rather than systemd's logind. Desktop is i3 and
|
||||||
|
display manager is lightdm. Servers are run on Debian and Docker
|
||||||
|
containers are typically debian:trixie-slim with a Dockerfile
|
||||||
|
called by compose.yml which adds the necessary packages, sometimes
|
||||||
|
building from source if the Debian executable is too old.
|
||||||
|
|
||||||
|
If the `$GOT_EM` environment variable is `true` then all the
|
||||||
|
necessary packages for compiling Android and Flutter were
|
||||||
|
installed. If it is `false` then they were not installed, and
|
||||||
|
compiling will fail. Please check this before trying and alert me
|
||||||
|
if they need added. If we don't have Internet, then ask me to
|
||||||
|
compile or run whatever command is needed on the host system.
|
||||||
|
|
||||||
|
# Rules
|
||||||
|
|
||||||
|
Never use any `git` subcommands that change the repo, including
|
||||||
|
but not limited to `add`, `commit`, `pull`, `push`, `branch`,
|
||||||
|
`switch`, etc. The user is who controls the respository changes.
|
||||||
|
You may use informational git subcommands such as `git status`,
|
||||||
|
and may occasionally be asked to run `git clone` type commands.
|
||||||
|
|
||||||
|
If any programs need installed in order to work on a project, we
|
||||||
|
need to document that in an `install.sh` script, as well as add it
|
||||||
|
to `~/PACKAGES.txt` so that we can ensure they stay installed.
|
||||||
|
`install.sh` scripts should be for both `apt` systems (Debian,
|
||||||
|
Ubuntu) and pacman system (Arch, Artix). using distribution
|
||||||
|
package managers is preferable over `pip` and `npm` when
|
||||||
|
possible, unless the project is actually Python or Node.js.
|
||||||
|
|
||||||
|
The user manages the `{{ user_user.home }}/SDKs` directory. Do not
|
||||||
|
modify it. Instead, ask if anything needs updated or added.
|
||||||
|
|
||||||
|
Never manually edit, modify, delete, alter, replace, etc any
|
||||||
|
files under system folders such as `/usr`. Anything under `/` is
|
||||||
|
managed by the system. If you need assistance changing anything
|
||||||
|
such as `/usr/lib/jvm`, please ask the user and halt all further
|
||||||
|
operations until you have received feedback.
|
||||||
|
|
||||||
|
# Effort
|
||||||
|
|
||||||
|
It is never okay to brute force a solution if something is not
|
||||||
|
working well. it is better to ask the user for assistance or alert
|
||||||
|
them that you've encountered blockers and then cease the process
|
||||||
|
until you've received feedback. This especially relates to when
|
||||||
|
system errors occur which are not related to the source code, such
|
||||||
|
as a compiler failing to be found or an SDK version mismatch. If
|
||||||
|
the error is with the source code though, troubleshooting and code
|
||||||
|
changes should continue until the program is compiling properly.
|
||||||
|
|
||||||
|
For CLI projects such as script languages, the final result should
|
||||||
|
always be tested both to run successfully and have the proper
|
||||||
|
output. All test cases should be analyzed and walked through,
|
||||||
|
which will help ensure all the requirements have been met.
|
||||||
|
|
||||||
|
For GUI programs (such as Android, Flutter, Kotlin Multiplatform,
|
||||||
|
Kivy, etc), the project should be tested to both compile & build
|
||||||
|
successfully and also generate the proper installation file (APK,
|
||||||
|
Linux Bundle). Once that is confirmed, the user/desginer will test
|
||||||
|
that the application meets the proper requirements.
|
||||||
|
|
||||||
|
# Preferences
|
||||||
|
|
||||||
|
You have free reign over your home directory. Feel free to
|
||||||
|
create memory files or anything else which would benefit you.
|
||||||
|
|
||||||
|
Everything we create should have both Desktop Linux and Android
|
||||||
|
in mind. Windows, MacOS, and iOS will never be compiled for, but
|
||||||
|
if we can do things in a way which makes it easy for others to
|
||||||
|
fork the project and add the support themselves, then that's best.
|
||||||
|
|
||||||
|
# Versions
|
||||||
|
|
||||||
|
These are the versions of plugins and languages we need to use.
|
||||||
|
If you know of an important upgrade from them, please let me know.
|
||||||
|
|
||||||
|
If you find that an application is already a newer version than
|
||||||
|
those listed here, that is acceptable, never attempt to downgrade
|
||||||
|
without explicitly asking the user first and having a good reason.
|
||||||
|
|
||||||
|
## Android / Flutter
|
||||||
|
|
||||||
|
- Gradle 9.8.2
|
||||||
|
- AGP 9.5.0
|
||||||
|
- Kotlin 2.4.21
|
||||||
|
- Java JDK 17
|
||||||
|
- Flutter Plugin Loader 1.0.0
|
||||||
|
- compileSdk 37
|
||||||
|
- targetSDK 37
|
||||||
|
|
||||||
|
Regardless of whether AGP bundles Kotlin, we need to specify it to
|
||||||
|
avoid things like "Your project's Kotlin version (2.2.10) is lower
|
||||||
|
than Flutter's minimum supported version of 2.2.20. Please upgrade
|
||||||
|
your Kotlin version." This is exactly why we use these versions,
|
||||||
|
plus it helps document what's actually being used over guessing.
|
||||||
|
|
||||||
|
Only the arm-v8a architecture needs included in the release
|
||||||
|
builds. x86 and others should continue to exist in the debug run.
|
||||||
|
This will help save space on local servers like Gitea and F-Droid.
|
||||||
|
If code for this does not exist, please add splitting or filtering
|
||||||
|
so that when the designer generates a signed APK it's only v8a.
|
||||||
|
|
||||||
|
Android : paths are from the project root.
|
||||||
|
Flutter : paths are under the folder `android`.
|
||||||
|
|
||||||
|
### All Android Project Types
|
||||||
|
|
||||||
|
#### ./gradle/wrapper/grade-wrapper.properties
|
||||||
|
|
||||||
|
```
|
||||||
|
distributionUrl=https\://services.gradle.org/distributions/gradle-9.8.2-bin.zip
|
||||||
|
```
|
||||||
|
|
||||||
|
#### ./settings.gradle.kts
|
||||||
|
|
||||||
|
```
|
||||||
|
id("com.android.application") version "9.5.0" apply false
|
||||||
|
id("org.jetbrains.kotlin.android") version "2.4.21" apply false
|
||||||
|
```
|
||||||
|
|
||||||
|
#### ./app/build.gradle.kts
|
||||||
|
|
||||||
|
```
|
||||||
|
compileOptions {
|
||||||
|
sourceCompatibility = JavaVersion.VERSION_17
|
||||||
|
targetCompatibility = JavaVersion.VERSION_17
|
||||||
|
}
|
||||||
|
kotlin {
|
||||||
|
compilerOptions {
|
||||||
|
jvmTarget.set(JvmTarget.JVM_17)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
Also enable minify and shrink while in there.
|
||||||
|
|
||||||
|
```
|
||||||
|
buildTypes {
|
||||||
|
getByName("release") {
|
||||||
|
...
|
||||||
|
isMinifyEnabled = true
|
||||||
|
isShrinkResources = true
|
||||||
|
proguardFiles(
|
||||||
|
getDefaultProguardFile("proguard-android-optimize.txt"),
|
||||||
|
"proguard-rules.pro"
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
### Flutter Projects
|
||||||
|
|
||||||
|
#### ./settings.gradle.kts
|
||||||
|
|
||||||
|
```
|
||||||
|
id("dev.flutter.flutter-plugin-loader") version "1.0.0"
|
||||||
|
```
|
||||||
|
|
||||||
|
### Native Kotlin Apps
|
||||||
|
|
||||||
|
These only apply to Android apps which are not Flutter, Kivy, etc.
|
||||||
|
|
||||||
|
#### Plugin Versions
|
||||||
|
|
||||||
|
##### ./gradle/libs.versions.toml
|
||||||
|
|
||||||
|
```
|
||||||
|
[versions]
|
||||||
|
agp = "9.5.0"
|
||||||
|
kotlin = "2.4.21"
|
||||||
|
coreKtx = "1.19.1"
|
||||||
|
junit = "4.13.2"
|
||||||
|
junitVersion = "1.3.0"
|
||||||
|
espressoCore = "3.7.0"
|
||||||
|
lifecycleRuntimeKtx = "2.11.0"
|
||||||
|
activityCompose = "1.13.0"
|
||||||
|
composeBom = "2026.09.00"
|
||||||
|
```
|
||||||
|
|
||||||
|
#### Kotlin Compose Fix
|
||||||
|
|
||||||
|
Also ensure Kotlin is coming from Compose and not Jetbrains.
|
||||||
|
|
||||||
|
##### ./gradle/libs.versions.toml
|
||||||
|
|
||||||
|
```
|
||||||
|
[plugins]
|
||||||
|
androidApplication = { id = "com.android.application", version.ref = "agp" }
|
||||||
|
#jetbrainsKotlinAndroid = { id = "org.jetbrains.kotlin.android", version.ref = "kotlin" }
|
||||||
|
kotlinCompose = { id = "org.jetbrains.kotlin.plugin.compose", version.ref = "kotlin" }
|
||||||
|
```
|
||||||
|
|
||||||
|
##### ./build.gradle.kts
|
||||||
|
|
||||||
|
```
|
||||||
|
plugins {
|
||||||
|
alias(libs.plugins.androidApplication) apply false
|
||||||
|
//alias(libs.plugins.jetbrainsKotlinAndroid) apply false
|
||||||
|
alias(libs.plugins.kotlinCompose) apply false
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
##### ./app/build.gradle.kts
|
||||||
|
|
||||||
|
```
|
||||||
|
plugins {
|
||||||
|
alias(libs.plugins.androidApplication)
|
||||||
|
//alias(libs.plugins.jetbrainsKotlinAndroid)
|
||||||
|
alias(libs.plugins.kotlinCompose)
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
# Build Processes
|
||||||
|
|
||||||
|
How to compile certain projects. Tools to prefer. If a language
|
||||||
|
or framework is not mentioned, then use the typical commands.
|
||||||
|
|
||||||
|
## Kotlin Multiplatform (KMP)
|
||||||
|
|
||||||
|
Used to create small native Android apps with the ability to also
|
||||||
|
run against Desktop Linux. APK size is the greatest benefit for
|
||||||
|
using KMP over something like Flutter or KivyMD.
|
||||||
|
|
||||||
|
### Kotlin Toolchain
|
||||||
|
|
||||||
|
This is the preferred build type when setting up new projects.
|
||||||
|
|
||||||
|
Please use `kotlin` rather than any `amper` commands. `amper` has
|
||||||
|
been deprecated and is intentionally not present on the system.
|
||||||
|
Examples:
|
||||||
|
|
||||||
|
```
|
||||||
|
# 1. Compile + link ALL targets (JVM, iOS, Android, native, etc.)
|
||||||
|
./kotlin build
|
||||||
|
|
||||||
|
# 2. (Optional) Run tests across all targets
|
||||||
|
./kotlin test
|
||||||
|
|
||||||
|
# 3. (Optional) Run all quality checks (tests + registered linters)
|
||||||
|
./kotlin check
|
||||||
|
```
|
||||||
|
|
||||||
|
### Gradle KMP
|
||||||
|
|
||||||
|
This is a legacy method, new projects will not be set up with it.
|
||||||
|
Examples:
|
||||||
|
|
||||||
|
```
|
||||||
|
# Compile all targets
|
||||||
|
./gradlew assemble
|
||||||
|
|
||||||
|
# Or more explicitly (if you want to be sure nothing is skipped):
|
||||||
|
./gradlew jvmJar assembleDebug assembleIosSimulatorArm64 # etc. per target
|
||||||
|
|
||||||
|
# Run all tests
|
||||||
|
./gradlew allTests
|
||||||
|
```
|
||||||
|
|
||||||
|
# Coding Conventions
|
||||||
|
|
||||||
|
Preferences related to how code should be written.
|
||||||
|
|
||||||
|
## All languages
|
||||||
|
|
||||||
|
If a value is going to be used more than once, even a small path or file
|
||||||
|
name, it should exist in a variable.
|
||||||
|
|
||||||
|
Relative shebangs such as `#!/usr/bin/env bash` and `#!/usr/bin/env node`
|
||||||
|
are always preferred over static shebangs such as `#!/bin/bash`, since
|
||||||
|
scripts are run across a multitude of different systems.
|
||||||
|
|
||||||
|
### Layout
|
||||||
|
|
||||||
|
Programs should be laid out in 5 sections.
|
||||||
|
|
||||||
|
- Variables
|
||||||
|
- Instantiate global variables and defaults used for parameters which
|
||||||
|
do not get passed an explicit value by the user.
|
||||||
|
- Functions
|
||||||
|
- Functions to be used throughout the program, including the Usage.
|
||||||
|
- Parameters / Validation
|
||||||
|
- Parse the parameters, validate the input, and assign any defaults.
|
||||||
|
- Main
|
||||||
|
- The primary logic of the program, completes the task at hand.
|
||||||
|
- Finish / Cleanup
|
||||||
|
- Typically just `exit 0`, but sometimes a summary of what was done.
|
||||||
|
|
||||||
|
All sections may not always apply, such as with Hugo websites. With
|
||||||
|
projects like Android apps this would apply to each individual function,
|
||||||
|
method, and class. If a section does not need anything, it can be blank.
|
||||||
|
|
||||||
|
```
|
||||||
|
public static void doThing(String thingName) {
|
||||||
|
// Variables //
|
||||||
|
String thingPrefix = "/place/for/thing/"
|
||||||
|
|
||||||
|
// Functions //
|
||||||
|
|
||||||
|
// Parameters //
|
||||||
|
if (thingName.isEmpty) {
|
||||||
|
Exception e = new Exception("No name passed!");
|
||||||
|
throw e;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Main //
|
||||||
|
runStuff(thingPrefix + thingName);
|
||||||
|
|
||||||
|
// Finish //
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
The comments do not need to be included, this example is just as valid,
|
||||||
|
what maytters most is that the 5 section are done in order rather than
|
||||||
|
instantiating variable mid-scope.
|
||||||
|
|
||||||
|
```
|
||||||
|
public static void doThing(String thingName) {
|
||||||
|
String thingPrefix = "/place/for/thing/"
|
||||||
|
|
||||||
|
if (thingName.isEmpty) {
|
||||||
|
Exception e = new Exception("No name passed!");
|
||||||
|
throw e;
|
||||||
|
}
|
||||||
|
|
||||||
|
runStuff(thingPrefix + thingName);
|
||||||
|
}
|
||||||
|
```
|
||||||
|
|
||||||
|
`if` statements and loops start new scope, so they also need the layout
|
||||||
|
applied to them. Loops may sometimes require a variable assignment before
|
||||||
|
it begins which is completely okay and does not break the layout rule.
|
||||||
|
This example has a Variables, Validation, Main, and Finish section without
|
||||||
|
the use of labels or comments since the code itself is simple and small.
|
||||||
|
|
||||||
|
```
|
||||||
|
count=0
|
||||||
|
array="cats dogs giraffes rhinos horses"
|
||||||
|
last_animal=""
|
||||||
|
for animal in $array; do
|
||||||
|
if (( count >= 3 )); then
|
||||||
|
echo "That's enough! We finished at the ${last_animal}."
|
||||||
|
break;
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "We're looking at ${animal}."
|
||||||
|
|
||||||
|
last_animal=$animal
|
||||||
|
(( count++ ))
|
||||||
|
done
|
||||||
|
```
|
||||||
|
|
||||||
|
Providing the user's input in error messages is really helpful and can aid
|
||||||
|
their troubleshooting if things are not going according to expectations.
|
||||||
|
|
||||||
|
Example using Bash:
|
||||||
|
|
||||||
|
```
|
||||||
|
#!/usr/bin/env bash
|
||||||
|
|
||||||
|
### Variables ###
|
||||||
|
|
||||||
|
declare A B
|
||||||
|
typeset -i a b
|
||||||
|
|
||||||
|
### Functions ###
|
||||||
|
|
||||||
|
function usage() {
|
||||||
|
status="$1"
|
||||||
|
cat << EOF
|
||||||
|
Usage: add.sh -a NUM -b NUM [-h]
|
||||||
|
|
||||||
|
Adds two numbers and prints out the full equation.
|
||||||
|
|
||||||
|
Example:
|
||||||
|
|
||||||
|
$ add.sh -a 5 -b 25
|
||||||
|
5 + 25 = 30
|
||||||
|
EOF
|
||||||
|
exit $status
|
||||||
|
}
|
||||||
|
function add() {
|
||||||
|
num1="$1"
|
||||||
|
num2="$2"
|
||||||
|
sum=""
|
||||||
|
|
||||||
|
if [[ -z $num1 || -z $num2 ]]; then
|
||||||
|
echo "ERROR: Two numnbers must be passed."
|
||||||
|
fi
|
||||||
|
|
||||||
|
sum=$(( num1 + num2 ))
|
||||||
|
echo "${num1} + ${num2} = ${sum}"
|
||||||
|
}
|
||||||
|
|
||||||
|
### Parameters ###
|
||||||
|
|
||||||
|
while getopts ':a:b:h' opt; do
|
||||||
|
case $opt in
|
||||||
|
a) A="$OPTARG" ;;
|
||||||
|
b) B="$OPTARG" ;;
|
||||||
|
h) usage 0 ;;
|
||||||
|
*) echo "ERROR: Option $OPTARG not recognized." >&2 && usage 1 ;;
|
||||||
|
esac
|
||||||
|
done
|
||||||
|
|
||||||
|
if [[ -z "$A" || -z "$B" ]]; then
|
||||||
|
echo "ERROR: Both numbers need to be passed. A=${A} B=${B}" >&2
|
||||||
|
usage 2
|
||||||
|
fi
|
||||||
|
a="$A" b="$B"
|
||||||
|
if [[ "$a" != "$A" || "$b" != "$B" ]]; then
|
||||||
|
echo "ERROR: Values contain non-numeric data, please try again." >&2
|
||||||
|
echo "A=${A} B=${B}" >&2
|
||||||
|
usage 3
|
||||||
|
fi
|
||||||
|
|
||||||
|
### Main ###
|
||||||
|
|
||||||
|
add "$a" "$b"
|
||||||
|
|
||||||
|
### Finish ###
|
||||||
|
|
||||||
|
unset A B usage add
|
||||||
|
exit 0
|
||||||
|
```
|
||||||
|
|
||||||
|
## Bash
|
||||||
|
|
||||||
|
`[[ ]]` are preferred over `[ ]`, `test`, etc. `(( ))` are always fine.
|
||||||
|
|
||||||
|
When defining a function please use both the keyword `function` as well as
|
||||||
|
the `()`, such as `function myfunc() {}`.
|
||||||
|
|
||||||
|
When instantiating global variables, please use `typeset` or `declare`
|
||||||
|
rather than just `VAR1=""; VAR2=""`, such as:
|
||||||
|
|
||||||
|
```
|
||||||
|
declare VAR1="" VAR2="" BOOL="true" BOOL2="false"
|
||||||
|
typeset -i INT1=0 INT2=99
|
||||||
|
```
|
||||||
|
|
||||||
|
When doing colored output, `tput` is always preferred over literal values.
|
||||||
|
backup: false
|
||||||
|
owner: "{{ user }}"
|
||||||
|
group: "{{ user }}"
|
||||||
|
mode: "0755"
|
||||||
@@ -205,29 +205,29 @@
|
|||||||
- name: Workstation | Linux | Software | Android | SDK
|
- name: Workstation | Linux | Software | Android | SDK
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Download Commandline Tools
|
- name: Workstation | Linux | Software | Android | Download Commandline Tools
|
||||||
get_url:
|
ansible.builtin.get_url:
|
||||||
url: "{{ android_url }}"
|
url: "{{ android_url }}"
|
||||||
dest: "{{ android_download_file }}"
|
dest: "{{ android_download_file }}"
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
group: "{{ user }}"
|
group: "{{ user }}"
|
||||||
mode: '0664'
|
mode: '0664'
|
||||||
when: not android_download_stat.stat.exists
|
when: not android_download_stat.stat.exists
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Create Folder
|
- name: Workstation | Linux | Software | Android | Create Folder
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "{{ android_sdk_cmdline_temp }}"
|
path: "{{ android_sdk_cmdline_temp }}"
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
group: "{{ user }}"
|
group: "{{ user }}"
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Extract Tools
|
- name: Workstation | Linux | Software | Android | Extract Tools
|
||||||
unarchive:
|
ansible.builtin.unarchive:
|
||||||
src: "{{ android_download_file }}"
|
src: "{{ android_download_file }}"
|
||||||
dest: "{{ android_sdk_cmdline_temp }}"
|
dest: "{{ android_sdk_cmdline_temp }}"
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
group: "{{ user }}"
|
group: "{{ user }}"
|
||||||
|
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
@@ -243,7 +243,9 @@
|
|||||||
|
|
||||||
# This can only be run once, otherwise cmdline-tools creates latest-* folders.
|
# This can only be run once, otherwise cmdline-tools creates latest-* folders.
|
||||||
- name: Workstation | Linux | Software | Android | Install | Consistent Modules
|
- name: Workstation | Linux | Software | Android | Install | Consistent Modules
|
||||||
ansible.builtin.shell: "yes | {{ android_sdkmanager_temp }} --install '{{ item }}' --sdk_root={{ android_sdk_location }}"
|
ansible.builtin.shell: |
|
||||||
|
set -o pipefail
|
||||||
|
yes | {{ android_sdkmanager_temp }} --install '{{ item }}' --sdk_root={{ android_sdk_location }}
|
||||||
loop:
|
loop:
|
||||||
# Current
|
# Current
|
||||||
- cmdline-tools/latest
|
- cmdline-tools/latest
|
||||||
@@ -251,17 +253,28 @@
|
|||||||
- emulator
|
- emulator
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
when: coding
|
when: coding
|
||||||
and not android_sdkmanager_check.stat.exists
|
and not android_sdkmanager_check.stat.exists
|
||||||
|
|
||||||
|
# Report the preliminary installed packges.
|
||||||
|
- name: Workstation | Linux | Software | Android | Report Modules
|
||||||
|
ansible.builtin.shell: "{{ android_sdkmanager2_list }} > {{ android_report_file }}"
|
||||||
|
become: true
|
||||||
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
when: coding
|
||||||
|
|
||||||
# These are safe to run multiple times, and uses the new `latest` version.
|
# These are safe to run multiple times, and uses the new `latest` version.
|
||||||
- name: Workstation | Linux | Software | Android | Install | Required Modules
|
- name: Workstation | Linux | Software | Android | Install | Required Modules
|
||||||
ansible.builtin.shell: |
|
ansible.builtin.shell: |
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -v 'unknown' | grep -q '{{ item }}' == 1 ]]; then
|
if ! cat {{ android_report_file }} | grep -v 'unknown' | grep -q '{{ item }}'; then
|
||||||
yes | {{ android_sdkmanager2_install }} '{{ item }}'
|
yes | {{ android_sdkmanager2_install }} '{{ item }}'
|
||||||
|
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -q '{{ item }}' == 0 ]]; then
|
if cat {{ android_report_file }} | grep -q '{{ item }}'; then
|
||||||
echo "INSTALLED"
|
echo "INSTALLED"
|
||||||
else
|
else
|
||||||
echo "FAILED"
|
echo "FAILED"
|
||||||
@@ -279,10 +292,10 @@
|
|||||||
- name: Workstation | Linux | Software | Android | Install | Additional Modules
|
- name: Workstation | Linux | Software | Android | Install | Additional Modules
|
||||||
ansible.builtin.shell: |
|
ansible.builtin.shell: |
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -v 'unknown' | grep -q '{{ item }}' == 1 ]]; then
|
if ! cat {{ android_report_file }} | grep -v 'unknown' | grep -q '{{ item }}'; then
|
||||||
yes | {{ android_sdkmanager2_install }} '{{ item }}'
|
yes | {{ android_sdkmanager2_install }} '{{ item }}'
|
||||||
|
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -q '{{ item }}' == 0 ]]; then
|
if cat {{ android_report_file }} | grep -q '{{ item }}'; then
|
||||||
echo "INSTALLED"
|
echo "INSTALLED"
|
||||||
else
|
else
|
||||||
echo "FAILED"
|
echo "FAILED"
|
||||||
@@ -301,13 +314,13 @@
|
|||||||
- name: Workstation | Linux | Software | Android | Uninstall | Additional Modules
|
- name: Workstation | Linux | Software | Android | Uninstall | Additional Modules
|
||||||
ansible.builtin.shell: |
|
ansible.builtin.shell: |
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -q '{{ item }}' == 0 ]]; then
|
if cat {{ android_report_file }} | grep -q '{{ item }}'; then
|
||||||
yes | {{ android_sdkmanager2_remove }} '{{ item }}'
|
yes | {{ android_sdkmanager2_remove }} '{{ item }}'
|
||||||
|
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -q '{{ item }}' == 1 ]]; then
|
if cat {{ android_report_file }} | grep -q '{{ item }}'; then
|
||||||
echo "REMOVED"
|
|
||||||
else
|
|
||||||
echo "FAILED"
|
echo "FAILED"
|
||||||
|
else
|
||||||
|
echo "REMOVED"
|
||||||
fi
|
fi
|
||||||
fi
|
fi
|
||||||
loop: "{{ android_downloads_additional }}"
|
loop: "{{ android_downloads_additional }}"
|
||||||
@@ -323,10 +336,10 @@
|
|||||||
- name: Workstation | Linux | Software | Android | Uninstall | Unused Modules
|
- name: Workstation | Linux | Software | Android | Uninstall | Unused Modules
|
||||||
ansible.builtin.shell: |
|
ansible.builtin.shell: |
|
||||||
set -o pipefail
|
set -o pipefail
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -q '{{ item }}' == 0 ]]; then
|
if cat {{ android_report_file }} | grep -q '{{ item }}'; then
|
||||||
yes | {{ android_sdkmanager2_remove }} '{{ item }}'
|
yes | {{ android_sdkmanager2_remove }} '{{ item }}'
|
||||||
|
|
||||||
if [[ {{ android_sdkmanager2_list }} | grep -q '{{ item }}' == 1 ]]; then
|
if cat {{ android_report_file }} | grep -q '{{ item }}'; then
|
||||||
echo "REMOVED"
|
echo "REMOVED"
|
||||||
else
|
else
|
||||||
echo "FAILED"
|
echo "FAILED"
|
||||||
@@ -340,31 +353,47 @@
|
|||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
# Report the currently installed packges.
|
# Report the currently installed packages.
|
||||||
- name: Workstation | Linux | Software | Android | Report Modules
|
- name: Workstation | Linux | Software | Android | Report Modules
|
||||||
ansible.builtin.shell: "{{ android_sdkmanager2_list }} --all > {{ android_report_file }}"
|
ansible.builtin.shell: "{{ android_sdkmanager2_list }} --all > {{ android_report_file }}"
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
## Flutter and Licenses ##
|
## Flutter and Licenses ##
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Inform Flutter
|
- name: Workstation | Linux | Software | Android | Inform Flutter
|
||||||
ansible.builtin.shell: "{{ flutter }} config --android-sdk={{ android_sdk_location }}"
|
ansible.builtin.shell: "{{ flutter_exe }} config --android-sdk={{ android_sdk_location }}"
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
|
# "Warning: The --licenses option is no longer needed."
|
||||||
- name: Workstation | Linux | Software | Android | License Agreements [1/2]
|
- name: Workstation | Linux | Software | Android | License Agreements [1/2]
|
||||||
ansible.builtin.shell: "yes | {{ android_sdkmanager_final }} --licenses --sdk_root={{ android_sdk_location }}"
|
ansible.builtin.shell: |
|
||||||
|
set -o pipefail
|
||||||
|
yes | {{ android_sdkmanager_final }} --licenses --sdk_root={{ android_sdk_location }}
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
failed_when: false
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
|
# "Warning: The --licenses option is no longer needed."
|
||||||
- name: Workstation | Linux | Software | Android | License Agreements [2/2]
|
- name: Workstation | Linux | Software | Android | License Agreements [2/2]
|
||||||
ansible.builtin.shell: "yes | {{ flutter }} doctor --android-licenses"
|
ansible.builtin.shell: |
|
||||||
|
set -o pipefail
|
||||||
|
yes | {{ flutter_exe }} doctor --android-licenses
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
failed_when: false
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Refresh Flutter Doctor Report
|
- name: Workstation | Linux | Software | Android | Refresh Flutter Doctor Report
|
||||||
@@ -372,42 +401,29 @@
|
|||||||
loop: "{{ flutter_report_commands }}"
|
loop: "{{ flutter_report_commands }}"
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
## Configure Environment ##
|
## Configure Environment ##
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Modify PATH (.bashrc)
|
- name: Workstation | Linux | Software | Android | Modify PATH (profiles)
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
path: "{{ item }}/.bashrc"
|
path: "{{ user_user.home }}/{{ item }}"
|
||||||
block: |
|
block: |
|
||||||
export PATH="$PATH:{{ android_bin_location }}:{{ android_sdk_cmdline_final }}"
|
export ANDROID_HOME="{{ android_sdk_location | replace('~', '$HOME') }}"
|
||||||
|
export ANDROID_SDK_ROOT="$ANDROID_HOME"
|
||||||
|
export PATH="{{ android_bin_location }}:{{ android_sdk_cmdline_final }}:$PATH"
|
||||||
marker: '# {mark} MANAGED BY ANSIBLE | Android'
|
marker: '# {mark} MANAGED BY ANSIBLE | Android'
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0755"
|
||||||
loop:
|
loop:
|
||||||
- "{{ user_root.home }}"
|
- ".bash_profile"
|
||||||
- "{{ user_user.home }}"
|
- ".zprofile"
|
||||||
ignore_errors: true
|
- ".profile"
|
||||||
when: coding
|
when: coding
|
||||||
and user_root.home != ""
|
|
||||||
and user_user.home != ""
|
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Android | Modify PATH (.zshrc)
|
|
||||||
ansible.builtin.blockinfile:
|
|
||||||
path: "{{ item }}/.zshrc"
|
|
||||||
block: |
|
|
||||||
export PATH="$PATH:{{ android_bin_location }}:{{ android_sdk_cmdline_final }}"
|
|
||||||
marker: '# {mark} MANAGED BY ANSIBLE | Android'
|
|
||||||
state: present
|
|
||||||
create: true
|
|
||||||
backup: true
|
|
||||||
loop:
|
|
||||||
- "{{ user_root.home }}"
|
|
||||||
- "{{ user_user.home }}"
|
|
||||||
ignore_errors: true
|
|
||||||
when: coding
|
|
||||||
and user_root.home != ""
|
|
||||||
and user_user.home != ""
|
and user_user.home != ""
|
||||||
|
|
||||||
## Uninstall SDK ##
|
## Uninstall SDK ##
|
||||||
|
|||||||
@@ -21,4 +21,3 @@
|
|||||||
- "{{ cinnamon_package }}"
|
- "{{ cinnamon_package }}"
|
||||||
- "{{ lightdm }}"
|
- "{{ lightdm }}"
|
||||||
state: present
|
state: present
|
||||||
update_cache: true
|
|
||||||
@@ -0,0 +1,116 @@
|
|||||||
|
# 2026-10-27 Hyperling
|
||||||
|
# Pulled out of llm.yml since the number of tasks is growing.
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Install
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- docker
|
||||||
|
- docker-compose
|
||||||
|
- docker-buildx
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Install [runit]
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- docker-runit
|
||||||
|
state: present
|
||||||
|
when: ansible_pkg_mgr == "pacman"
|
||||||
|
and ansible_service_mgr == "runit"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Group
|
||||||
|
ansible.builtin.user:
|
||||||
|
name: "{{ item }}"
|
||||||
|
groups: docker
|
||||||
|
append: true
|
||||||
|
loop:
|
||||||
|
- root
|
||||||
|
- "{{ user }}"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Config | Dir
|
||||||
|
ansible.builtin.file:
|
||||||
|
name: /etc/docker
|
||||||
|
state: directory
|
||||||
|
owner: root
|
||||||
|
mode: '0755'
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Socker | Services | Enable
|
||||||
|
ansible.builtin.service:
|
||||||
|
name: "{{ item.name }}"
|
||||||
|
state: "{{ 'started' if item.status else 'stopped' }}"
|
||||||
|
enabled: "{{ item.status }}"
|
||||||
|
loop:
|
||||||
|
- { 'name': 'docker' , 'status': true }
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | Facts
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
docker_network_sync: "docker-network-sync"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | Block
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | /etc/sv
|
||||||
|
ansible.builtin.file:
|
||||||
|
name: "/etc/sv/{{ docker_network_sync }}/log"
|
||||||
|
state: directory
|
||||||
|
owner: root
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | /var/log
|
||||||
|
ansible.builtin.file:
|
||||||
|
name: "/var/log/{{ docker_network_sync }}"
|
||||||
|
state: directory
|
||||||
|
owner: "{{ user }}"
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | Run
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/sv/{{ docker_network_sync }}/run
|
||||||
|
content: |
|
||||||
|
#!/bin/sh
|
||||||
|
# Ensure all containers using host network keep a correct resolv.conf.
|
||||||
|
exec 2>&1
|
||||||
|
set -e
|
||||||
|
|
||||||
|
while true; do
|
||||||
|
for c in $(docker container ls --filter network=host -q); do
|
||||||
|
echo "RUN: Container ID $c"
|
||||||
|
docker exec -i -u root $c sh -c 'tee /etc/resolv.conf' < /etc/resolv.conf
|
||||||
|
done
|
||||||
|
echo "RUN: Done, sleeping."
|
||||||
|
sleep 20
|
||||||
|
done
|
||||||
|
backup: false
|
||||||
|
owner: root
|
||||||
|
mode: '0755'
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | Finish
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/sv/{{ docker_network_sync }}/finish
|
||||||
|
content: |
|
||||||
|
{{ runit_finish_sleep }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | Log
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /etc/sv/{{ docker_network_sync }}/log/run
|
||||||
|
content: |
|
||||||
|
#!/bin/sh -e
|
||||||
|
exec svlogd -tt /var/log/{{ docker_network_sync }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Docker | Network Sync | runit | Log Config
|
||||||
|
ansible.builtin.copy:
|
||||||
|
dest: /var/log/{{ docker_network_sync }}/config
|
||||||
|
content: |
|
||||||
|
{{ runit_log_config_1mb }}
|
||||||
|
mode: "0755"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Socker | Services | Enable
|
||||||
|
ansible.builtin.service:
|
||||||
|
name: "{{ item.name }}"
|
||||||
|
state: "{{ 'started' if item.status else 'stopped' }}"
|
||||||
|
enabled: "{{ item.status }}"
|
||||||
|
loop:
|
||||||
|
- { 'name': '{{ docker_network_sync }}', 'status': true }
|
||||||
|
|
||||||
|
when: ansible_service_mgr == "runit"
|
||||||
@@ -19,7 +19,6 @@
|
|||||||
- name: Workstation | Linux | Flatpak Distro | Flatpak | Install
|
- name: Workstation | Linux | Flatpak Distro | Flatpak | Install
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name: flatpak
|
name: flatpak
|
||||||
update_cache: true
|
|
||||||
|
|
||||||
- name: Workstation | Linux | Flatpak Distro | Flatpak | Add Flathub for System
|
- name: Workstation | Linux | Flatpak Distro | Flatpak | Add Flathub for System
|
||||||
flatpak_remote:
|
flatpak_remote:
|
||||||
|
|||||||
@@ -12,19 +12,20 @@
|
|||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Facts 2
|
- name: Workstation | Linux | Software | Flutter | Facts 2
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
flutter_bin_location: "{{ flutter_sdk_location }}/flutter/bin"
|
flutter_home: "{{ flutter_sdk_location }}/flutter"
|
||||||
|
flutter_bin: "{{ flutter_sdk_location }}/flutter/bin"
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Facts 3
|
- name: Workstation | Linux | Software | Flutter | Facts 3
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
flutter: "{{ flutter_bin_location }}/flutter"
|
flutter_exe: "{{ flutter_bin }}/flutter"
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Facts 4
|
- name: Workstation | Linux | Software | Flutter | Facts 4
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
flutter_report_commands:
|
flutter_report_commands:
|
||||||
- "date > {{ flutter_report }}"
|
- "date > {{ flutter_report }}"
|
||||||
- "{{ flutter }} --disable-analytics >> {{ flutter_report }}"
|
- "{{ flutter_exe }} --disable-analytics >> {{ flutter_report }}"
|
||||||
- "date >> {{ flutter_report }}"
|
- "date >> {{ flutter_report }}"
|
||||||
- "{{ flutter }} doctor -v >> {{ flutter_report }}"
|
- "{{ flutter_exe }} doctor -v >> {{ flutter_report }}"
|
||||||
- "date >> {{ flutter_report }}"
|
- "date >> {{ flutter_report }}"
|
||||||
|
|
||||||
## Checks ##
|
## Checks ##
|
||||||
@@ -50,13 +51,13 @@
|
|||||||
- name: Workstation | Linux | Software | Flutter | Necessities
|
- name: Workstation | Linux | Software | Flutter | Necessities
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- curl
|
- curl
|
||||||
- git
|
- git
|
||||||
- unzip
|
- unzip
|
||||||
- "{{ xz }}"
|
- "{{ xz }}"
|
||||||
- zip
|
- zip
|
||||||
- "{{ mesa }}"
|
- "{{ mesa }}"
|
||||||
- "{{ mesa_utils }}"
|
- "{{ mesa_utils }}"
|
||||||
state: present
|
state: present
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
@@ -64,14 +65,14 @@
|
|||||||
- name: Workstation | Linux | Software | Flutter | Linux App Dependencies
|
- name: Workstation | Linux | Software | Flutter | Linux App Dependencies
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- clang
|
- clang
|
||||||
- cmake
|
- cmake
|
||||||
- git
|
- git
|
||||||
- "{{ ninja }}"
|
- "{{ ninja }}"
|
||||||
- pkg-config
|
- pkg-config
|
||||||
- "{{ gtk3 }}"
|
- "{{ gtk3 }}"
|
||||||
- "{{ xz_libs }}"
|
- "{{ xz_libs }}"
|
||||||
- "{{ cpp }}"
|
- "{{ cpp }}"
|
||||||
state: present
|
state: present
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
@@ -91,29 +92,29 @@
|
|||||||
- name: Workstation | Linux | Software | Flutter | SDK
|
- name: Workstation | Linux | Software | Flutter | SDK
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Download SDK
|
- name: Workstation | Linux | Software | Flutter | Download SDK
|
||||||
get_url:
|
ansible.builtin.get_url:
|
||||||
url: "{{ flutter_url }}"
|
url: "{{ flutter_url }}"
|
||||||
dest: "{{ flutter_download_file }}"
|
dest: "{{ flutter_download_file }}"
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
group: "{{ user }}"
|
group: "{{ user }}"
|
||||||
mode: '0664'
|
mode: '0664'
|
||||||
when: not flutter_download_stat.stat.exists
|
when: not flutter_download_stat.stat.exists
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Create Folder
|
- name: Workstation | Linux | Software | Flutter | Create Folder
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
path: "{{ flutter_sdk_location }}"
|
path: "{{ flutter_sdk_location }}"
|
||||||
state: directory
|
state: directory
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
group: "{{ user }}"
|
group: "{{ user }}"
|
||||||
mode: '0755'
|
mode: '0755'
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Extract SDK
|
- name: Workstation | Linux | Software | Flutter | Extract SDK
|
||||||
unarchive:
|
ansible.builtin.unarchive:
|
||||||
src: "{{ flutter_download_file }}"
|
src: "{{ flutter_download_file }}"
|
||||||
dest: "{{ flutter_sdk_location }}"
|
dest: "{{ flutter_sdk_location }}"
|
||||||
owner: "{{ user }}"
|
owner: "{{ user }}"
|
||||||
group: "{{ user }}"
|
group: "{{ user }}"
|
||||||
|
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
@@ -128,38 +129,22 @@
|
|||||||
|
|
||||||
## Configure Environment ##
|
## Configure Environment ##
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Modify PATH (.bashrc)
|
- name: Workstation | Linux | Software | Flutter | Modify PATH (profiles)
|
||||||
ansible.builtin.blockinfile:
|
ansible.builtin.blockinfile:
|
||||||
path: "{{ item }}/.bashrc"
|
path: "{{ user_user.home }}/{{ item }}"
|
||||||
block: |
|
block: |
|
||||||
export PATH="$PATH:{{ flutter_bin_location }}"
|
export FLUTTER_HOME="{{ flutter_home }}"
|
||||||
|
export PATH="{{ flutter_bin }}:$PATH"
|
||||||
marker: '# {mark} MANAGED BY ANSIBLE | Flutter'
|
marker: '# {mark} MANAGED BY ANSIBLE | Flutter'
|
||||||
state: present
|
state: present
|
||||||
create: true
|
create: true
|
||||||
backup: true
|
backup: true
|
||||||
|
mode: "0755"
|
||||||
loop:
|
loop:
|
||||||
- "{{ user_root.home }}"
|
- ".bash_profile"
|
||||||
- "{{ user_user.home }}"
|
- ".zprofile"
|
||||||
ignore_errors: true
|
- ".profile"
|
||||||
when: coding
|
when: coding
|
||||||
and user_root.home != ""
|
|
||||||
and user_user.home != ""
|
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Flutter | Modify PATH (.zshrc)
|
|
||||||
ansible.builtin.blockinfile:
|
|
||||||
path: "{{ item }}/.zshrc"
|
|
||||||
block: |
|
|
||||||
export PATH="$PATH:{{ flutter_bin_location }}"
|
|
||||||
marker: '# {mark} MANAGED BY ANSIBLE | Flutter'
|
|
||||||
state: present
|
|
||||||
create: true
|
|
||||||
backup: true
|
|
||||||
loop:
|
|
||||||
- "{{ user_root.home }}"
|
|
||||||
- "{{ user_user.home }}"
|
|
||||||
ignore_errors: true
|
|
||||||
when: coding
|
|
||||||
and user_root.home != ""
|
|
||||||
and user_user.home != ""
|
and user_user.home != ""
|
||||||
|
|
||||||
## Test SDK ##
|
## Test SDK ##
|
||||||
@@ -169,6 +154,8 @@
|
|||||||
loop: "{{ flutter_report_commands }}"
|
loop: "{{ flutter_report_commands }}"
|
||||||
become: true
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
when: coding
|
when: coding
|
||||||
|
|
||||||
## Uninstall SDK ##
|
## Uninstall SDK ##
|
||||||
|
|||||||
@@ -5,52 +5,73 @@
|
|||||||
- name: Workstation | Linux | Software | Hugo
|
- name: Workstation | Linux | Software | Hugo
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | pacman
|
- name: Workstation | Linux | Software | Hugo | pacman
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | pacman | Facts
|
- name: Workstation | Linux | Software | Hugo | pacman | Facts
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
sass_old: ruby-sass
|
sass_old: ruby-sass
|
||||||
sass_current: dart-sass
|
sass_current: dart-sass
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | pacman | Remove Old
|
- name: Workstation | Linux | Software | Hugo | pacman | Remove Old
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- "{{ sass_old }}"
|
- "{{ sass_old }}"
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | pacman | Install New
|
- name: Workstation | Linux | Software | Hugo | pacman | Install New
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- "{{ sass_current }}"
|
- hugo
|
||||||
state: present
|
- "{{ sass_current }}"
|
||||||
|
state: present
|
||||||
|
|
||||||
when: ansible_pkg_mgr == "pacman"
|
when: ansible_pkg_mgr == "pacman"
|
||||||
|
|
||||||
# This must exist after nodejs.yml so that NPM is installed.
|
# This must exist after nodejs.yml so that NPM is installed.
|
||||||
- name: Workstation | Linux | Software | Hugo | npm
|
- name: Workstation | Linux | Software | Hugo | apt
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | npm | Facts
|
- name: Workstation | Linux | Software | Hugo | apt | sass | Facts
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
sass_old: node-sass
|
sass_old: node-sass
|
||||||
sass_current: sass
|
sass_current: sass
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | npm | Gather
|
- name: Workstation | Linux | Software | Hugo | apt | sass | Gather
|
||||||
ansible.builtin.shell: npm prefix -g
|
ansible.builtin.shell: npm prefix -g
|
||||||
register: npm_bin_dir # Provides /usr/local/ on Devuan, /usr/ on Artix.
|
register: npm_bin_dir # Provides /usr/local/ on Devuan, /usr/ on Artix.
|
||||||
changed_when: false
|
changed_when: false
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | npm | Remove Old
|
- name: Workstation | Linux | Software | Hugo | apt | sass | Remove Old
|
||||||
ansible.builtin.shell: "npm remove -g {{ sass_old }}"
|
ansible.builtin.shell: "npm remove -g {{ sass_old }}"
|
||||||
args:
|
args:
|
||||||
creates: "{{ npm_bin_dir.stdout }}/bin/sass"
|
creates: "{{ npm_bin_dir.stdout }}/bin/sass"
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Hugo | npm | Install New
|
- name: Workstation | Linux | Software | Hugo | apt | sass | Install New
|
||||||
ansible.builtin.shell: "npm install -g {{ sass_current }}"
|
ansible.builtin.shell: "npm install -g {{ sass_current }}"
|
||||||
args:
|
args:
|
||||||
creates: "{{ npm_bin_dir.stdout }}/bin/sass"
|
creates: "{{ npm_bin_dir.stdout }}/bin/sass"
|
||||||
|
|
||||||
when: ansible_pkg_mgr == "apt"
|
- name: Workstation | Linux | Software | Hugo | apt | hugo | Remove Old
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- hugo
|
||||||
|
state: absent
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Hugo | apt | hugo | Install Dependencies
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- golang
|
||||||
|
- gcc
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Hugo | apt | hugo | Build
|
||||||
|
ansible.builtin.shell: |
|
||||||
|
CGO_ENABLED=1 go install -tags extended github.com/gohugoio/hugo@latest
|
||||||
|
ln -s $HOME/go/bin/hugo /usr/local/bin/hugo
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
when: coding is true
|
when: coding is true
|
||||||
@@ -2,34 +2,77 @@
|
|||||||
# 20260912 - Hyperling
|
# 20260912 - Hyperling
|
||||||
# Arch has too new of Java for Android / Gradle to even run AGP Assistant on.
|
# Arch has too new of Java for Android / Gradle to even run AGP Assistant on.
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Java | Facts 1
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
jdk_version: 17
|
||||||
|
jdk_jvm: /usr/lib/jvm
|
||||||
|
jdk_src: /usr/lib/jvm/default-java
|
||||||
|
jdk_dir: "{{ user_user.home}}/SDKs/Java"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Java | Facts 2
|
||||||
|
ansible.builtin.set_fact:
|
||||||
|
jdk_path: "{{ jdk_dir }}/bin"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Java | apt
|
||||||
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- "default-jdk"
|
||||||
|
state: present
|
||||||
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Java | pacman
|
- name: Workstation | Linux | Software | Java | pacman
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Java | pacman | Facts
|
- name: Workstation | Linux | Software | Java | pacman | Facts
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
jdk_version: 21
|
jdk_src: /usr/lib/jvm/default
|
||||||
jdk_dir: ~/SDKs/Java
|
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Java | pacman | Install
|
- name: Workstation | Linux | Software | Java | pacman | Install [base]
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- "jdk{{ item }}-openjdk"
|
- "jdk{{ jdk_version }}-openjdk"
|
||||||
state: present
|
state: present
|
||||||
loop:
|
|
||||||
- "{{ jdk_version }}"
|
|
||||||
- 25
|
|
||||||
- 21
|
|
||||||
- 17
|
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Java | pacman | Set
|
- name: Workstation | Linux | Software | Java | pacman | Install [all]
|
||||||
ansible.builtin.shell: "archlinux-java set java-{{ jdk_version }}-openjdk"
|
ansible.builtin.package:
|
||||||
|
name:
|
||||||
|
- "jdk{{ item }}-openjdk"
|
||||||
|
state: present
|
||||||
|
loop:
|
||||||
|
- 25
|
||||||
|
- 21
|
||||||
|
- 17
|
||||||
|
when: coding
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Java | pacman | Link
|
- name: Workstation | Linux | Software | Java | pacman | Set
|
||||||
ansible.builtin.shell: "ln -sf /usr/lib/jvm {{ jdk_dir }}"
|
ansible.builtin.shell: "archlinux-java set java-{{ jdk_version }}-openjdk"
|
||||||
args:
|
register: shell_check
|
||||||
creates: "{{ jdk_dir }}"
|
changed_when: shell_check.rc == 0
|
||||||
become: true
|
|
||||||
become_user: "{{ user }}"
|
|
||||||
|
|
||||||
when: coding is true
|
when: ansible_pkg_mgr == "pacman"
|
||||||
and ansible_pkg_mgr == "pacman"
|
|
||||||
|
- name: Workstation | Linux | Software | Java | pacman | Link
|
||||||
|
ansible.builtin.file:
|
||||||
|
src: "{{ jdk_src }}"
|
||||||
|
dest: "{{ jdk_dir }}"
|
||||||
|
state: link
|
||||||
|
become: true
|
||||||
|
become_user: "{{ user }}"
|
||||||
|
|
||||||
|
- name: Workstation | Linux | Software | Java | Modify PATH (profiles)
|
||||||
|
ansible.builtin.blockinfile:
|
||||||
|
path: "{{ user_user.home }}/{{ item }}"
|
||||||
|
block: |
|
||||||
|
export JAVA_HOME="{{ jdk_dir }}"
|
||||||
|
export JAVA_PATH="{{ jdk_path }}"
|
||||||
|
export PATH="$JAVA_PATH:$PATH
|
||||||
|
marker: '# {mark} MANAGED BY ANSIBLE | Java'
|
||||||
|
state: present
|
||||||
|
create: true
|
||||||
|
backup: true
|
||||||
|
mode: "0755"
|
||||||
|
loop:
|
||||||
|
- ".bash_profile"
|
||||||
|
- ".zprofile"
|
||||||
|
- ".profile"
|
||||||
|
when: user_user.home != ""
|
||||||
@@ -17,4 +17,3 @@
|
|||||||
- "{{ lxqt_package }}"
|
- "{{ lxqt_package }}"
|
||||||
- "{{ sddm }}"
|
- "{{ sddm }}"
|
||||||
state: present
|
state: present
|
||||||
update_cache: true
|
|
||||||
@@ -7,41 +7,41 @@
|
|||||||
- name: Workstation | Software | NodeJS
|
- name: Workstation | Software | NodeJS
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Software | NodeJS | apt
|
- name: Workstation | Software | NodeJS | apt
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Software | NodeJS | apt | Facts
|
- name: Workstation | Software | NodeJS | apt | Facts
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
node_version: node_24.x
|
node_version: node_24.x
|
||||||
|
|
||||||
- name: Workstation | Software | NodeJS | apt | Old | Remove
|
- name: Workstation | Software | NodeJS | apt | Old | Remove
|
||||||
|
ansible.builtin.package:
|
||||||
|
name: npm
|
||||||
|
state: absent
|
||||||
|
|
||||||
|
- name: Workstation | Software | NodeJS | apt | extrepo | Install
|
||||||
|
ansible.builtin.package:
|
||||||
|
name: extrepo
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Workstation | Software | NodeJS | apt | extrepo | Enable
|
||||||
|
ansible.builtin.shell: "extrepo enable {{ node_version }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
|
- name: Workstation | Software | NodeJS | apt | Install
|
||||||
|
ansible.builtin.package:
|
||||||
|
name: nodejs
|
||||||
|
state: present
|
||||||
|
|
||||||
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
|
||||||
|
- name: Workstation | Software | NodeJS | All Others | Install
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name: npm
|
name:
|
||||||
state: absent
|
- nodejs
|
||||||
|
- npm
|
||||||
- name: Workstation | Software | NodeJS | apt | extrepo | Install
|
|
||||||
ansible.builtin.package:
|
|
||||||
name: extrepo
|
|
||||||
state: present
|
state: present
|
||||||
update_cache: true
|
when: ansible_pkg_mgr != "apt"
|
||||||
|
|
||||||
- name: Workstation | Software | NodeJS | apt | extrepo | Enable
|
|
||||||
ansible.builtin.shell: "extrepo enable {{ node_version }}"
|
|
||||||
|
|
||||||
- name: Workstation | Software | NodeJS | apt | Install
|
|
||||||
ansible.builtin.package:
|
|
||||||
name: nodejs
|
|
||||||
state: latest
|
|
||||||
update_cache: true
|
|
||||||
|
|
||||||
when: ansible_pkg_mgr == "apt"
|
|
||||||
|
|
||||||
- name: Workstation | Software | NodeJS | All Others | Install
|
|
||||||
ansible.builtin.package:
|
|
||||||
name:
|
|
||||||
- nodejs
|
|
||||||
- npm
|
|
||||||
state: present
|
|
||||||
when: ansible_pkg_mgr != "apt"
|
|
||||||
|
|
||||||
when: coding
|
when: coding
|
||||||
@@ -14,6 +14,8 @@
|
|||||||
- "dnf install -y https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm"
|
- "dnf install -y https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm"
|
||||||
- "dnf config-manager --enable rpmfusion-nonfree"
|
- "dnf config-manager --enable rpmfusion-nonfree"
|
||||||
- "dnf config-manager --enable rpmfusion-nonfree-updates"
|
- "dnf config-manager --enable rpmfusion-nonfree-updates"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
when: ansible_distribution == "Fedora"
|
when: ansible_distribution == "Fedora"
|
||||||
|
|
||||||
|
|
||||||
@@ -50,6 +52,10 @@
|
|||||||
- "{{ transmission_qt }}"
|
- "{{ transmission_qt }}"
|
||||||
- "{{ libreoffice }}"
|
- "{{ libreoffice }}"
|
||||||
- "{{ strawberry }}"
|
- "{{ strawberry }}"
|
||||||
|
- "{{ dict_en }}"
|
||||||
|
- "{{ dict_es }}"
|
||||||
|
- "{{ xset }}"
|
||||||
|
- "{{ xlock }}"
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Packages | Install From Repo [Coding]
|
- name: Workstation | Linux | Software | Packages | Install From Repo [Coding]
|
||||||
@@ -86,6 +92,9 @@
|
|||||||
state: present
|
state: present
|
||||||
when: ansible_service_mgr != "systemd"
|
when: ansible_service_mgr != "systemd"
|
||||||
|
|
||||||
|
# TBD/TODO: Change the below AUR tasks to echo EXISTS, INSTALLED, or FAILED
|
||||||
|
# and then catch it, similar to what's done in android.yml and others.
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | Packages | Install From AUR
|
- name: Workstation | Linux | Software | Packages | Install From AUR
|
||||||
ansible.builtin.shell: "yay -Qs {{ item }} || yay --noconfirm -S {{ item }}"
|
ansible.builtin.shell: "yay -Qs {{ item }} || yay --noconfirm -S {{ item }}"
|
||||||
loop:
|
loop:
|
||||||
|
|||||||
@@ -53,7 +53,6 @@
|
|||||||
- "{{ tlp_rdw }}"
|
- "{{ tlp_rdw }}"
|
||||||
- "{{ tlp_smart }}"
|
- "{{ tlp_smart }}"
|
||||||
- "{{ tlp_run_script }}"
|
- "{{ tlp_run_script }}"
|
||||||
update_cache: true
|
|
||||||
|
|
||||||
## Configuration ##
|
## Configuration ##
|
||||||
|
|
||||||
@@ -115,7 +114,7 @@
|
|||||||
|
|
||||||
- name: Workstation | Linux | Software | TLP | runit | Devuan | Facts 02
|
- name: Workstation | Linux | Software | TLP | runit | Devuan | Facts 02
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
devuan_tlp_run: "{{ devuan_tlp_dir }}/run"
|
devuan_tlp_run: "{{ devuan_tlp_dir }}/{{ runit_service_script }}"
|
||||||
|
|
||||||
- name: Workstation | Linux | Software | TLP | runit | Devuan | Create Script
|
- name: Workstation | Linux | Software | TLP | runit | Devuan | Create Script
|
||||||
ansible.builtin.shell: "{{ item }}"
|
ansible.builtin.shell: "{{ item }}"
|
||||||
|
|||||||
@@ -4,35 +4,39 @@
|
|||||||
- name: Workstation | Software | VPN | Mullvad
|
- name: Workstation | Software | VPN | Mullvad
|
||||||
block:
|
block:
|
||||||
|
|
||||||
# https://mullvad.net/en/help/install-mullvad-app-linux
|
# https://mullvad.net/en/help/install-mullvad-app-linux
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | Add Repo [apt]
|
- name: Workstation | Software | VPN | Mullvad | Add Repo [apt]
|
||||||
ansible.builtin.shell: "{{ item }}"
|
ansible.builtin.shell: "{{ item }}"
|
||||||
loop:
|
loop:
|
||||||
- sudo curl -fsSLo /usr/share/keyrings/mullvad-keyring.asc https://repository.mullvad.net/deb/mullvad-keyring.asc
|
- sudo curl -fsSLo /usr/share/keyrings/mullvad-keyring.asc https://repository.mullvad.net/deb/mullvad-keyring.asc
|
||||||
- echo "deb [signed-by=/usr/share/keyrings/mullvad-keyring.asc arch=$( dpkg --print-architecture )] https://repository.mullvad.net/deb/stable $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/mullvad.list
|
- echo "deb [signed-by=/usr/share/keyrings/mullvad-keyring.asc arch=$( dpkg --print-architecture )] https://repository.mullvad.net/deb/stable $(lsb_release -cs) main" | sudo tee /etc/apt/sources.list.d/mullvad.list
|
||||||
- apt update
|
- apt update
|
||||||
when: ansible_pkg_mgr == "apt"
|
when: ansible_pkg_mgr == "apt"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | Add Repo [dnf]
|
- name: Workstation | Software | VPN | Mullvad | Add Repo [dnf]
|
||||||
ansible.builtin.shell: "{{ item }}"
|
ansible.builtin.shell: "{{ item }}"
|
||||||
loop:
|
loop:
|
||||||
- sudo dnf config-manager --add-repo https://repository.mullvad.net/rpm/stable/mullvad.repo
|
- sudo dnf config-manager --add-repo https://repository.mullvad.net/rpm/stable/mullvad.repo
|
||||||
when: ansible_pkg_mgr == "dnf"
|
when: ansible_pkg_mgr == "dnf"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Install
|
- name: Workstation | Software | VPN | Install
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- mullvad-vpn
|
- mullvad-vpn
|
||||||
state: present
|
state: present
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Install (Artix, runit)
|
- name: Workstation | Software | VPN | Install (Artix, runit)
|
||||||
ansible.builtin.package:
|
ansible.builtin.package:
|
||||||
name:
|
name:
|
||||||
- mullvad-vpn-runit
|
- mullvad-vpn-runit
|
||||||
state: present
|
state: present
|
||||||
when: ansible_pkg_mgr == "pacman"
|
when: ansible_pkg_mgr == "pacman"
|
||||||
and ansible_service_mgr == "runit"
|
and ansible_service_mgr == "runit"
|
||||||
|
|
||||||
when: ansible_distribution in ("Debian", "Ubuntu")
|
when: ansible_distribution in ("Debian", "Ubuntu")
|
||||||
or ansible_pkg_mgr in ("pacman", "dnf")
|
or ansible_pkg_mgr in ("pacman", "dnf")
|
||||||
@@ -42,31 +46,33 @@
|
|||||||
- name: Workstation | Software | VPN | Mullvad | Devuan (runit)
|
- name: Workstation | Software | VPN | Mullvad | Devuan (runit)
|
||||||
block:
|
block:
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | Devuan | Facts 01
|
- name: Workstation | Software | VPN | Mullvad | Devuan | Facts 01
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
devuan_mullvad_dir: "{{ global_src }}/mullvad-installer"
|
devuan_mullvad_dir: "{{ global_src }}/mullvad-installer"
|
||||||
mullvad_deb_url: https://mullvad.net/en/download/app/deb/latest
|
mullvad_deb_url: https://mullvad.net/en/download/app/deb/latest
|
||||||
mullvad_repack_url: https://github.com/sys-fs/mullvad-repack
|
mullvad_repack_url: https://github.com/sys-fs/mullvad-repack
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | Devuan | Facts 02
|
- name: Workstation | Software | VPN | Mullvad | Devuan | Facts 02
|
||||||
ansible.builtin.set_fact:
|
ansible.builtin.set_fact:
|
||||||
mullvad_repack_dir: "{{ devuan_mullvad_dir }}/mullvad_repack"
|
mullvad_repack_dir: "{{ devuan_mullvad_dir }}/mullvad_repack"
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | Devuan | Check
|
- name: Workstation | Software | VPN | Mullvad | Devuan | Check
|
||||||
ansible.builtin.stat:
|
ansible.builtin.stat:
|
||||||
path: '/opt/Mullvad VPN'
|
path: '/opt/Mullvad VPN'
|
||||||
register: mullvad_installed
|
register: mullvad_installed
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | Devuan | Install
|
- name: Workstation | Software | VPN | Mullvad | Devuan | Install
|
||||||
ansible.builtin.shell: "{{ item }}"
|
ansible.builtin.shell: "{{ item }}"
|
||||||
loop:
|
loop:
|
||||||
- "mkdir -pv {{ devuan_mullvad_dir }}"
|
- "mkdir -pv {{ devuan_mullvad_dir }}"
|
||||||
- "curl -L -o {{ devuan_mullvad_dir }}/Mullvad.deb {{ mullvad_deb_url }}"
|
- "curl -L -o {{ devuan_mullvad_dir }}/Mullvad.deb {{ mullvad_deb_url }}"
|
||||||
- "rm -rfv {{ mullvad_repack_dir }}"
|
- "rm -rfv {{ mullvad_repack_dir }}"
|
||||||
- "git clone {{ mullvad_repack_url }} {{ mullvad_repack_dir }}"
|
- "git clone {{ mullvad_repack_url }} {{ mullvad_repack_dir }}"
|
||||||
- "cd {{ mullvad_repack_dir }} && ./repack.sh ../Mullvad.deb"
|
- "cd {{ mullvad_repack_dir }} && ./repack.sh ../Mullvad.deb"
|
||||||
- "apt-get install -y --reinstall {{ devuan_mullvad_dir }}/Mullvad_repack.deb"
|
- "apt-get install -y --reinstall {{ devuan_mullvad_dir }}/Mullvad_repack.deb"
|
||||||
when: not mullvad_installed.stat.exists
|
when: not mullvad_installed.stat.exists
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
when: ansible_pkg_mgr == "apt"
|
when: ansible_pkg_mgr == "apt"
|
||||||
and ansible_service_mgr != "systemd"
|
and ansible_service_mgr != "systemd"
|
||||||
@@ -95,6 +101,8 @@
|
|||||||
- echo "cd {{ mullvad_exe_dir }}" >> {{ mullvad_exe_new }}
|
- echo "cd {{ mullvad_exe_dir }}" >> {{ mullvad_exe_new }}
|
||||||
- echo "./{{ mullvad_exe }}" >> {{ mullvad_exe_new }}
|
- echo "./{{ mullvad_exe }}" >> {{ mullvad_exe_new }}
|
||||||
- chmod +x {{ mullvad_exe_new }}
|
- chmod +x {{ mullvad_exe_new }}
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
|
|
||||||
- name: Workstation | Software | VPN | Mullvad | runit | Enable Service (mullvad-daemon)
|
- name: Workstation | Software | VPN | Mullvad | runit | Enable Service (mullvad-daemon)
|
||||||
ansible.builtin.file:
|
ansible.builtin.file:
|
||||||
@@ -113,10 +121,13 @@
|
|||||||
- name: Workstation | Software | VPN | Mullvad | PATH | Enable Lockdown
|
- name: Workstation | Software | VPN | Mullvad | PATH | Enable Lockdown
|
||||||
ansible.builtin.shell: "{{ item }}"
|
ansible.builtin.shell: "{{ item }}"
|
||||||
loop:
|
loop:
|
||||||
- mullvad lan set block
|
- mullvad lan set allow # This allows Docker to forward ports to localhost!
|
||||||
- mullvad tunnel set ipv6 on
|
- mullvad tunnel set ipv6 on
|
||||||
- mullvad dns set default --block-ads --block-trackers --block-malware --block-gambling --block-adult-content --block-social-media
|
- mullvad dns set default --block-ads --block-trackers --block-malware --block-gambling --block-adult-content --block-social-media
|
||||||
- mullvad auto-connect set on
|
- mullvad auto-connect set on
|
||||||
- mullvad lockdown-mode set on
|
- mullvad lockdown-mode set on
|
||||||
- mullvad beta-program set off
|
- mullvad beta-program set off
|
||||||
|
become: true
|
||||||
become_user: "{{ user }}"
|
become_user: "{{ user }}"
|
||||||
|
register: shell_check
|
||||||
|
changed_when: shell_check.rc == 0
|
||||||
@@ -17,7 +17,6 @@
|
|||||||
- "{{ make }}"
|
- "{{ make }}"
|
||||||
- "{{ dmenu }}"
|
- "{{ dmenu }}"
|
||||||
- "{{ font_awesome }}"
|
- "{{ font_awesome }}"
|
||||||
update_cache: true
|
|
||||||
|
|
||||||
|
|
||||||
## Download ##
|
## Download ##
|
||||||
|
|||||||
@@ -66,7 +66,6 @@
|
|||||||
- "{{ i3_redshift }}"
|
- "{{ i3_redshift }}"
|
||||||
- "{{ i3_redshift_gui }}"
|
- "{{ i3_redshift_gui }}"
|
||||||
state: present
|
state: present
|
||||||
update_cache: true
|
|
||||||
|
|
||||||
- name: Workstation | Shared | Software | i3 | Install (yay)
|
- name: Workstation | Shared | Software | i3 | Install (yay)
|
||||||
ansible.builtin.shell: "yay -Qs {{ item }} || yay --noconfirm -S {{ item }}"
|
ansible.builtin.shell: "yay -Qs {{ item }} || yay --noconfirm -S {{ item }}"
|
||||||
|
|||||||
@@ -0,0 +1,34 @@
|
|||||||
|
---
|
||||||
|
# Used to single out plays which are either near the end of the playbook or are
|
||||||
|
# brand new and not safe to add to the full mix of things until finished.
|
||||||
|
|
||||||
|
- name: Main | TEST Setup
|
||||||
|
hosts: localhost
|
||||||
|
connection: local
|
||||||
|
become: true
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
|
||||||
|
- name: TEST| Header
|
||||||
|
ansible.builtin.include_tasks: tasks/header.yml
|
||||||
|
|
||||||
|
#######################
|
||||||
|
#######################
|
||||||
|
####### TESTING #######
|
||||||
|
#######################
|
||||||
|
#######################
|
||||||
|
|
||||||
|
- name: TEST | LLMs
|
||||||
|
block:
|
||||||
|
|
||||||
|
- name: LLM
|
||||||
|
ansible.builtin.include_tasks: tasks/workstation/linux/software/ai/llm.yml
|
||||||
|
|
||||||
|
#######################
|
||||||
|
#######################
|
||||||
|
###### / TESTING ######
|
||||||
|
#######################
|
||||||
|
#######################
|
||||||
|
|
||||||
|
- name: TEST | Footer
|
||||||
|
ansible.builtin.include_tasks: tasks/footer.yml
|
||||||
Reference in new issue
Block a user