[Gambas-user] Running website from server

Moviga Technologies moviga at ...3488...
Tue Jun 30 20:23:38 CEST 2015


 

Den 26.06.2015 11:55, skrev Ian: 

> Randel,
> Don't forget to give your shell scripts an extension ie: myscript.gbw
> 
> Then let Apache ( or ngix ) know that it's a CGI script.
> 
> something like this: from the apache 000-default.conf on my web server
> 
> ScriptAlias /cgi-bin "/usr/lib/cgi-bin/"
> 
> <Directory "/usr/lib/cgi-bin/">
> AllowOverride None
> AddHandler cgi-script .gbw .gambas
> Options -Indexes +ExecCGI +FollowSymLinks
> Require all granted
> </Directory>
> 
> I've been able to get the single example to work but no other scripts 
> formatted for gbw3 appear to do so.
> I've been trying now for about 2 weeks with no success, so if you get it 
> working can you please let me know how you did it.
> Error logs from Apache give this as an error for any script ( other than 
> the example)
> "malformed header from script 'test3.gbw': Bad header: # Gambas Project 
> File 3.0,"
> 
> I've also tried .gambas control line applications but same deal.
> The Apache error log contains nothing and the access log seems to say 
> that it functioned correctly.
> But... the output is a blank page with no source code when you "view source"
> 
> One of the test scripts I've tried without any success.
> ========================
> #!/usr/bin/gbw3
> 
> <%
> private sRes As String
> Exec ["cat", "/proc/meminfo"] To sRes
> %>
> <html><body>
> <!-- Variable declaration must come before any HTML -->
> <ul>
> <li><%= sRes %></li>
> </ul>
> </body></html>
> ===========================
> 
> Also ensure that the symbolic link for gbw3 is set in :
> /usr/bin
> 
> ian at ...3489... /usr/bin $ ls -l gb*
> -rwxr-xr-x 1 root root 31568 Jun 20 12:10 gba3
> -rwxr-xr-x 1 root root 167184 Jun 20 12:10 gbc3
> lrwxrwxrwx 1 root root 11 Jun 20 12:10 gbh3 -> gbh3.gambas
> -rwxr-xr-x 1 root root 14873 Jun 7 21:26 gbh3.gambas
> -rwxr-xr-x 1 root root 31392 Jun 20 12:10 gbi3
> lrwxrwxrwx 1 root root 4 Jun 20 12:10 gbr3 -> gbx3
> lrwxrwxrwx 1 root root 11 Jun 7 21:26 gbs3 -> gbs3.gambas
> -rwxr-xr-x 1 root root 23230 Jun 7 21:26 gbs3.gambas
> *lrwxrwxrwx 1 root root 11 Jun 7 21:26 gbw3 -> gbs3.gambas*
> -rwxr-xr-x 1 root root 380664 Jun 20 12:10 gbx3
> 
> Also I've written a quick apache log viewer gambas app which will also 
> give you the modules loaded using 'apachectl'.
> Allow you to view the apache2.conf & the various other config files
> If you want a copy drop me a line - it's a quick & dirty app to help me 
> try an diagnose the issues I'm having
> getting Gambas scripts to run.
> 
> If you have any success please let me know.
> My Web server is Ubuntu 14.04
> Gambas is 3.7.90
> 
> Cheers,
> Ian Roper.

Sorry for the late reply Ian! I seem to have missed your reply. Thanks
for the detailed description! I will let you know if I figure it out. 

 



More information about the User mailing list