2012-04-14 16:22:27 +02:00
|
|
|
#########
|
|
|
|
## Config for pirate-box WWW Release
|
2015-04-07 18:54:23 +02:00
|
|
|
## written by Matthias Strubel (matthias.strubel@aod-rpg.de) (c)2011-2014
|
|
|
|
## licenced under the GPL-3 ; feel free to improve or send me feedback
|
2012-04-14 16:22:27 +02:00
|
|
|
########
|
|
|
|
## Configuration help
|
|
|
|
## If you plan to use one laptop as the piratebox:
|
|
|
|
## Set DO_IFCONFIG , USE_APN, USE_DNSMASQ to yes
|
|
|
|
## If you plan to run a two component setup (one router and one providing the storage+website)
|
|
|
|
## connected with ethernet:
|
|
|
|
## Set DO_IFCONFIG , USE_APN, USE_DNSMASQ to no
|
|
|
|
## Configure your ethernet eth0 (or whatever) to a static IP
|
|
|
|
## force your router to publish the HOST Option with your static IP; in case of dnsmasq add the /etc/hosts entrys
|
2014-01-17 16:52:26 +01:00
|
|
|
## Have a look at http://www.piratebox.cc for futher instructions
|
2012-04-14 16:22:27 +02:00
|
|
|
##
|
|
|
|
## You may deactivated severall option as needed. It's flexible.
|
|
|
|
|
|
|
|
|
2012-06-08 23:20:51 +02:00
|
|
|
#----------------- Folder Configuration -------------------#
|
|
|
|
|
|
|
|
PIRATEBOX_FOLDER="/opt/piratebox"
|
|
|
|
WWW_FOLDER="/opt/piratebox/www"
|
2016-05-10 20:09:49 +02:00
|
|
|
WWW_CONTENT="/opt/piratebox/share/content"
|
2012-06-08 23:20:51 +02:00
|
|
|
|
2012-12-26 09:51:59 +01:00
|
|
|
#Do not change untill really needed.
|
|
|
|
PIRATEBOX_PYTHONPATH="$PIRATEBOX_FOLDER/python_lib"
|
|
|
|
|
2012-06-08 23:20:51 +02:00
|
|
|
|
|
|
|
#Datafolder , where is you usb-stick // drive mounted
|
|
|
|
SHARE_FOLDER="$PIRATEBOX_FOLDER/share"
|
|
|
|
|
|
|
|
#Upload Folder
|
|
|
|
# Change this if you want to user uploaded data in a subfolder
|
|
|
|
# Make sure the folder exists
|
|
|
|
# UPLOADFOLDER="$SHARE_FOLDER/Upload"
|
|
|
|
UPLOADFOLDER="$SHARE_FOLDER/Shared"
|
|
|
|
|
|
|
|
#----------------- Startup Configuration -------------------#
|
|
|
|
# Which Steps has to be done
|
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
#Do network config
|
|
|
|
DO_IFCONFIG="yes"
|
|
|
|
|
|
|
|
#Do IW config - setting up a wlan0 interface with iw
|
|
|
|
# for some wifi-cards required
|
|
|
|
DO_IW="no"
|
|
|
|
#Iw physical interface
|
|
|
|
PHY_IF="phy0"
|
|
|
|
|
2013-02-26 20:30:54 +01:00
|
|
|
# Check if interface exists
|
|
|
|
# should be set to yes if you use a USB wifi card
|
|
|
|
PROBE_INTERFACE="no"
|
|
|
|
# wait how many seconds until throw an error
|
|
|
|
PROBE_TIME=10
|
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
#Start services...
|
|
|
|
# act like a apn / <yes|no>
|
|
|
|
# please have a look @ hostapd.conf ; you may need to change some options, regarding wifi-card
|
|
|
|
USE_APN="yes"
|
|
|
|
# act like dns&dhcp (dnsmasq)
|
|
|
|
USE_DNSMASQ="yes"
|
|
|
|
|
|
|
|
#HOSTNAME ... if you really want to change it, plz change:
|
2013-10-09 12:17:07 +02:00
|
|
|
# www/index.html
|
|
|
|
#
|
|
|
|
# That is the Domain-Specifi part, where you reach always the local box
|
2012-04-14 16:22:27 +02:00
|
|
|
HOST="piratebox.lan"
|
|
|
|
|
|
|
|
#----------------- Configuration for DNSMASQ & IF-Setup -------------------#
|
|
|
|
# Name of the wlan interface
|
|
|
|
INTERFACE="wlan0"
|
|
|
|
# On which interface DNSMASQ should listen. -i is the parameter for dnsmasq
|
|
|
|
# Make it empty to disable
|
2012-06-09 10:04:42 +02:00
|
|
|
DNSMASQ_INTERFACE="wlan0"
|
2012-04-14 16:22:27 +02:00
|
|
|
|
2015-04-07 18:18:49 +02:00
|
|
|
#Brdige add interface (setr yes to enable bridging)
|
2012-04-14 16:22:27 +02:00
|
|
|
DO_BRIDGE="no"
|
|
|
|
BRIDGE="br-lan"
|
|
|
|
|
2012-06-08 23:20:51 +02:00
|
|
|
#Network
|
|
|
|
NET=192.168.77
|
|
|
|
|
|
|
|
#IP-SHORT (is stringed together)
|
2015-04-07 18:18:49 +02:00
|
|
|
# What IP does your Box have?? i.e. 1 => 192.168.77.1
|
2012-06-08 23:20:51 +02:00
|
|
|
IP_SHORT=1
|
|
|
|
|
|
|
|
#DHCP LEASE Start
|
|
|
|
START_LEASE=10
|
|
|
|
#DHCP LEASE End Range
|
|
|
|
END_LEASE=250
|
|
|
|
#Leasetime (When should the client renew it's IP)
|
|
|
|
LEASE_DURATION=12h
|
2012-04-14 16:22:27 +02:00
|
|
|
|
2013-08-11 17:09:03 +02:00
|
|
|
# Where is the leasefile stored to?
|
|
|
|
LEASE_FILE_LOCATION=$PIRATEBOX_FOLDER/tmp/lease.file
|
|
|
|
|
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
# Define the netmask
|
|
|
|
NETMASK=255.255.255.0
|
|
|
|
|
2012-06-08 23:20:51 +02:00
|
|
|
#SET IP for ifconfig stuff - DON'T CHANGE
|
|
|
|
IP=$NET.$IP_SHORT
|
|
|
|
|
|
|
|
#Load Config about ipv6 stuff - DON'T CHANGE
|
|
|
|
. $PIRATEBOX_FOLDER/conf/ipv6.conf
|
2012-04-14 16:22:27 +02:00
|
|
|
|
|
|
|
|
2013-10-09 12:17:07 +02:00
|
|
|
#--------------------------------------------------------------------------#
|
|
|
|
# Node-Config path
|
|
|
|
|
|
|
|
NODE_CONFIG="$PIRATEBOX_FOLDER/conf/node.conf"
|
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
#----------------- Configuration for the pure piratebox -------------------#
|
|
|
|
## droopy, webserver, shoutbox- and forum-server
|
|
|
|
|
2015-04-07 18:18:49 +02:00
|
|
|
## Timesave file for non-RTC devices
|
2013-08-14 16:56:04 +02:00
|
|
|
TIMESAVE="$PIRATEBOX_FOLDER/share/timesave_file"
|
2012-04-14 16:22:27 +02:00
|
|
|
|
2015-08-23 11:07:04 +02:00
|
|
|
#On non OpenWRT you can use the default output format
|
|
|
|
# as an input format. For OpenWrt you need to specify +%C%g%m%d%H%M
|
|
|
|
# The content is exchanged during makefile processing and image build
|
|
|
|
TIMESAVE_FORMAT=""
|
|
|
|
|
2012-06-15 18:09:03 +02:00
|
|
|
#Start droopy? - Enable upload?
|
2016-04-14 07:43:59 +02:00
|
|
|
DROOPY_ENABLED="yes"
|
2012-04-14 16:22:27 +02:00
|
|
|
#Image-SRC
|
|
|
|
IMAGENAME="piratebox-logo-small.png"
|
|
|
|
IMAGE="$PIRATEBOX_FOLDER/src/$IMAGENAME"
|
2012-04-14 18:47:27 +02:00
|
|
|
DROOPY_TXT=""
|
|
|
|
DROOPY_PORT="8080"
|
2015-07-30 21:54:43 +02:00
|
|
|
# Set correct permissions for an uploaded file
|
2016-06-14 20:09:28 +02:00
|
|
|
# The following line needs to be commented for FAT32 / vfat partitions
|
2015-07-30 21:54:43 +02:00
|
|
|
DROOPY_CHMOD="755"
|
2016-06-14 20:09:28 +02:00
|
|
|
|
2012-04-26 21:46:03 +02:00
|
|
|
DROOPY_USERDIR=""
|
|
|
|
# Uncomment line below for adding directory feature
|
|
|
|
#DROOPY_USERDIR=" -u True "
|
2012-04-14 16:22:27 +02:00
|
|
|
|
2012-04-26 22:26:48 +02:00
|
|
|
#Use UserId from lighttpd for droopy (use on ext-filesystems)
|
2012-10-05 21:55:56 +02:00
|
|
|
DROOPY_USE_USER="yes"
|
2012-04-26 22:26:48 +02:00
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
#Configuration for chat (If you decide to move the chat folder, you have to change /opt/piratebox/chat/cgi-bin/py* files )
|
|
|
|
CHATFILE="$WWW_FOLDER/cgi-bin/data.pso"
|
|
|
|
|
2012-11-01 22:47:36 +01:00
|
|
|
#Generated File
|
|
|
|
GEN_CHATFILE="$WWW_FOLDER/chat_content.html"
|
|
|
|
|
2015-09-15 01:31:00 +02:00
|
|
|
#Generated File for DiskUsage
|
|
|
|
GEN_DISKFILE="$WWW_FOLDER/diskusage.html"
|
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
# Reset Shoutbox on Startup?
|
|
|
|
RESET_CHAT="yes"
|
|
|
|
|
2014-01-17 17:37:57 +01:00
|
|
|
### Shoutbox is enabled.
|
|
|
|
# When you set this option to "no", then the shoutbox file is not writable anymore
|
|
|
|
# and in the json file the module is disabled. You should adjust the chat_init.txt
|
|
|
|
# to make clear, that the box is not working anymore.
|
|
|
|
SHOUTBOX_ENABLED="yes"
|
|
|
|
|
2014-08-04 21:46:17 +02:00
|
|
|
SHOUTBOX_CLIENT_TIMESTAMP="no"
|
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
#Inititiation Chat-Message
|
2014-01-17 16:41:48 +01:00
|
|
|
### This option was removed, you can find the chat message in conf/chat_init.txt
|
2012-04-14 16:22:27 +02:00
|
|
|
|
2014-01-17 16:37:23 +01:00
|
|
|
#Provide files needed for PirateBox custom dirlisting
|
|
|
|
CUSTOM_DIRLIST_COPY="yes"
|
|
|
|
|
2014-01-17 17:13:50 +01:00
|
|
|
#Generate config json for frontend
|
|
|
|
PBX_JSON_GENERATION="yes"
|
|
|
|
PBX_JSON_FILE="$WWW_FOLDER/piratebox_config.json"
|
|
|
|
|
2012-11-09 08:01:00 +01:00
|
|
|
#Activate Global chat
|
|
|
|
# Still experimentall!
|
|
|
|
GLOBAL_CHAT="no"
|
|
|
|
|
|
|
|
#On which broadcast address should it send
|
|
|
|
# Take care on the syntax!!
|
2012-12-26 09:51:59 +01:00
|
|
|
GLOBAL_DEST="[ #255.255.255.255# , #10.255.255.255# , #$NET.255# ]"
|
2012-11-09 08:01:00 +01:00
|
|
|
|
2012-04-14 16:22:27 +02:00
|
|
|
#------------------------ Additional configuration for lighttpd
|
2012-04-14 17:24:55 +02:00
|
|
|
LIGHTTPD_USER=nobody
|
|
|
|
LIGHTTPD_GROUP=nogroup
|
2012-04-14 16:22:27 +02:00
|
|
|
|
|
|
|
|
2013-03-29 09:22:07 +01:00
|
|
|
#------------------------ IRC Configuration
|
|
|
|
|
|
|
|
#Switch to yes if you want to enable the IRC-Server
|
|
|
|
ENABLE_IRC_SERVER="no"
|
|
|
|
|
2012-06-15 18:03:51 +02:00
|
|
|
#------------------------ Hook in user-config
|
|
|
|
. $PIRATEBOX_FOLDER/conf/hook_custom.conf
|