Unicorn.conf.rb attach account

Hello,

Why the processes are attached to my personal account ?

johan  123738  0.0  0.2  41852  4488 ?        S    déc.21   0:22 /bin/bash config/unicorn_launcher -E production -c config/unicorn.conf.rb
johan  123756  0.0  7.1 434420 147132 ?       Sl   déc.21   1:13 unicorn master -E production -c config/unicorn.conf.rb                                              
johan  123800  0.4 16.0 1773016 329072 ?      Sl   déc.21   5:53 sidekiq 4.1.2 discourse [0 of 5 busy]                                                               
johan  123841  0.1 14.2 1658924 290712 ?      Sl   déc.21   2:22 unicorn worker[0] -E production -c config/unicorn.conf.rb                                           
johan  123872  0.1 14.0 1651756 287492 ?      Sl   déc.21   2:24 unicorn worker[1] -E production -c config/unicorn.conf.rb                                           
johan  123916  0.1 13.9 1648680 285884 ?      Sl   déc.21   2:16 unicorn worker[2] -E production -c config/unicorn.conf.rb                                           
johan  123998  0.2 17.0 1717432 349280 ?      Sl   déc.21   2:57 unicorn worker[3] -E production -c config/unicorn.conf.rb                                           
johan   41871  0.0  0.1  27876  3316 ?        S    11:59   0:00 sleep 1

Thanks

Are you looking from outside docker? To see the correct user of process you need to enter the docker container first.

1 Like

Yes it’s outside docker, i dont understand why this processes are started with my account.

They aren’t, it’s an artifact of user id inside the container being used outside it. Go inside the container and run top again.

5 Likes

Hello @Falco,
Inside the container it’s the discourse user.

discour+    117     73  0 Dec21 ?        00:11:19 sidekiq 4.1.2 discourse [0 of 5 busy]
discour+    158     73  0 Dec21 ?        00:04:39 unicorn worker[0] -E production -c config/unicorn.conf.rb
discour+    189     73  0 Dec21 ?        00:04:48 unicorn worker[1] -E production -c config/unicorn.conf.rb
discour+    233     73  0 Dec21 ?        00:04:35 unicorn worker[2] -E production -c config/unicorn.conf.rb
discour+    315     73  0 Dec21 ?        00:05:47 unicorn worker[3] -E production -c config/unicorn.conf.rb

What do I must understand ?
Thanks

It is a quirk of how containers (Docker) work on Linux. You can think of the container as being a second system running. From outside the container, processes can be seen, but the metadata like account names is not visible. In your case the inside user id (UID) matches your outside UID, so tools like ps, top, etc guess that it is yours.

3 Likes

Ok Thank’s you …