Skip to content
This repository
Browse code

new init command "setup" for config changes

  • Loading branch information...
commit 7661a5750a7b1340439c7f9a8d9701778518e500 1 parent 72607fe
Christiane Ruetten authored
5 src/control/postinst
@@ -14,9 +14,8 @@ then
14 14 echo "Next time you log in, you must use ssh."
15 15 fi
16 16
17   -# configure usb and network
18   -pb_usbconfig
19   -pb_netconfig
  17 +# configure USB and network
  18 +/etc/init.d/piratebox setup
20 19
21 20 # disable web interface, start PirateBox instead
22 21 /etc/init.d/uhttpd stop
14 src/data/etc/init.d/piratebox
@@ -3,16 +3,18 @@
3 3 NAME=piratebox
4 4 START=80
5 5 STOP=20
6   -EXTRA_COMMANDS="init update nodns"
7   -EXTRA_HELP=" init PirateBoxify a fresh USB disk
  6 +EXTRA_COMMANDS="setup init update nodns"
  7 +EXTRA_HELP=" setup Activate current USB and entwork configuration
  8 + init Mount USB, and PirateBoxify a fresh USB disk
8 9 update Update PirateBox files on USB disk
9 10 nodns Disable local DNS redirection through dnsmasq"
10 11
11 12 # include PirateBox shared functionality
12 13 . /etc/piratebox.common
13 14
14   -nodns() {
15   - pb_nodns
  15 +setup() {
  16 + pb_usbsetup
  17 + pb_netconfig
16 18 }
17 19
18 20 init() {
@@ -23,6 +25,10 @@ update() {
23 25 pb_update
24 26 }
25 27
  28 +nodns() {
  29 + pb_nodns
  30 +}
  31 +
26 32 start() {
27 33 pb_mount usb
28 34 # init if we have a fresh USB disk
2  src/data/etc/piratebox.common
... ... @@ -1,5 +1,5 @@
1 1 #############################################################################
2   -# PirateBox global config (do not change)
  2 +# PirateBox global config. /etc/init.d/piratebox setup to take effect
3 3
4 4 pb_ip="192.168.1.1"
5 5 pb_wireless_ssid="PirateBox"

0 comments on commit 7661a57

Please sign in to comment.
Something went wrong with that request. Please try again.