Differences
This shows you the differences between two versions of the page.
Both sides previous revision Previous revision Next revision | Previous revision | ||
openwrt:mods [2016/10/14 19:57] matthias [Hostname] fixed formatted; 1.0 mark |
openwrt:mods [2017/12/16 07:54] (current) comap89 [Install a tracker software] |
||
---|---|---|---|
Line 31: | Line 31: | ||
After this make a ''reboot''. All ''.php'' files are processed, as long as these are placed in the ''/content/'' folder. This folder is located in ''/opt/piratebox/share'' - on OpenWrt on the USB stick ''<usb>/PirateBox/''. | After this make a ''reboot''. All ''.php'' files are processed, as long as these are placed in the ''/content/'' folder. This folder is located in ''/opt/piratebox/share'' - on OpenWrt on the USB stick ''<usb>/PirateBox/''. | ||
+ | |||
+ | ===== Disable client isolation ===== | ||
+ | Per default it is not permitted to connect directly to another client. To allow this, you need to disable the feature "AP isolation". Connect via SSH and run the following commands: | ||
+ | |||
+ | uci set wireless.@wifi-iface[0].isolate='0' | ||
+ | uci commit | ||
+ | reboot | ||
+ | |||
+ | |||
====== Lighttpd Mods - Piratebox version 1.0.x ====== | ====== Lighttpd Mods - Piratebox version 1.0.x ====== | ||
Line 68: | Line 77: | ||
option netmask '255.255.255.0' | option netmask '255.255.255.0' | ||
+ | **Since 1.1:** The next step is to change the referred IP in the firewall configuration. This can be done easily with that command: | ||
+ | |||
+ | sed -i -e 's|192.168.1.1|<new IP>|g' /etc/config/firewall | ||
+ | |||
+ | As the changes will drop in the connectivity, reboot the box: | ||
- | Restart your Scripts and reload your network-config on OpenWRT: | + | reboot |
- | /etc/init.d/network reload | + | |
==== Small python Forum ==== | ==== Small python Forum ==== | ||
Line 118: | Line 131: | ||
==== Hostname === | ==== Hostname === | ||
- | Since 1.0 there is a command in install_piratebox.sh ; this is the only thing needed. | + | Since PirateBox 1.0 there is a command in install_piratebox.sh ; this is the only thing needed. |
/opt/piratebox/bin/install_piratebox.sh /opt/piratebox/conf/piratebox.conf hostname <new hostname> | /opt/piratebox/bin/install_piratebox.sh /opt/piratebox/conf/piratebox.conf hostname <new hostname> | ||
- | Before 1.0: Change hostname in the index.html **/opt/piratebox/www/index.html** | + | Before PirateBox 1.0: Change hostname in the file index.html **/opt/piratebox/www/index.html** |
<iframe width='650' frameBorder='0' src='http://piratebox.lan:8080'>Your browser does not supprt Iframes.. If you want to upload something, follow this <a href='http://piratebox.lan:8080'>Link</a></iframe> | <iframe width='650' frameBorder='0' src='http://piratebox.lan:8080'>Your browser does not supprt Iframes.. If you want to upload something, follow this <a href='http://piratebox.lan:8080'>Link</a></iframe> | ||
==== Custom Directory Listing ==== | ==== Custom Directory Listing ==== | ||
- | How to customize your personall directory-listing is described on the [[http://redmine.lighttpd.net/projects/lighttpd/wiki/Docs:ModDirlisting|Lighttpd wiki]] | + | How to customize your personal directory-listing is described on the [[http://redmine.lighttpd.net/projects/lighttpd/wiki/Docs:ModDirlisting|Lighttpd wiki]] |
==== PHP for PirateBox ==== | ==== PHP for PirateBox ==== | ||
Line 188: | Line 201: | ||
/opt/piratebox/bin/install_piratebox.sh /opt/piratebox/conf/piratebox.conf station_cnt | /opt/piratebox/bin/install_piratebox.sh /opt/piratebox/conf/piratebox.conf station_cnt | ||
| | ||
- | The makes an entry to your crontab of the current user. It updates a station_cnt.txt file in /opt/piratebox/www every 2 minutes. On **OpenWRT you have to** ensure, that the cron daemon runs: | + | That makes an entry into the crontab of the current user. It updates a ''station_cnt.txt'' file in ''/opt/piratebox/www'' every 2 minutes. On **OpenWRT you have to** ensure, that the Cron daemon runs: |
/etc/init.d/cron enable && /etc/init.d/cron start | /etc/init.d/cron enable && /etc/init.d/cron start | ||
- | Add the following line in the index.html file | + | Add the following line in the ''index.html'' file |
<div id="station" class="card"></div> | <div id="station" class="card"></div> | ||
- | **Note:** if you try to do the activation on the RPi version, you need to execute the following command to enable cron: | + | **Note:** if you try to do the activation on the RPi version, you need to execute the following command to enable Cron: |
sudo systemctl enable cronie | sudo systemctl enable cronie | ||
Line 202: | Line 215: | ||
This option is important for the OpenWRT users. You want a www folder on your USB stick? | This option is important for the OpenWRT users. You want a www folder on your USB stick? | ||
- | <div classes important>We are going to disable the script exchange_www.sh with hotfix release 1.0.4 , even if the installation tells you to change something, it won't. The www_alt feature is disabled, please follow the instructions below.</div> | + | <div classes important>We are going to disable the script exchange_www.sh with PirateBox hotfix release 1.0.4 , even if the installation tells you to change something, it won't. The www_alt feature is disabled, please follow the instructions below.</div> |
After finalizing your box, you can run the following set of commands while being connected via **ssh**. These commands will create a folder, where you can put your files to. | After finalizing your box, you can run the following set of commands while being connected via **ssh**. These commands will create a folder, where you can put your files to. | ||
Line 217: | Line 230: | ||
After this, you can power off your PirateBox and put your content to the "content" folder. | After this, you can power off your PirateBox and put your content to the "content" folder. | ||
- | ==== bigger Image for webdata ==== | + | ==== Bigger image file size for webdata ==== |
[[http://ubuntuhak.blogspot.de/2012/10/how-to-create-format-and-mount-img-files.html|How to create, format and mount .img files]] | [[http://ubuntuhak.blogspot.de/2012/10/how-to-create-format-and-mount-img-files.html|How to create, format and mount .img files]] | ||
Line 223: | Line 236: | ||
If you want a regular changing MAC address for you hostspot, you can implement the script which is found [[https://forum.openwrt.org/viewtopic.php?pid=213774#p213774|on OpenWrt forum]]. [[http://forum.piratebox.cc/read.php?16,14001,14159#msg-14159|It is reported]] as working. | If you want a regular changing MAC address for you hostspot, you can implement the script which is found [[https://forum.openwrt.org/viewtopic.php?pid=213774#p213774|on OpenWrt forum]]. [[http://forum.piratebox.cc/read.php?16,14001,14159#msg-14159|It is reported]] as working. | ||
- | ==== Install a tracker software ==== | + | ==== Install a Torrent tracker software ==== |
The [[http://www.edoput.it/blog/2015/08/27/a-decentralised-tracker/|linked guide]] describes how to install a Torrent tracker to your PirateBox. You find support in [[http://forum.piratebox.cc/read.php?16,15678,15678#msg-15678|this forum topic]]. | The [[http://www.edoput.it/blog/2015/08/27/a-decentralised-tracker/|linked guide]] describes how to install a Torrent tracker to your PirateBox. You find support in [[http://forum.piratebox.cc/read.php?16,15678,15678#msg-15678|this forum topic]]. |