What is conler?

Conler stands for “Wi-Fi Connection Handler”. Conler is a configuration tool for Maemo OS which allow you to define reactions on connection with specified Wi-Fi Access Points (AP). ‘Reaction’ is supposed to be a list of user-defined commands which will be executed sequentially.

You do not need to spend you time doing such configurations in the the depths of OS anymore!

Conler is a Free Software, it is licensed under GNU GPL v3.

Note

conler is still under active development. Please feel free to send bug-reports, suggestions and just interesting ideas to conler-maemo {at} thekondor.net

When do I need conler?

You may need conler when you want:
  • To bring up/down firewall (e.g., iptables)
  • Start a synchronisation of your data (e.g., via rsync)
  • Change default IP routes
  • Start some application or play some sound :)

when you get connected to AP

Examples TBD

Working with UI

Main View

Main Window
Main view consists of the following major UI components:
  • List of Access Points to handle

  • List of Commands to execute

  • Toolbar which allows user to manage easily both these lists

    Control Toolbar

AP List

Access Point List

AP List contains names of Wi-Fi Access Points which will be handled on connection with. The list consists of two columns:

Status column
Defines if connection with this AP should be handled. Green colour means “yes, it certainly should”, Red means that connection with this AP will not be handled (disabled)
Access Point name column
Name of AP here must correspond to the name defined in Control Panel -> Settings -> Connectivity -> Connections

All operations to manage APs are placed on the left side of the toolbar.

Add new AP

New AP can be added with the following button on toolbar:

Add New AP button

After a click you will be asked to enter a name of AP:

Add New AP dialog

When you your confirm you input, a new AP will be added to the end of the list. By default, added AP will be disabled (it’s status can be changed any time later, see Disable/Enable AP for details)

Rename AP

From time to time names of APs are changed. You don’t need to create a new AP with a duplicate list of commands, you can just rename existin AP. Rename is performed with the following button:

Rename Access Point button

After a click you will be asked to enter a new name of the AP:

Rename Access Point dialog

Disable/Enable AP

There is no need to delete AP or to clear command list when you need to stop handling connection with concrete AP. AP handling can be just disabled.

There are two ways to disable AP:
  1. Toolbutton:
Toggle Access Point status (toolbutton)

It always indicates status of current AP

  1. Corresponding icon in the AP list

Remove AP

Deletion of AP can be performed with the following button on the toolbar:

Delete Access Point button

Note

  1. No confirmation to delete is asked
  2. Command list related to deleted AP will be cleared as well

Command List

Command List

Command List contains a sequence of commands which will be executed for the choosen AP.

You should keep in mind the following:
  • Commands are executed sequentially Next command is executed only when previous one is finished
  • Commands are executed with superuser (root) privileges

Add command

New command can be added using the following button on the toolbar:

Add New Command button

After a click you will be asked to enter a command to add.

Enter New Command dialog

When you confirm your input, a new command will be added to the end of the list (command’s position in the list can be changed anytime – see Change Command Position for details)

Edit command

Already existent command can be edited any time using the button:

Edit Current Command button

After a click you will be asked to edit selected command

Edit Current Command dialog

Change Command Position

Because commands are executed one by one, an order of them does matter. To change command’s position the following buttons are used:

Promote a command

Promote Current Command button

Demote a command

Demote Current Command button

Note

Functions to promote/demote command may be unvailable in some cases, when:

  1. Selected command is the last/first in the list
  2. Selected command is only one in the list

Remove command

Command can be removed by the following button:

Remove Current Command button

Note

No confirmation to delete is asked.

FAQ

How to run an application in backround?

Currently, Conler does not provider user with a handy way to select launch-mode – all applications are launched sequentially.

But the following workaround is possible:
  1. Create a shell script like that one:

    #!/bin/sh
    $@ &
  2. Name it, for example, /usr/local/bin/run-in-background.sh and make it executable

  3. Modify your command in Command List to look like:

    /usr/local/bin/run-in-background.sh /my/program -arg1 -arg2:value

How to get an output of the run application?

Currently, Conler does not provide user with a handy way to collect program’s output.

But the following workaround is possible:
  1. Create a shell script like that one:

    #!/bin/sh
    $@ 2>&1 > /tmp/launch.log
  2. Name it, for example, /usr/local/bin/run-logged.sh and make it executable

  3. Modify your command in Command List to look like:

    /usr/local/bin/run-logged.sh /my/program -arg1 -arg2:value
  4. Output of launched application will be stored in /tmp/launch.log

Note

This functionality is planned to be implemented in the further versions

Why my command is not executed?

Most common mistakes:
  1. You are trying to run a GUI application which can’t find set $DISPLAY variable
  2. You are trying to run an application which can’t be run with root privileges
  3. You are trying to run an application using relative path such as ../../my-program.sh or just my-program.sh. Use always absolute path instead.

How to run an application with non-root privileges?

Currently, Conler does not provide user with a handy way to switch launching with root and non-root privileges.

To run an application with user (non-root) privileges use /bin/su. Example:

/bin/su user -c "/my/program -arg1 -arg2:value"

Note

This functionality is planned to be implemented in the further versions

How to run a GUI application?

Currently, all applications are launched in the environment without defined $DISPLAY, $DBUS- and other variables.

To run a GUI application:
  1. Create a shell script like that one:

    #!/bin/sh
    export DEFAULTGTKTHEME="default"
    # Theme to use
    export DEFAULTMBTHEME="glasser"
    export DISABLE_GATEWAY="1"
    export DISPLAY=":0.0"
    export GTK2_RC_FILES="/home/user/.osso/current-gtk-theme:/home/user/.osso/current-gtk-key-theme"
    export DBUS_SESSION_BUS_ADDRESS="unix:path=/tmp/session_bus_socket"
    export DISPLAY=:0.0
    
    # Run all GUI application with non-root privileges only
    /bin/su user -c "$@"
  2. Name it, for example, /usr/local/bin/run-gui.sh and make it executable

  3. Modify your command in Command List to look like:

    /usr/local/bin/run-gui.sh /my/program -arg1 -arg2:value

Note

This functionality is planned to be implemented in the further versions