LC Server - HTTP response code 500: permission denied error

Martin Koob mkoob at rogers.com
Mon Feb 10 13:18:04 EST 2020


Hi

I asked this question on LiveCode forums and haven’t go much response.  
LC Server returns 'lscgid: execve():/home/myapp/sites/api.myapp.com/cgi-bin/livecode-server: No such file or Directory <http://forums.livecode.com/viewtopic.php?p=187834&sid=170f8ce7549c8cdec2fc227d0315509c#p187829>



So I am reposting the question here.  Hope that is OK.

Here is the question.

——————————————
I use LiveCode Server for a REST api for a LiveCode application and I am migrating an installation of the api to a new server with a new domain.
The API uses Ralf Bitter's wonderful Revigniter framework. https://revigniter.com <https://revigniter.com/>

To to the transfer the site I copied all the files to the new server.

Then I changed all references to the domain the new domain in the API and the App.

When I tried to call the API from the App I got 'HTTP response code 500 returned from server’ but with a different error message
lscgid: execve():/home/myapp/sites/api.myapp.com/cgi-bin/livecode-server: Permission denied

I looked at the livecode-server executable in the path above and it had permissions set at 644. So I set the executable bit for all so permissions for livecode-server were 755. (The files in Drivers and External directories are still 644. Should they be changed to 755 too?)

Now I still get 'HTTP response code 500 returned from server’ but with a different error message:
- lscgid: execve():/home/mysite/sites/api.myapp.com/cgi-bin/livecode-server: No such file or directory

The API is using a REST approach.  

An example of how the App uses the api is to get LC Server to return a list of projects it is posting the session id as authentication to the URL https://api.myapp.com/myapp_db/listProjects

Using RevIgniter command rigFetchSegment(n) The API takes the first segment of the url ‘myapp_db’ as the name of the database and the the second segment of the URL 'listProjects' is the command being called in the API.

From the error being called it appears that the server is actually taking the path https://api.example.com/myappDB/listProjectsliterally, i.e. looks for that directory which does not exist and returns the error.

So since I copied the site to the new server I think I may have not have copied a config file correctly or there is a server setting I need to change so the REST URLs are dealt with correctly.

Does anyone have any ideas of how to resolve this?

Thanks in advance.

Martin Koob

VideoLinkwell, a service of
Koob SourceText Solutions Inc.








Regards,

Martin Koob








More information about the use-livecode mailing list