Skip to content

Commit

Permalink
tmp
Browse files Browse the repository at this point in the history
  • Loading branch information
Yurii Smetanka committed Oct 21, 2024
1 parent f851905 commit 6276ad9
Show file tree
Hide file tree
Showing 4 changed files with 44 additions and 35 deletions.
22 changes: 11 additions & 11 deletions builder/bpim4.json.pkr.hcl
Original file line number Diff line number Diff line change
Expand Up @@ -50,8 +50,8 @@ build {
destination = "/usr/bin/"
sources = [
"data/64bit/usr/bin/bettercap-launcher",
"data/64bit/usr/bin/decryption-webserver",
"data/64bit/usr/bin/fix_pwny_ethernet.sh",
// "data/64bit/usr/bin/decryption-webserver",
// "data/64bit/usr/bin/fix_pwny_ethernet.sh",
"data/64bit/usr/bin/hdmioff",
"data/64bit/usr/bin/hdmion",
"data/64bit/usr/bin/monstart",
Expand All @@ -70,15 +70,15 @@ build {
destination = "/usr/local/src/pwnagotchi/"
source = "../"
}
provisioner "file" {
destination = "/etc/"
sources = [
"data/64bit/etc/rc.local",
"data/64bit/etc/dphys-swapfile",
"data/64bit/etc/bash_completion.d/",
"data/64bit/etc/network/",
]
}
// provisioner "file" {
// destination = "/etc/"
// sources = [
// "data/64bit/etc/rc.local",
// "data/64bit/etc/dphys-swapfile",
// "data/64bit/etc/bash_completion.d/",
// "data/64bit/etc/network/",
// ]
// }
provisioner "file" {
destination = "/etc/systemd/system/"
sources = [
Expand Down
8 changes: 7 additions & 1 deletion builder/bpim4.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
- apt-daily-upgrade.timer
- apt-daily.service
- apt-daily.timer
# - bluetooth.service ## todo: disabled anyway, maybe reenable after bluetooth support for bpim4z is fixed in armbian kernel
- bluetooth.service
packages:
caplets:
source: "https://github.com/jayofelony/caplets.git"
Expand Down Expand Up @@ -114,6 +114,7 @@
- libts-bin
- libusb-1.0-0-dev
- lsof
- net-tools
- make
- ntp
- pkg-config
Expand Down Expand Up @@ -167,6 +168,11 @@
regexp: '^overlays='
line: 'overlays=ph-i2c1 pg-i2c4 pg-uart1 spi0-spidev spi1-cs1-spidev'

- name: remove current rc.local
file:
path: /etc/rc.local
state: absent

- name: adjust /etc/modules
lineinfile:
dest: /etc/modules
Expand Down
3 changes: 2 additions & 1 deletion builder/data/64bit/etc/modules-load.d/modules.conf
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@
# This file contains the names of kernel modules that should be loaded
# at boot time, one per line. Lines beginning with "#" are ignored.
# Parameters can be specified after the module name.
i2c-dev
i2c-dev
g_ether
46 changes: 24 additions & 22 deletions builder/data/64bit/etc/rc.local
Original file line number Diff line number Diff line change
Expand Up @@ -8,33 +8,35 @@

# pwnagotchi first run script

sleep 10
# sleep 10

systemctl stop bettercap pwngrid-peer pwnagotchi
# systemctl stop bettercap pwngrid-peer pwnagotchi

/usr/bin/fix_pwny_ethernet.sh
# /usr/bin/fix_pwny_iface.sh
# /usr/bin/fix_pwny_ethernet.sh
# # /usr/bin/fix_pwny_iface.sh

systemctl restart bettercap pwngrid-peer pwnagotchi
# systemctl restart bettercap pwngrid-peer pwnagotchi

mv /etc/rc.local /etc/rc.local.FIRSTRUN
mv /etc/rc.local.ORIG /etc/rc.local || cat >/etc/rc.local <<EOF
#!/bin/sh -e
#
# rc.local
#
# This script is executed at the end of each multiuser runlevel.
# Make sure that the script will "exit 0" on success or any other
# value on error.
#
# In order to enable or disable this script just change the execution
# bits.
#
# By default this script does nothing.
# mv /etc/rc.local /etc/rc.local.FIRSTRUN
# mv /etc/rc.local.ORIG /etc/rc.local || cat >/etc/rc.local <<EOF
# #!/bin/sh -e
# #
# # rc.local
# #
# # This script is executed at the end of each multiuser runlevel.
# # Make sure that the script will "exit 0" on success or any other
# # value on error.
# #
# # In order to enable or disable this script just change the execution
# # bits.
# #
# # By default this script does nothing.

exit 0
EOF
# exit 0
# EOF

# exec /etc/rc.local

exec /etc/rc.local
timedatectl set-ntp true

exit 0

0 comments on commit 6276ad9

Please sign in to comment.