If there are any major changes, I can now edit MOTD!

Signed-off-by: Jeroen Oudshoorn <oudshoorn.jeroen@gmail.com>
This commit is contained in:
Jeroen Oudshoorn
2023-09-20 10:42:13 +02:00
parent 6115819351
commit f288f6e522
2 changed files with 32 additions and 27 deletions

0
builder/data/etc/update-motd.d/01-motd Normal file → Executable file
View File

View File

@ -492,34 +492,39 @@
- name: configure 01-motd - name: configure 01-motd
become_user: root become_user: root
copy: copy:
dest: /etc/01-motd dest: /etc/update-motd.d/01-motd
content: | content: |
(◕‿‿◕) {{pwnagotchi.hostname}} #!/bin/sh
_hostname=$(hostname)
Hi! I'm a pwnagotchi {{pwnagotchi.version}}, please take good care of me! _version=$(cut -d"'" -f2 < /usr/local/lib/python3.9/dist-packages/pwnagotchi/_version.py)
Here are some basic things you need to know to raise me properly! echo
echo "(◕‿‿◕) $_hostname"
If you want to change my configuration, use /etc/pwnagotchi/config.toml echo
echo "Hi! I'm a pwnagotchi $_version, please take good care of me!"
All the configuration options can be found on /etc/pwnagotchi/default.toml, echo "Here are some basic things you need to know to raise me properly!"
but don't change this file because I will recreate it every time I'm restarted! echo
echo "If you want to change my configuration, use /etc/pwnagotchi/config.toml"
I'm managed by systemd. Here are some basic commands. echo
echo "All the configuration options can be found on /etc/pwnagotchi/default.toml,"
If you want to know what I'm doing, you can check my logs with the command echo "but don't change this file because I will recreate it every time I'm restarted!"
tail -f /var/log/pwnagotchi.log echo
echo "I use oPwnGrid as my main API, you can check stats at https://opwngrid.xyz"
If you want to know if I'm running, you can use echo
systemctl status pwnagotchi echo "I'm managed by systemd. Here are some basic commands."
echo
You can restart me using echo "If you want to know what I'm doing, you can check my logs with the command"
systemctl restart pwnagotchi echo "- pwnlog"
echo "- pwnver, to check the current version"
But be aware I will go into MANUAL mode when restarted! echo "- sudo pwnagotchi --donate, to see how you can donate to this project"
You can put me back into AUTO mode using echo "- sudo pwnagotchi --check-update, to see if there is a new version available"
touch /root/.pwnagotchi-auto && systemctl restart pwnagotchi echo
echo "If you want to know if I'm running, you can use"
You learn more about me at https://pwnagotchi.ai/ echo "systemctl status pwnagotchi"
echo
echo "You can restart me using"
echo "systemctl restart pwnagotchi"
echo
echo "You learn more about me at https://pwnagotchi.ai/"
when: hostname.changed when: hostname.changed
- name: Add pwnlog alias - name: Add pwnlog alias