[REBOL] Re: gi Script file access problem
From: rebol::svendx::dk at: 15-Nov-2000 18:10
Hello Tim,
As Jamey Cribbs pointed out, it's probably a permissions problem.
The safest thing would probably be to create a new directory (ie. /home/httpd/public-write)
and and read-/write-enable it for 'others'.
(It would probably be a bad idea to write-enable your cgi-bin directory...)
something like (in a shell):
mkdir /home/httpd/public-write
chmod o+rw /home/httpd/public-write
But then again, I'm no unix expert either, so...
On 15-Nov-00, you wrote:
> Hi:
> Am new to linux and apache.
> I am running the following script on through apache:
> ;> #!/usr/bin/rebol -cs
> REBOL[]
> print "Content-Type: text/html^/^/"
> debug-port: open/new/write make file! "test.txt"
> close debug-port
>
> running this from rebol command line as
> do %testcgi.r
> performs without error message.
>
> Running this as a cgi script ie.
> http://localhost/cgi-bin/testcgi.r
>
> returns the following error message from rebol:
> ** Access Error: Cannot open /home/httpd/cgi-bin/test.txt.
> ** Where: debug-port: open/new/write make file! "test.txt"
>
> subsitituting
> write %test.txt "line one"
>
> returns the following error message from rebol:
> ** Access Error: Cannot open /home/httpd/cgi-bin/test.txt.
> ** Where: write %test.txt "line one"
>
> I'm guessing I need to do something with the apache configuration.
> Does anyone know what needs to be done?
> TIA
> -Tim
>
Best regards
Thomas Jensen