Hi,
I want to automatically start django server on remote server. For that i have created a robotframework-djangolibrary robot file. Manually on remote server if i run this robot file, the server starts and works fine… BUT, i want to run this robot file from another robot file on my pc.
So like remotely executing a robot file to start the django server.
I run and get the log info in log.html, but after checking on remote machine, server isn’t running.
While there are probably many ways this can be achieved, the most obvious that springs to mind for me is to use SSHLibrary, ssh to the machine where you have robotframework-djangolibrary working and run the robot command in the ssh session.
I am getting all green in the log.html also getting prompts for the django starting. BUT
when checking the remote machine, Server isn’t running.
I tried to run a simple python script for test, that didn’t work too man.
Not sure what to do now.
is the django environment getting stopped when the robot script exits on the remote machine or perhaps when the ssh session is closed all the processes under the ssh session are killed by the os?
Perhaps try adding an & to the end of the ${start_django_server} string
if the django server can be started as a service instead of a process under the logged in ssh user then that might solve the process
But if you go that far you can probably just set the service to start automatically when windows starts on the VM, so you might not need to ssh into it to start django unless you are doing some django configuration first, so this might solve the original issue as well.
Option 2
Another option is to use the windows start command (the windows equivalent of the & in *nix environments