mysql / mysql/mysql-shell-plugins
Extension fails to install in root only environment (docker container) without sudo installed
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 96
- Forks
- 22
- PR merge metrics
- No merged PRs in 30d
Description
The installation script seems to expect sudo to be installed, which it might not be in a minimal container with only a root user.
root@121f9f88f689:/app# id
uid=0(root) gid=0(root) groups=0(root)
root@121f9f88f689:/app# /root/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/install.sh
The MySQL Shell Web Root Certificate required by the MySQL for VS Code extension will now be installed on your system.
The following script will be executed. Some operations will require the sudo password , please review at your own discretion:
/root/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/install.sh
The script will perform the following operations:
- Install the following requirements:
- certutil
- NSS User Database
- Install the MySQL Shell GUI certificate at the following locations:
* - NSS User Database
Do you want to continue [Y/n] ?
Installing the certificate management utility: libnss3-tools
/root/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/install.sh: line 26: sudo: command not found
Failed installing libnss3-tools
Press any key to continue...
Since I already have root permission, the install script shouldn't fail.
As a temporary work around, I installed sudo and finished the install
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with /root/.mysqlsh-gui/plugin_data/gui_plugin/web_certs/install.sh, or locate install.sh in the repository, and inspect the sudo invocation that fails when sudo is unavailable. Reproduce the installation in a minimal Docker container running as root. Done means the certificate installation completes for a root-only environment without requiring sudo.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- shell
- Domain
- devops
- Issue type
- Bug
- Difficulty
- 2/5
- Estimated time
- 1-3 hours
- Activity status
- Stale
- Clarity
- Clearly specified
- Newbie friendliness
- 50/100