Launcher permission denied error after rebuilding with typo in app.yml

(Tobias Eigen) #1

I just broke my discourse instance, it appears, and I am stumped. I’d be grateful for any pointers.

I wrote a typo in my app.yml file when seeking to install @lightyear’s promising checklist plugin (git pull git pull URL). Now for some reason when I try ./launcher rebuild app I get the following.

root@discourse:/var/discourse# ./launcher rebuild app
-bash: ./launcher: Permission denied

Here’s the result of the first attempt rebuilding before fixing the typo:

root@discourse:/var/discourse# ./launcher rebuild app
WARNING: No swap limit support
Updating discourse docker
remote: Counting objects: 16, done.
remote: Compressing objects: 100% (9/9), done.
remote: Total 16 (delta 7), reused 13 (delta 7)
Unpacking objects: 100% (16/16), done.
   074f2b6..583397f  master     -> origin/master
Updating 074f2b6..583397f
 launcher               | 51 ++++++++++++++++++++++++++++++++++-----------------
 samples/standalone.yml |  2 +-
 samples/web_only.yml   |  1 +
 3 files changed, 36 insertions(+), 18 deletions(-)
 mode change 100755 => 100644 launcher
Stopping old container
(<unknown>): found a tab character that violate intendation while scanning a plain scalar at line 62 column 13 -e LANG=en_US.UTF-8
YAML syntax error. Please check your /var/docker/containers/*.yml config files.

(Jeff Atwood) #2

Looks like an extra tab character on line 62. Try an editor that can visualize tabs and white space to find it.

(Tobias Eigen) #3

thanks but that’s not my problem anymore - I have been able to see my typo in the app.yml file and fixed it, and now since I ran it and got that error above I get a “permission denied” error when I run ./launcher. No matter what I do with the app.yml file. I am stumped.

(Jeff Atwood) #4

Hmm, odd, someone with more Unix experience than me will need to chime in. Did you verify permissions on the launcher exe did not change? Are you logged in as root?

(Tobias Eigen) #5

yes, logged in as root and I didn’t do anything to the permissions. All I did was change app.yml and run ./launcher rebuild app, got that error above, then went back to fix it and then run it again. Then started getting the permission denied error. At a loss.

(Tobias Eigen) #6

What is the permission supposed to be for the /var/discourse/launcher? Should it be 744? On my site below is how permissions look right now - seems not to be executable. Why/how would that happen? Maybe the executable bit gets flipped during the rebuild but did not get flipped back when the error occurred?

root@discourse:/var/discourse# ls -la
total 72
drwxr-xr-x 11 root root  4096 Oct 20 10:52 .
drwxr-xr-x 13 root root  4096 Sep  8 16:04 ..
drwxr-xr-x  2 root root  4096 Jul 18 18:37 bin
drwxr-xr-x  2 root root  4096 Oct 12 19:29 cids
drwxr-xr-x  2 root root  4096 May 10 13:18 containers
drwxr-xr-x  8 root root  4096 Oct 20 10:52 .git
-rw-r--r--  1 root root    63 Jul 18 18:37 .gitignore
drwxr-xr-x 10 root root  4096 Sep  8 16:05 image
-rw-r--r--  1 root root 14553 Oct 20 10:52 launcher
-rw-r--r--  1 root root  7655 Oct 12 19:23
drwxr-xr-x  2 root root  4096 Oct 20 10:52 samples
drwxr-xr-x  2 root root  4096 Sep  8 16:05 scripts
drwxr-xr-x  3 root root  4096 May 10 13:29 shared
drwxr-xr-x  2 root root  4096 Oct 12 19:23 templates

Edit: Ok, I changed permissions to make launcher executable and was able to rebuild and restart my discourse. But still seems to me this is something for your team to look into since it shouldn’t have happened just because of a parsing error in app.yml?

(James Milligan) #7

For reference, this is what it looks like on my box @tobiaseigen:

root@forum:/var/discourse# ls -al | grep launcher -rwxr-xr-x 1 root root 14308 Oct 18 09:05 launcher

(Sam Saffron) #8

a bug in a PR I merged


fixed, pull latest

(Jeff Atwood) #9

Oh wow sorry about that @tobiaseigen!

(Jeff Atwood) #10