Tiny Core Linux
General TC => Programming & Scripting - Unofficial => Topic started by: Arslan S. on August 03, 2012, 04:22:03 AM
-
Here is a sample script to start a window manager or a desktop session with ConsoleKit
start-flwm:
#!/bin/sh
#
# Start Desktop Session with ConsoleKit
#
STARTUP="flwm_topside"
CK_LAUNCH_SESSION=/usr/local/bin/ck-launch-session
if [ -z "$DBUS_SESSION_BUS_ADDRESS" ]; then
STARTUP="dbus-launch --exit-with-session $STARTUP"
fi
if [ -x "$CK_LAUNCH_SESSION" -a -z "$XDG_SESSION_COOKIE" ]; then
STARTUP="$CK_LAUNCH_SESSION $STARTUP"
fi
exec $STARTUP
copy it to somewhere in PATH
install -Dm755 start-flwm ~/.local/bin/start-flwm
adjust sysconfig/desktop
echo start-flwm > /etc/sysconfig/desktop
and backup
echo etc/sysconfig/desktop >> /opt/.filetool.lst
add ConsoleKit.tcz to onboot.lst
after you login check:
tc@box:~$ sudo ck-history --last
tc Session1 Seat1 tty2 :0.0 Fri Aug 3 14:13 still logged in
Log begins Fri Aug 3 14:13:09 2012
-
what is all this consoleshit, has it already spread into tinycore base?
-
has it already spread into tinycore base?
No and won't on my watch ;) I'm sure the others feel that way too.
-
it is required by polkit to grant priviliges to run some applications like nm-applet
-
has it already spread into tinycore base?
No and won't on my watch ;) I'm sure the others feel that way too.
Agree, it is not needed in base.
-
what is all this consoleshit, has it already spread into tinycore base?
After reading:
Furthermore, ConsoleKit will run ~60 threads in the background, where most of them are never used. If you mind using an unmaintained application using so much threads and you only want a convenient way to mount disks as user, have a look at udev, udiskie and polkit. Otherwise you might consider switching to systemd.
that would never occur to me...
-
why don't include this instructions in the consolekit info file?
-
That's a very good idea.
-
script is updated (dbus-launch --exit-with-session is added if DBUS_SESSION_BUS_ADDRESS is not set)
and i will update ck soon
-
heh. that clear message makes me happy. But what if someday udev depends on d-bus, d-bus on systemd and systemd on policykit? will you guys stop using udev?
I sadly have to admit that I'm half-serious...
-
We'd use the last version of udev that doesn't need those, and if/when that becomes unsensible, look for alternatives.
The current situation is a bit similar, because the udev-to-systemd integration is not yet complete, so if I were to update udev right now, I'd have to use a tarball release from before the systemd integration.
It's looking a bit bad on that front, with both Lennart and Kay only caring about the systemd-integrated udev. There are some external contributors working on making the build-separate-udev-from-the-combined tree work as well as it did before, but I believe right now building only udev from the systemd tree wouldn't work fully.
-
Perhaps this might be of any interest?
http://connie.slackware.com/~rworkman/standalone-udev-from-systemd/
-
https://wiki.gentoo.org/wiki/Mdev
http://wiki.openwrt.org/doc/devel/packages/hotplug2