- root@backend-5d4bb8c4d8-bvsh4:/var/www/html# apt-get install supervisor
- Reading package lists... Done
- Building dependency tree... Done
- Reading state information... Done
- Suggested packages:
- supervisor-doc
- The following NEW packages will be installed:
- supervisor
- 0 upgraded, 1 newly installed, 0 to remove and 33 not upgraded.
- Need to get 309 kB of archives.
- After this operation, 1738 kB of additional disk space will be used.
- Get:1 http://deb.debian.org/debian bullseye/main amd64 supervisor all 4.2.2-2 [309 kB]
- Fetched 309 kB in 0s (3159 kB/s)
- debconf: delaying package configuration, since apt-utils is not installed
- Selecting previously unselected package supervisor.
- (Reading database ... 36005 files and directories currently installed.)
- Preparing to unpack .../supervisor_4.2.2-2_all.deb ...
- Unpacking supervisor (4.2.2-2) ...
- Setting up supervisor (4.2.2-2) ...
- invoke-rc.d: could not determine current runlevel
- invoke-rc.d: policy-rc.d denied execution of start.
- Created symlink /etc/systemd/system/multi-user.target.wants/supervisor.service → /lib/systemd/system/supervisor.service.
- root@backend-5d4bb8c4d8-bvsh4:/var/www/html# cd /etc/supervisor/conf.d/ && touch messenger-consume.conf && apt-get install vim && vim messenger-consume.conf
- Reading package lists... Done
- Building dependency tree... Done
- Reading state information... Done
- The following additional packages will be installed:
- vim-common vim-runtime xxd
- Suggested packages:
- ctags vim-doc vim-scripts
- The following NEW packages will be installed:
- vim vim-common vim-runtime xxd
- 0 upgraded, 4 newly installed, 0 to remove and 33 not upgraded.
- Need to get 8138 kB of archives.
- After this operation, 36.9 MB of additional disk space will be used.
- Do you want to continue? [Y/n]
- Get:1 http://deb.debian.org/debian bullseye/main amd64 xxd amd64 2:8.2.2434-3+deb11u1 [192 kB]
- Get:2 http://deb.debian.org/debian bullseye/main amd64 vim-common all 2:8.2.2434-3+deb11u1 [226 kB]
- Get:3 http://deb.debian.org/debian bullseye/main amd64 vim-runtime all 2:8.2.2434-3+deb11u1 [6226 kB]
- Get:4 http://deb.debian.org/debian bullseye/main amd64 vim amd64 2:8.2.2434-3+deb11u1 [1494 kB]
- Fetched 8138 kB in 0s (22.1 MB/s)
- debconf: delaying package configuration, since apt-utils is not installed
- Selecting previously unselected package xxd.
- (Reading database ... 36148 files and directories currently installed.)
- Preparing to unpack .../xxd_2:8.2.2434-3+deb11u1_amd64.deb ...
- Unpacking xxd (2:8.2.2434-3+deb11u1) ...
- Selecting previously unselected package vim-common.
- Preparing to unpack .../vim-common_2:8.2.2434-3+deb11u1_all.deb ...
- Unpacking vim-common (2:8.2.2434-3+deb11u1) ...
- Selecting previously unselected package vim-runtime.
- Preparing to unpack .../vim-runtime_2:8.2.2434-3+deb11u1_all.deb ...
- Adding 'diversion of /usr/share/vim/vim82/doc/help.txt to /usr/share/vim/vim82/doc/help.txt.vim-tiny by vim-runtime'
- Adding 'diversion of /usr/share/vim/vim82/doc/tags to /usr/share/vim/vim82/doc/tags.vim-tiny by vim-runtime'
- Unpacking vim-runtime (2:8.2.2434-3+deb11u1) ...
- Selecting previously unselected package vim.
- Preparing to unpack .../vim_2:8.2.2434-3+deb11u1_amd64.deb ...
- Unpacking vim (2:8.2.2434-3+deb11u1) ...
- Setting up xxd (2:8.2.2434-3+deb11u1) ...
- Setting up vim-common (2:8.2.2434-3+deb11u1) ...
- Setting up vim-runtime (2:8.2.2434-3+deb11u1) ...
- Setting up vim (2:8.2.2434-3+deb11u1) ...
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/vim (vim) in auto mode
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/vimdiff (vimdiff) in auto mode
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/rvim (rvim) in auto mode
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/rview (rview) in auto mode
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/vi (vi) in auto mode
- update-alternatives: warning: skip creation of /usr/share/man/da/man1/vi.1.gz because associated file /usr/share/man/da/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/de/man1/vi.1.gz because associated file /usr/share/man/de/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/fr/man1/vi.1.gz because associated file /usr/share/man/fr/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/it/man1/vi.1.gz because associated file /usr/share/man/it/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ja/man1/vi.1.gz because associated file /usr/share/man/ja/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/pl/man1/vi.1.gz because associated file /usr/share/man/pl/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ru/man1/vi.1.gz because associated file /usr/share/man/ru/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/man1/vi.1.gz because associated file /usr/share/man/man1/vim.1.gz (of link group vi) doesn't exist
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/view (view) in auto mode
- update-alternatives: warning: skip creation of /usr/share/man/da/man1/view.1.gz because associated file /usr/share/man/da/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/de/man1/view.1.gz because associated file /usr/share/man/de/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/fr/man1/view.1.gz because associated file /usr/share/man/fr/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/it/man1/view.1.gz because associated file /usr/share/man/it/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ja/man1/view.1.gz because associated file /usr/share/man/ja/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/pl/man1/view.1.gz because associated file /usr/share/man/pl/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ru/man1/view.1.gz because associated file /usr/share/man/ru/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/man1/view.1.gz because associated file /usr/share/man/man1/vim.1.gz (of link group view) doesn't exist
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/ex (ex) in auto mode
- update-alternatives: warning: skip creation of /usr/share/man/da/man1/ex.1.gz because associated file /usr/share/man/da/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/de/man1/ex.1.gz because associated file /usr/share/man/de/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/fr/man1/ex.1.gz because associated file /usr/share/man/fr/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/it/man1/ex.1.gz because associated file /usr/share/man/it/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ja/man1/ex.1.gz because associated file /usr/share/man/ja/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/pl/man1/ex.1.gz because associated file /usr/share/man/pl/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ru/man1/ex.1.gz because associated file /usr/share/man/ru/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/man1/ex.1.gz because associated file /usr/share/man/man1/vim.1.gz (of link group ex) doesn't exist
- update-alternatives: using /usr/bin/vim.basic to provide /usr/bin/editor (editor) in auto mode
- update-alternatives: warning: skip creation of /usr/share/man/da/man1/editor.1.gz because associated file /usr/share/man/da/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/de/man1/editor.1.gz because associated file /usr/share/man/de/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/fr/man1/editor.1.gz because associated file /usr/share/man/fr/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/it/man1/editor.1.gz because associated file /usr/share/man/it/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ja/man1/editor.1.gz because associated file /usr/share/man/ja/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/pl/man1/editor.1.gz because associated file /usr/share/man/pl/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/ru/man1/editor.1.gz because associated file /usr/share/man/ru/man1/vim.1.gz (of link group editor) doesn't exist
- update-alternatives: warning: skip creation of /usr/share/man/man1/editor.1.gz because associated file /usr/share/man/man1/vim.1.gz (of link group editor) doesn't exist
- Processing triggers for hicolor-icon-theme (0.17-2) ...
- root@backend-5d4bb8c4d8-bvsh4:/etc/supervisor/conf.d# adduser appuser
- Adding user `appuser' ...
- Adding new group `appuser' (1000) ...
- Adding new user `appuser' (1000) with group `appuser' ...
- Creating home directory `/home/appuser' ...
- Copying files from `/etc/skel' ...
- New password:
- Retype new password:
- passwd: password updated successfully
- Changing the user information for appuser
- Enter the new value, or press ENTER for the default
- Full Name []:
- Room Number []:
- Work Phone []:
- Home Phone []:
- Other []:
- Is the information correct? [Y/n]
- root@backend-5d4bb8c4d8-bvsh4:/etc/supervisor/conf.d# usermod -aG sudo appuser
- root@backend-5d4bb8c4d8-bvsh4:/etc/supervisor/conf.d# su - appuser
- appuser@backend-5d4bb8c4d8-bvsh4:~$ /etc/bin/supervisord -c /etc/supervisor/supervisord.conf
- -bash: /etc/bin/supervisord: No such file or directory
- appuser@backend-5d4bb8c4d8-bvsh4:~$ /usr/bin/supervisord -c /etc/supervisor/supervisord.conf
- Traceback (most recent call last):
- File "/usr/bin/supervisord", line 33, in <module>
- sys.exit(load_entry_point('supervisor==4.2.2', 'console_scripts', 'supervisord')())
- File "/usr/lib/python3/dist-packages/supervisor/supervisord.py", line 359, in main
- go(options)
- File "/usr/lib/python3/dist-packages/supervisor/supervisord.py", line 369, in go
- d.main()
- File "/usr/lib/python3/dist-packages/supervisor/supervisord.py", line 72, in main
- self.options.make_logger()
- File "/usr/lib/python3/dist-packages/supervisor/options.py", line 1494, in make_logger
- loggers.handle_file(
- File "/usr/lib/python3/dist-packages/supervisor/loggers.py", line 419, in handle_file
- handler = RotatingFileHandler(filename, 'a', maxbytes, backups)
- File "/usr/lib/python3/dist-packages/supervisor/loggers.py", line 213, in __init__
- FileHandler.__init__(self, filename, mode)
- File "/usr/lib/python3/dist-packages/supervisor/loggers.py", line 160, in __init__
- self.stream = open(filename, mode)
- PermissionError: [Errno 13] Permission denied: '/var/log/supervisor/supervisord.log'
- appuser@backend-5d4bb8c4d8-bvsh4:~$ sudo /usr/bin/supervisord -c /etc/supervisor/supervisord.conf
- -bash: sudo: command not found
- appuser@backend-5d4bb8c4d8-bvsh4:~$ apt-get install sudo
- E: Could not open lock file /var/lib/dpkg/lock-frontend - open (13: Permission denied)
- E: Unable to acquire the dpkg frontend lock (/var/lib/dpkg/lock-frontend), are you root?
- appuser@backend-5d4bb8c4d8-bvsh4:~$ sudo /usr/bin/supervisord -c /etc/supervisor/supervisord.conf
- We trust you have received the usual lecture from the local System
- Administrator. It usually boils down to these three things:
- #1) Respect the privacy of others.
- #2) Think before you type.
- #3) With great power comes great responsibility.
- [sudo] password for appuser:
- appuser@backend-5d4bb8c4d8-bvsh4:~$ supervisorctl start messenger-consume:*
- error: <class 'PermissionError'>, [Errno 13] Permission denied: file: /usr/lib/python3/dist-packages/supervisor/xmlrpc.py line: 560
- appuser@backend-5d4bb8c4d8-bvsh4:~$ sudo supervisorctl start messenger-consume:*
- messenger-consume:messenger-consume_00: ERROR (spawn error)
- appuser@backend-5d4bb8c4d8-bvsh4:~$ sudo supervisorctl start messenger-consume:*
- messenger-consume:messenger-consume_00: ERROR (spawn error)
- appuser@backend-5d4bb8c4d8-bvsh4:~$ sudo supervisorctl reload
- Restarted supervisord
- appuser@backend-5d4bb8c4d8-bvsh4:~$ sudo supervisorctl start messenger-consume:*
- appuser@backend-5d4bb8c4d8-bvsh4:~$