• 📢 Notice: Our community has moved to Zelo.cx! Visit us at Zelo.cx for the latest updates and discussions.

Need Simple SH script to run at startup

IgniteHost

Contributor
Contributor
IgniteHost Rep
0
0
0
Rep
866
IgniteHost Vouches
0
0
0
Vouches
0
Posts
1,050
Likes
707
Bits
2 YEARS
2 YEARS OF SERVICE
I never did it, im on a Debian 11 System.
I would like to have a screen created at startup, and make it run a nodejs command, so when i connect, i can just reattach the screen.
Anyone can give me a piece of code doing that ?
[Image: ignitehost-pro-signature.gif]
 
Rep
0
0
0
Rep
0
Vouches
0
0
0
Vouches
0
Posts
3
Likes
0
Bits
3 YEARS
3 YEARS OF SERVICE
ChatGPT will litzelolly solve this for you
[Image: tST0zMY.png]
FREE COMBOS -FREESTUFF

[Image: 0OjOKQT.gif]
JOIN FART CLUB TODAY
[Image: hPjExPx.png]
 

OpenBSD

Premium member
Premium
Rep
0
0
0
Rep
0
Vouches
0
0
0
Vouches
0
Posts
1
Likes
0
Bits
3 YEARS
3 YEARS OF SERVICE
Hi, you can do:
vim /etc/rc.local
type screen -d -m node (your node project)

rc.local is executed on startup, then launches a screen in detatched mode
 

48,736

38,247

238,888

Top