ION

October 14th, 2008

Ion is a tiling tabbed window manager designed with keyboard users in mind.

Ion is an awesome minimalist window manager that let’s you get job done without wearing out your mouse. That is right, you can do everything with your keyboard. Throw that cheap mouse away.

Some quick shortcuts:

F2 - open the default terminal
F3 - run a command
Mod1-s - split a frame in half vertically
Mod1-k s - split a frame in half horizontally
Mod1-n - move vertically between frames
Mod1-tab - move horizontally between frames
Mod1-k x - kill the current frame

SSHMenu

October 9th, 2008

If you are a system administrator, there is a good chance that you have hundreds of servers to maintain. It can be quite hard to remember the hostnames of each individual one. On Windows, there are Putty and SecureCRT. Both applications solve this problem really well, as you can save the individual ssh sessions. SecureCRT even allows you to automate the login process for each session.

If you happen to be running GNU/Linux on your workstation, SSHMenu can help out. SSHMenu is a GNOME panel applet that keeps all your regular SSH connections within a single mouse click.

This solution is not as good as SecureCRT for example, but it is free and pretty easy to use.

Free book: Getting Started With Adobe Flex 3

July 25th, 2008

For anyone interested in development with Adobe Flex, Sitepoint is giving away a free book for the next 60 days.

Click here for more information (sitepoint.com)

Link of the day: Lazy Linux: 10 essential tricks for admins

July 25th, 2008

Learn these 10 tricks and you’ll be the most powerful Linux® systems administrator in the universe…well, maybe not the universe, but you will need these tips to play in the big leagues. Learn about SSH tunnels, VNC, password recovery, console spying, and more. Examples accompany each trick, so you can duplicate them on your own systems.

link

cPanel Presentation Slides from Conference 08

July 25th, 2008

If you run hosting servers with cPanel, here is a great resource to check out:

Presentation Slides from Conference 08

Especially useful presentation is Exim & Spam which goes into details on how to maintain exim on cPanel servers.

On the same link you can also find more information regarding new cPanel for Windows Server 08.

Setting up Lighttpd + web.py on CentOS 5

July 25th, 2008

After playing for a while with python, easy and neat programming language, I was curious how easy (or hard) would it be to develop web application in it. Looking around google, there is a huge list of web frameworks that is ready for use, but most of them are way too big for this purpose.

Until I found web.py, small, simple and powerful python based web framework with not so great documentation. After playing around for a while, it was time to deploy this puppy onto my VPS with preinstalled CentOS 5.x. Here is a short and easy guide how to setup fully functional web.py enviroment with lighttpd, mysql and flup for fastcgi.

web.py & flup
To install web.py, we will use easy_install.

# wget http://peak.telecommunity.com/dist/ez_setup.py
# python ez_setup.py
# easy_install web.py

Flup

# wget http://www.saddi.com/software/flup/dist/flup-1.0.tar.gz
# tar xvzf flup-1.0.tar.gz ; cd flup-1.0
# python setup.py install

Install lighttpd & fastcgi
First, we need to setup rpmforge repository which contains lighttpd and fastcgi rpms. Then we install them with yum.

# rpm -Uhv http://apt.sw.be/redhat/el5/en/i386/rpmforge/RPMS/rpmforge-release-0.3.6-1.el5.rf.i386.rpm
# yum -y install lighttpd lighttpd-fastcgi mysql-server
# chkconfig --levels 235 lighttpd on
# chkconfig --levels 235 mysqld on
# /etc/init.d/lighttpd start
# /etc/init.d/mysqld start

Setup home directory for our web.py site
We will create folder called static where all static files such as images and css files will be stored.

# mkdir /home/oursite
# mkdir /home/oursite/static
# vi /etc/lighttpd/lighttpd.conf

In lighttpd.conf uncomment mod_fastcgi then go to the last line of the file (G in vi) and append:

include "oursite.conf"

Now let’s create oursite.conf

# vi /etc/lighttpd/conf/oursite.conf

oursite.conf:

$HTTP["host"] =~ "oursite\.com" {
        server.document-root        = "/home/oursite/"
        fastcgi.server = ( "/website.py" =>
        ((
                "socket" => "/tmp/fastcgi.socket",
                "bin-path" => "/home/oursite/website.py",
                "max-procs" => 1,
                "bin-environment" => (
                "REAL_SCRIPT_NAME" => ""
                ),
                "check-local" => "disable"
        ))
        )
 
        url.rewrite-once = (
                "^/favicon.ico$" => "/static/favicon.ico",
                "^/static/(.*)$" => "/static/$1",
                "^/(.*)$" => "/website.py/$1",
        )
}

Create our web.py application
As you noticed, in our lighttpd configuration file, we told lighttpd to access website.py file which will contain code for our web.py website. Here is hello world example from official web.py website.

website.py:

  import web
 
  urls = (
      '/(.*)', 'hello'
  )
 
  class hello:        
      def GET(self, name):
          i = web.input(times=1)
          if not name: name = 'world'
          for c in range(int(i.times)):
              print 'Hello,', name+'!'
 
  if __name__ == "__main__": web.run(urls, globals())

Save this file in /home/oursite/website.py

Restart lighttpd

# /etc/init.d/lighttpd restart

Now go to oursite.com (your real domain) and see your web.py powered website in action.

web.py website + documentation
lighttpd website + documentation