randomguy Posted December 29, 2016 Posted December 29, 2016 hi,I have a simple ruby cgi script that I want to be able to use via helio web-server. It is working ok on my linux machine. Where exactly should I upload this cgi script? The cgi-bin folder or the public_html folder? My script includes the following shebang: #!/usr/local/bin/ruby. Do I need to change permissions on the script file? So far I've not been able to execute/access it from either cgi-bin or public_html.Thanks.
randomguy Posted December 29, 2016 Author Posted December 29, 2016 I've uploaded another script with the following shebang: #!/usr//bin/ruby. Sadly, still getting server error. I would really appreciate if anybody could help.
wolstech Posted December 29, 2016 Posted December 29, 2016 What server are you on, and what is your username?
Krydos Posted December 29, 2016 Posted December 29, 2016 Create public_html/cgi-bin/test.rbGive it 755 permissionsPut the following contents#!/usr/bin/ruby puts "Content-Type: text/html\n\n" puts "Ruby is working as CGI..." Here is my example file on Johnny http://krydos1.heliohost.org/cgi-bin/test.rb 1
randomguy Posted December 29, 2016 Author Posted December 29, 2016 Thanks @Krydos for your tips, the script is up and running.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now