Monday, March 31, 2008

» FTP server on openSUSE

Here's a quick and simplified version of the FTP Server HOWTO that's on the openSUSE wiki, in order to install and enable a passive FTP server on openSUSE. 1) Install the package vsftpd (ships with the standard OSS repository and media), using the following command from a shell as root:
zypper in vsftpd
(or smart install vsftpd, depending on your preferred package manager) 2) Enable the vsftpd init script at boot to have the FTP server automatically enabled when after booting, still in a shell as root:
chkconfig --add vsftpd
3) Start the vsftpd server now, to avoid rebooting to start it up, still in a shell as root:
rcvsftpd start
(note that you can use that rcvsftpd script to control the FTP daemon, followed by the self-explanatory commands start, stop, status, restart, ...) 4) Now here's the secret magic sauce: to enable FTP in the firewall, open the file /etc/sysconfig/SuSEfirewall2 in your favourite text editor, still as root, and do the following: 4.1) make sure ftp is mentioned in the variable FW_SERVICES_EXT_TCP, e.g. like this:
FW_SERVICES_EXT_TCP="http https ftp"
4.2) enable FTP connection tracking and NATing by setting the variable FW_LOAD_MODULES as follows:
FW_LOAD_MODULES="ip_conntrack_ftp ip_nat_ftp"
(actually, ip_nat_ftp is only needed if that server is acting as a reverse proxy (DNAT) to a real FTP server behind it, but it doesn't harm enabling it anyway, for the sake of simplicity) 5) Apply the firewall changes with the following command, again from a shell as root:
rcSuSEfirewall2 reload


Thursday, March 27, 2008

» osc plugin for coloured build results

Hacked a little osc (the CLI client for the openSUSE Build Service) plugin that produces a nice, ANSI-coloured, unicode-drawing-char-enabled output of a package's build results. Either just grab the file and copy it into /var/lib/osc-plugins/, or install the package osc-plugin-niceresults from my home:pbleser:osc repository in the openSUSE Build Service. To use it, just invoke osc nr (mnemonics: nr for "nice results", may also use cr instead) in your Build Service working directory, just as you would with osc results Oh, and the obligatory screenshots: