cia.vc reports

Talk among developers, and propose and discuss general development planning/tackling/etc... feature in this forum.
Post Reply
charlieg
Elite Mercenary
Elite Mercenary
Posts: 1329
Joined: Thu Mar 27, 2003 11:51 pm
Location: Manchester, UK
Contact:

cia.vc reports

Post by charlieg »

It would be cool to add the svn hook for cia.vc (I think it's called cia.navi.cx as well - they are one and the same thing) to add a way to track SVN commits and increase project visibility.

It takes a few secs to register an account there and a few secs to enable the svn hook for a Sourceforge project.
Free Gamer - free software games compendium and commentary!
FreeGameDev forum - open source game development community
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

Actually that cia script was on my list of things I wanted to do for the new web site...
ghoulsblade
Merchant
Merchant
Posts: 47
Joined: Wed Jun 20, 2007 7:13 pm
Location: Germany/Munich
Contact:

Post by ghoulsblade »

someone has already started the cia.cx page for the project. i filled in the repository url and added an irc bot.
please remove the "check every 15 minutes" flag when you have activated the sourceforge cia support =)
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

Yeah, I just started that project, but I set it up through sourceforge, so the hook script should contact them directly.

So I turned off the 15 minutes flag.
charlieg
Elite Mercenary
Elite Mercenary
Posts: 1329
Joined: Thu Mar 27, 2003 11:51 pm
Location: Manchester, UK
Contact:

Post by charlieg »

It's accessible as RSS so should be easy to add to the VS frontpage. :)
Free Gamer - free software games compendium and commentary!
FreeGameDev forum - open source game development community
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

The problem is more in the fact that sourceforge has an external firewall on their shell servers, making it hard to add an automated script.

But I found an easier method using svn log --xml which will generate a nice and simple XML file that can be formatted using a simple XML Stylesheet.

So that's all working, and that is what you see on the front page... the problem I'm having now is I can't figure out how to use crontab.

I added my script to crontab, and here it is:

Code: Select all

# WARNING: Every minute for debug purposes!!!

# Vega Strike: Get latest SVN log for display on home page.
* * * * * /bin/bash /home/groups/v/ve/vegastrike/htdocs/svnlog/grabsvnlog.sh
Any idea what might be wrong with this?

It never seems to even get to the running phase... I made a simple shell script to create a file in /tmp, and it wouldn't run that either.

Here is the aforementioned /svnlog/grabsvnlog.sh file.
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

Aha! Shoulda guessed.
sf.net site status wrote:( 2007-06-13 13:43:38 - Project Shell Service ) As of 2007-06-12 the cron service provided under the project shell service has been disabled. Ongoing systems problems have forced us to pull it offline until a suitable replacement can be developed. Accordingly, no estimate for when we'll restore service is being provided.
So CRON does in fact just not work at all... So I have to use a PHP method.

Should be simple, but Sourceforge's firewall seems to completely block off Web servers from even accessing other sourceforge servers, such as svn.sf.net. So...

So now it looks like the only solution is to take a server I own, download the XML log from there, and send it to a PHP script in a POST or PUT query.

Sounds messy, also is insecure (someone could then stick whatever content they want on our home page if they know where that updating PHP script is) but I can't think of a better way until they fix Cron.
charlieg
Elite Mercenary
Elite Mercenary
Posts: 1329
Joined: Thu Mar 27, 2003 11:51 pm
Location: Manchester, UK
Contact:

Post by charlieg »

Um, cia.vc is integrated into Sourceforge SVN. Set up the python hook and it should work. Then, from cia.vc, VS commits will be avialable via RSS which is easy to add to the website.
Free Gamer - free software games compendium and commentary!
FreeGameDev forum - open source game development community
ace123
Lead Network Developer
Lead Network Developer
Posts: 2560
Joined: Sun Jan 12, 2003 9:13 am
Location: Palo Alto CA
Contact:

Post by ace123 »

It's finally done.

I wasted too much time on simple stuff. So many systems seem to be crippled of one feature or another that required figuring out a different way of doing it.
For example, I was trying to use PHP to read the POST data, but it kept trying to expand it as urlencoded. But finally, I realized that a shell script CGI program would work just fine, so I had to redo some of the logic.

It was kind of like a maze, and I had to find a path from start (downloading the XML) to the finish (saved an HTML segment on vegastrike.sf.net).

Yes, as you said, it should have been simple, but I kept hitting really trivial but annoying stumbling blocks such as an outgoing firewall, no crontab scripting and so on.
Post Reply