Own stuff

Dynamic firewall rules for iptables

Here's the problem: you're allowing access to some ports of your server based on source IPs. This is common practise, even if it's not 100% secure (since source IPs can be spoofed in certain situations). However what if you've no fixed source IP address(es) (which is common practise too) that you can feed into iptables rules? You can register a domain name at a dynamic DNS provider (eg. dyndns.org) and have your client (a DSL router or a client app on your PC) automatically update the IP of that domain name, whenever your client's internet connection get's up. But still, iptables does not allow use of domain names in firewall rules (and it's good so Smiling ). Here's where my script comes into play. It allows you to specify a list of domain names and destinations (host+port) for which the script will automatically generate permitting iptables rules.

Flash Media Server (FMS) monitoring with Munin

Munin is a great open source monitoring program available for a number of platforms. Flash Media Server (FMS) is a streaming server from Adobe aiming mainly at video playback in Flash applications (video players, video conference solutions, etc.). There was already a Munin plugin for FMS (monitoring the number of active connections) at MuninExchange, but the config parameters were hard-coded (in the plugin code) and it lacked documentation on usage and did not match the structure of standard Munin plugins. I've rewritten the plugin to come up for all these shortcomings. The new version of the plugin is available both attached to this post and at MuninExchange.

Picasa Web Albums random photo block in Drupal

There's already a picasa module for Drupal, but if you just want a random photo block and not the complete integration stuff (custom node type and nodes for all the photos), then you might find my module more attractive. Its use is pretty straightforward, set up the block as you'd do with any other block. The Picasa Web Albums user id can be specified in the blocks configuration page (along with a couple of other options).

Automatized online backup of MySQL databases using LVM snapshots

This is again a script that people could write easily if they understood some shell scripting, but it is quite well implemented with logging and all and maybe spares a couple of minutes/hours of your time. Smiling

You should use it with crontab on a daily basis. For details take a look at the desc. of the MySQL backup script.

A Nagy Dalmuti játékszabályai

A Nagy Dalmuti egy roppant szórakoztató kártyajáték. Sajnos csak német és angol változatban kapható (itthon tudtommal csak a német) és nem is létezik hozzá magyar leírás. Pontosabban nem létezett ... egészen eddig. Smiling Lefordítottam a német változat szabályait és csatoltam DOC, ODT és PDF formátumban. Jó szórakozást kívánok hozzá! Smiling

Automatized backup of files and directories

This is again a script that people could write easily if they understood some shell scripting, but it is quite well implemented with logging and all and maybe spares a couple of minutes/hours of your time. Smiling

You should use it with crontab on a daily basis. For details take a look at the desc. of the MySQL backup script.

MTK (Müzso Toolkit)

A client of my company asked for the customization of the JavaScript builtin confirm() dialogs: they wanted to replace the standard text ("OK" and "Cancel") on the dialog's buttons with "Yes" and "No" labels. I did some web-crawling on the topic and arrived at Steve's Custom Alert Demonstration. This was a good start, but it lacked several features that I was looking for, so I decided to write my own pseudo-modal dialog handler library. Smiling Take a look at the included example!

Automatized backup of MySQL databases

I was given the task to write a script that makes daily backups of our company's MySQL databases and keeps only the most recent <n> of them (where <n> is a positive integer Eye-wink ). This is not a big deal for anyone with some knowledge of shell scripting, but I publish it nonetheless, because I think the implementation is quite nice and might spare some minutes/hours for beginners.

Ripples - a 256 byte demo

I've learnt x86 assembly in the summer before I went to the university (1996). I saw that there're some 256-byte competitions in Hungary and tried to write my own little demo so I can enter, too. Smiling

Implementing "--parent" switch of the Linux "cp" command in a Windows batch script

The point of the "--parent" switch is to copy a file (or a directory) with it's parent directory structure to another directory. This is not exactly a trivial task in a Windows batch file and as such, it's a great opportunity to introduce some not very widespread features of the command prompt (eg. setlocal/endlocal, the "&" command separator, string operations).

Did I already mention that Windows sux? Sad
Batch scripting is so clumsy ... you have to write dozens of lines to get something that you can do within one line in any standard Unix/Linux shell. Shocked

Syndicate content