Welcome to Geeklog, Anonymous Thursday, March 28 2024 @ 09:00 am EDT

Geeklog Forums

Geeklog running on Sourceforge.net


Auspexian

Anonymous
Anyone successfully able to run Geeklog on their home page on sourceforge.net?

I have two projects, I installed geeklog on both, neither will allow login, cookies issue.
The exact sites can be run perfectly on my Linux Redhat system.

Tks

John
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by Auspexian: Anyone successfully able to run Geeklog on their home page on sourceforge.net?

Geeklog was on geeklog.sourceforge.net for quite a while

bye, Dirk
 Quote

auspexian

Anonymous
Thanks Dirk, I'll continue to debug :-)
 Quote

Status: offline

vinny

Site Admin
Admin
Registered: 06/24/02
Posts: 352
Location:Colorado, USA
Also gplugs...

-Vinny
 Quote

Status: offline

thelusiv

Forum User
Junior
Registered: 05/21/04
Posts: 23
Location:Clemson, SC
I'm setting up a Geeklog site on SourceForge and was wondering how you guys went about dealing with this:
Quote by sourceforge docs:The ability to send email from the project web servers has been stopped to curb past abuse that has occurred from the project web servers. However, we do realize that this is a valued and required feature for many projects hosted on SourceForge.net, so we have provided a method for a project to accomplish this task. At a high level, it would look like this:
The module of the project web service that requires the ability to send out mail would now be modified to queue the message to the project database.
A cron job would be configured to pull out and send the emails from the project shell server.


Do you have any useful scripts, tips, or anything else I should know that might help me set this up?
 Quote

Status: offline

Dirk

Site Admin
Admin
Registered: 01/12/02
Posts: 13073
Location:Stuttgart, Germany
Quote by thelusiv: Do you have any useful scripts, tips, or anything else I should know that might help me set this up?

How about using an SMTP server? That would be the easiest solution.

You can also write your own function to send email (in lib-custom.php, a sample function is included).

bye, Dirk
 Quote

Status: offline

thelusiv

Forum User
Junior
Registered: 05/21/04
Posts: 23
Location:Clemson, SC
Quote by Dirk:How about using an SMTP server? That would be the easiest solution.

I will try this. However, I thought I read in the Sourceforge docs about not being able to make outbound connections. Maybe I misunderstood something...
 Quote

Status: offline

thelusiv

Forum User
Junior
Registered: 05/21/04
Posts: 23
Location:Clemson, SC
I tried using an SMTP server but either SF.net is totally blocking outbound connections or my ISP doesn't allow me to use their SMTP server outside their network (even with authentication). So has no one ever done this DB mail cache and cron sending thing? I will take a crack at it tonight and see if I can set it up...
 Quote

Status: offline

thelusiv

Forum User
Junior
Registered: 05/21/04
Posts: 23
Location:Clemson, SC
It wasn't terribly hard to implement. I changed CUSTOM_mail to call my own mail function which inserted the mail data into a table in the database called gl_mailpool. The table has a field for an id number (mid), fields for subject, recipients, headers, body, and a flag to tell if this particular mail's been sent or not. I used this shell script as an hourly cron job to send the mail:

Text Formatted Code
 #!/usr/bin/php -q
<?php
include_once("../htdocs/lib-common.php");
$num_emails = DB_count("gl_mailpool","sent","0");
$result = DB_query("SELECT mid,recipients,subject,body,headers FROM gl_mailpool WHERE sent='0'");
for( $i = 0; $i < $num_emails; $i++ )
{
    $A = DB_fetchArray($result);
    system("echo \"{$A['body']}\" > tmpmailfile");
    system("mail -s \"{$A['subject']}\" {$A['recipients']} < tmpmailfile");
    echo "sent mail to: {$A['recipients']}\nsubject: {$A['subject']}\n";
    DB_query("UPDATE gl_mailpool SET sent='1' WHERE mid={$A['mid']}");
}
?>

 


So, as the mails are sent it flags them as sent in the database so they don't get sent more than once, and the output of the script is the recipients and subjects which I receive as output of the cron job. The mail program is about the only way SF provides to send mail and it doesn't really let me do anything to the headers but I don't think that's a big deal.

If anyone sees any obvious mistakes in this script or has a better way to do it I'm all ears. Smile
 Quote

BlackDex

Anonymous
So if im correct,
With this script ppl should be able to send mail through the sourceforge web-account???

 Quote

All times are EDT. The time is now 09:00 am.

  • Normal Topic
  • Sticky Topic
  • Locked Topic
  • New Post
  • Sticky Topic W/ New Post
  • Locked Topic W/ New Post
  •  View Anonymous Posts
  •  Able to post
  •  Filtered HTML Allowed
  •  Censored Content