-
-
Notifications
You must be signed in to change notification settings - Fork 253
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Try to run script-server on ubuntu-server #781
Comments
Your docker mounts are possibly incorrect...
The /app/conf/whatever paths should be edited to wherever those conf files
live /in your live filesystem/. Same for the path to your scripts, you need
a location in your live filesystem to mount into the container. I don't
know if symlinks or hardlinks would work properly (so, like, creating a
repo directory of "scripts to present in SS", with links to wherever those
scripts live on the filesystem), or if you'll actually need to keep the
actual scripts in that directory, but you can troubleshoot that later.
…On Wed, Jan 29, 2025, 12:23 PM Adriano Palumbo ***@***.***> wrote:
Hi @bugy <https://github.com/bugy> congrats for this amazing tool.
I'm trying to use script-server for my job but i'm stuck in a loop. My
goal is to run the scripts present on a ubuntu-server machine from the
script-server broswer interface.
To do that I installed script-server on the remote machine and ran the
launcher in a docker container, as mentioned here
<#171 (comment)>.
Thanks to that I'm able to open the localhost:5000 page and run the scripts.
Screenshot.2025-01-29.180155.png (view on web)
<https://github.com/user-attachments/assets/2d91aea6-4707-49f6-8a21-66867e7d3f2d>
Now i have three problems:
1. When i close the ssh terminal, the web page crash
Screenshot.2025-01-29.180437.png (view on web)
<https://github.com/user-attachments/assets/7fb9d540-5a3e-46c4-9b18-260fe6156590>
2.
If I try to run the launcher.py as service, exactly as mentioned here
<https://github.com/bugy/script-server/wiki/Running-as-a-linux-service#systemd>,
the service does not start (or if start, when i close the terminal it
crash), whether I specify ExecStart with python command (ExecStart=sudo
/home/server/.python_venv/script-server/bin/python
/home/server/projects/script-server/launcher.py) or via docker
(ExecStart=/usr/bin/docker run -d -p 5000:5000 -v
/host/path/to/conf.json:/app/conf/conf.json -v
/host/path/to/runners/:/app/conf/runners -v
/host/path/to/scripts/:/app/custom_projects/ bugy/script-server:1.18.0
).
3.
The only web page that i can succesfully use is the localhost page and
not the ip server page. Infact, even if i specify the server ip in the
"address" field of conf.json, the page doesn't open.
For example this is my conf.json:
Screenshot.2025-01-29.181557.png (view on web)
<https://github.com/user-attachments/assets/d736da0c-6a68-4bef-a8fd-4736dd68e4f7>
I know these are a lot of questions, but your help would be greatly
appreciated.
Thanks
—
Reply to this email directly, view it on GitHub
<#781>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/A3HBI3SYRSZGRE4YVXYLEZD2NEFAVAVCNFSM6AAAAABWDMJR7CVHI2DSMVQWIX3LMV43ASLTON2WKOZSHAYTQOBRGE2TQOA>
.
You are receiving this because you are subscribed to this thread.Message
ID: ***@***.***>
|
Oops, got those backwards.
The /app/conf/* and /app/custom_projects are the mounts in the container.
The /host/path/to/* paths are the ones that need to point to the
outside-of-docker files on your filesystem.
…On Wed, Jan 29, 2025, 12:30 PM Mark Neill ***@***.***> wrote:
Your docker mounts are possibly incorrect...
The /app/conf/whatever paths should be edited to wherever those conf files
live /in your live filesystem/. Same for the path to your scripts, you need
a location in your live filesystem to mount into the container. I don't
know if symlinks or hardlinks would work properly (so, like, creating a
repo directory of "scripts to present in SS", with links to wherever those
scripts live on the filesystem), or if you'll actually need to keep the
actual scripts in that directory, but you can troubleshoot that later.
On Wed, Jan 29, 2025, 12:23 PM Adriano Palumbo ***@***.***>
wrote:
> Hi @bugy <https://github.com/bugy> congrats for this amazing tool.
> I'm trying to use script-server for my job but i'm stuck in a loop. My
> goal is to run the scripts present on a ubuntu-server machine from the
> script-server broswer interface.
> To do that I installed script-server on the remote machine and ran the
> launcher in a docker container, as mentioned here
> <#171 (comment)>.
> Thanks to that I'm able to open the localhost:5000 page and run the scripts.
>
> Screenshot.2025-01-29.180155.png (view on web)
> <https://github.com/user-attachments/assets/2d91aea6-4707-49f6-8a21-66867e7d3f2d>
>
> Now i have three problems:
>
> 1. When i close the ssh terminal, the web page crash
>
> Screenshot.2025-01-29.180437.png (view on web)
> <https://github.com/user-attachments/assets/7fb9d540-5a3e-46c4-9b18-260fe6156590>
>
> 2.
>
> If I try to run the launcher.py as service, exactly as mentioned here
> <https://github.com/bugy/script-server/wiki/Running-as-a-linux-service#systemd>,
> the service does not start (or if start, when i close the terminal it
> crash), whether I specify ExecStart with python command (ExecStart=sudo
> /home/server/.python_venv/script-server/bin/python
> /home/server/projects/script-server/launcher.py) or via docker
> (ExecStart=/usr/bin/docker run -d -p 5000:5000 -v
> /host/path/to/conf.json:/app/conf/conf.json -v
> /host/path/to/runners/:/app/conf/runners -v
> /host/path/to/scripts/:/app/custom_projects/ bugy/script-server:1.18.0
> ).
> 3.
>
> The only web page that i can succesfully use is the localhost page
> and not the ip server page. Infact, even if i specify the server ip in the
> "address" field of conf.json, the page doesn't open.
> For example this is my conf.json:
>
> Screenshot.2025-01-29.181557.png (view on web)
> <https://github.com/user-attachments/assets/d736da0c-6a68-4bef-a8fd-4736dd68e4f7>
>
> I know these are a lot of questions, but your help would be greatly
> appreciated.
> Thanks
>
> —
> Reply to this email directly, view it on GitHub
> <#781>, or unsubscribe
> <https://github.com/notifications/unsubscribe-auth/A3HBI3SYRSZGRE4YVXYLEZD2NEFAVAVCNFSM6AAAAABWDMJR7CVHI2DSMVQWIX3LMV43ASLTON2WKOZSHAYTQOBRGE2TQOA>
> .
> You are receiving this because you are subscribed to this thread.Message
> ID: ***@***.***>
>
|
Hi @adripalu Regarding 1 and 2: how do you run script server? Do you just ssh and then run launcher from a command line? Regarding 3: did you try to run any other remote services? When you are in your ssh session, can you try |
Thanks for the answers @MNeill73 @bugy I also tried to run the launcher with nohup with the following commands: I'd like to have SS running as service (with docker o python script) to have it always up and running. Infact, the ultimate goal is to allow my colleagues to run my scripts on SS from their PCs when I'm not present in the lab |
Did you specify the port?
I think the correct way to go is to run script server as a service. Which error do you get, when you try to run it as a service? |
@bugy |
Run it as a python for simplicity |
This is my conf.json file
this is the script-server.service file:
actived with:
As you can see below, the service succesfully started and the web page works.
Again, when i close the ssh the web crash as the photo posted above. |
Just to double check: are you sure, that your server keeps running after you close ssh? |
Yes I'm 100% sure that the server keeps running after I close ssh. Anyway, the problem to the server ip still remain, infact i can connect only to localhost. |
to double-check, is |
Yes the IP is the same as the one I am trying to access. |
Hi @bugy congrats for this amazing tool.
I'm trying to use script-server for my job but i'm stuck in a loop. My goal is to run the scripts present on a ubuntu-server machine from the script-server broswer interface.
To do that I installed script-server on the remote machine and ran the launcher in a docker container, as mentioned here. Thanks to that I'm able to open the localhost:5000 page and run the scripts.
Now i have three problems:
If I try to run the launcher.py as service, exactly as mentioned here, the service does not start (or if start, when i close the terminal it crash), whether I specify ExecStart with python command (
ExecStart=sudo /home/server/.python_venv/script-server/bin/python /home/server/projects/script-server/launcher.py
) or via docker(
ExecStart=/usr/bin/docker run -d -p 5000:5000 -v /host/path/to/conf.json:/app/conf/conf.json -v /host/path/to/runners/:/app/conf/runners -v /host/path/to/scripts/:/app/custom_projects/ bugy/script-server:1.18.0
).The only web page that i can succesfully use is the localhost page and not the ip server page. Infact, even if i specify the server ip in the "address" field of conf.json, the page doesn't open.
For example this is my conf.json:
I know these are a lot of questions, but your help would be greatly appreciated.
Thanks
The text was updated successfully, but these errors were encountered: