more cleanup, set dirs
This commit is contained in:
@ -1,9 +1,16 @@
|
|||||||
# initial router.config
|
# initial router.config
|
||||||
|
# temp directory
|
||||||
|
i2p.dir.temp=/data/data/net.i2p.router/files/tmp
|
||||||
|
i2p.dir.pid=/data/data/net.i2p.router/files/tmp
|
||||||
# save memory
|
# save memory
|
||||||
router.prng.buffers=2
|
router.prng.buffers=2
|
||||||
router.decayingBloomFilterM=20
|
router.decayingBloomFilterM=20
|
||||||
stat.full=false
|
stat.full=false
|
||||||
|
i2np.udp.maxConnections=30
|
||||||
# no I2CP
|
# no I2CP
|
||||||
i2p.dummyClientFacade=true
|
i2p.dummyClientFacade=true
|
||||||
# for now
|
# for now
|
||||||
i2np.ntcp.enable=false
|
i2np.ntcp.enable=false
|
||||||
|
# not on android
|
||||||
|
i2np.upnp.enable=false
|
||||||
|
routerconsole.geoip.enable=false
|
||||||
|
@ -18,6 +18,7 @@ import net.i2p.router.web.ContextHelper;
|
|||||||
public class I2PAndroid extends Activity
|
public class I2PAndroid extends Activity
|
||||||
{
|
{
|
||||||
static Context _context;
|
static Context _context;
|
||||||
|
private static final String DIR = "/data/data/net.i2p.router/files";
|
||||||
|
|
||||||
/** Called when the activity is first created. */
|
/** Called when the activity is first created. */
|
||||||
@Override
|
@Override
|
||||||
@ -80,6 +81,7 @@ public class I2PAndroid extends Activity
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void debugStuff() {
|
private void debugStuff() {
|
||||||
|
System.err.println("java.io.tmpdir" + ": " + System.getProperty("java.io.tmpdir"));
|
||||||
System.err.println("java.vendor" + ": " + System.getProperty("java.vendor"));
|
System.err.println("java.vendor" + ": " + System.getProperty("java.vendor"));
|
||||||
System.err.println("java.version" + ": " + System.getProperty("java.version"));
|
System.err.println("java.version" + ": " + System.getProperty("java.version"));
|
||||||
System.err.println("os.arch" + ": " + System.getProperty("os.arch"));
|
System.err.println("os.arch" + ": " + System.getProperty("os.arch"));
|
||||||
@ -99,6 +101,10 @@ public class I2PAndroid extends Activity
|
|||||||
copyResourceToFile(R.raw.logger_config, "logger.config");
|
copyResourceToFile(R.raw.logger_config, "logger.config");
|
||||||
copyResourceToFile(R.raw.blocklist_txt, "blocklist.txt");
|
copyResourceToFile(R.raw.blocklist_txt, "blocklist.txt");
|
||||||
// }
|
// }
|
||||||
|
|
||||||
|
// Set up the locations so Router and WorkingDir can find them
|
||||||
|
System.setProperty("i2p.dir.base", DIR);
|
||||||
|
System.setProperty("i2p.dir.config", DIR);
|
||||||
}
|
}
|
||||||
|
|
||||||
private void copyResourceToFile(int resID, String f) {
|
private void copyResourceToFile(int resID, String f) {
|
||||||
|
@ -76,6 +76,9 @@ class LogWriter implements Runnable {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public String currentFile() {
|
||||||
|
return _currentFile != null ? _currentFile.getAbsolutePath() : "uninitialized";
|
||||||
|
}
|
||||||
|
|
||||||
private void rereadConfig() {
|
private void rereadConfig() {
|
||||||
long now = Clock.getInstance().now();
|
long now = Clock.getInstance().now();
|
||||||
|
Reference in New Issue
Block a user