Custom-services.d script running but not executing


I am attempting to use the custom-services.d feature to run a service/script. Which is an awesome feature BTW! The script gets picked up and appears to be running according to a ps -aux, however, the script does nothing. I appreciate that you do not offer support for the functionality of custom scripts and reasons for doing so. I am simply looking for an answer as to why the script doesn’t appear to be functioning at the basic level. For the sake of a simple test please see the test script below and it’s setup. Nothing is written to the /tmp/ file. If, however, I execute the script manually from the command line (/config/custom-services.d/my_test_script &) it works and random strings are appended to the /tmp/ file.

Thank you

root@smokeping:/# ls -alF /config/custom-services.d/
total 12
drwxrwxr-x 2 abc abc 4096 Nov  8 16:53 ./
drwxr-xr-x 6 abc abc 4096 Nov  9 15:43 ../
-rwxrwxr-x 1 abc abc  292 Nov  8 16:53 my_test_script*

root@smokeping:/# ps -aux
root         272  0.0  0.0    196     4 ?        S    15:29   0:00 s6-supervise custom-service-my_test_script

root@smokeping:/# cat /config/custom-services.d/my_test_script
#!/usr/bin/with-contenv bash

while true
  RAND_STR=`cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1`
  echo $RAND_STR >> /tmp/
  sleep 10

root@smokeping:/# cat /tmp/ 

Bump… Any ideas on this issue I have? Thank you

i would recommend joining our discord and asking in #linux-chat or #other-support to get some assistance with this


Umm, thanks!, but I’m confused, I thought that’s exactly were I was. The URL of this site/page is

And I thought this was completely on topic, it’s a Docker container related issue.

Oh wait, you said discord. So I guess I would say or suggest that this forum be taken down if it’s a dead resource. Don’t know why it would be a direct link off the site if it’s not being used.

But thank you for your direction.

Hmm, maybe again I spoke too soon. I found the site which has in big bold type “ Discord Server”. I click the Forums link at the top and it brings me right back to this domain/forum where this/my question is posted. And I don’t see the other categories #linux-chat or #other-support you mention.

discourse is the forum, discord is the chat platform.

Your issue sounds more appropriate for a chat so discord is recommended in this case. Forums are great for quick q&a, but not that great for a lot of back and forth.

Ok, I found it. But when I do a Google Search for the discord server I get a top result of the below, which ultimately ends up back here. I finally went back to the Linuxserver’s Home Page and found a link under Support. Sorry for my confusion, but have to say there’s a bit too much round robin with Linuxserver links in this case. Discord Server › 2017/09/15 › linuxserver-io-disco...

Sep 15, 2017 — *LinuxServer*.*io Discord* Server. We would like to announce that we now have a Discord Server! Please come and join us at: https://discord

Well s**t, I find the Discord channel, read the #rules and there’s no Thumbs up link or button to click so I can’t post a message. What am I missing? I’ve not been a Discord user soooooo would be looking for a “Thumbs Up” button or link with the #rules. Appreciate your patience…

I have faith that you will figure it out, telling you would be an insult to you. We look forward to chatting with you!

For a hint… what told you to read the rules?

Ok, I did figure it out given the hint. Thanks! But respectfully, I’m on old man. Yes I’m a 35 yr IT vet, managed an ISP datacenter for 12 years, and written 100s or 1000’s of lines of code from Cobal, Fortran down to Java, Ruby, Perl, Python, etc., but that doesn’t make Social items on pages obvious. It was only after I went back and hovered over the box with a number and a thumb and saw a mouse pointer and clicked it that I moved forward. It really only looks like a piece of information with counters, not a clearly defined place to click to like and move forward. I know the text says click on the THUMB to react, but I was looking for something more clear, like a separate thumb. I’m only taking the time to write because of the frigin days/hours I’ve spent trying to get an answer to a simple question, for which I posed on a forum set up and hosted to post questions only find it’s a dead end and then struggle to move on to the “official” place ask my question. Forgive the frustration, but didn’t think the road would be this bumpy.

Hey man, glad you figured it out, like i said I had faith in you. I’m only a 22year IT vet, but IT is always a bumpy road, i wouldn’t expect a paradigm change :wink: Anyway, discord is definitely a much faster place for questions like this as our forum is mostly dead.

as a side note, 1000s of lines in cobal isn’t really impressive man, takes a hundred to hello world :stuck_out_tongue: thank god that language mostly died out, though there was some money to be made in y2k saving company’s bacon from cobol. note: I am teasing, though cobol really was horrid.

Hey, thanks for the support man! Sorry for my lack of patience earlier. And my bad, it meant to read “100s of 1000’s”. I didn’t want to say millions, that might have been bragging, even exaggerating, but close :slight_smile: . Though my last Perl project was 60k+ lines. I don’t miss Cobal or Fortran. Now I love my Python and Ruby.

* simple thank you program
    DISPLAY 'Thanks @driz!'.
1 Like