Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chores (phpmyadmin): Add insufficient-permission message #1694

Merged
merged 1 commit into from
Feb 14, 2024

Conversation

aswasif007
Copy link
Contributor

@aswasif007 aswasif007 commented Feb 14, 2024

Description

We are adding insufficient permission message so that user's without permission can know why they cannot access the feature.

$ node ./dist/bin/vip db phpmyadmin @5910.develop
Note: PHPMyAdmin sessions are read-only. If you run a query that writes to DB, it will fail.
✕ Enabling PHPMyAdmin for this environment
○ Generating access link
Error:  You do not have sufficient permission to access phpMyAdmin for this environment.
Debug:  VIP-CLI v2.38.1-dev.0, Node v20.11.0, darwin 23.3.0 arm64

Pull request checklist

New release checklist

Steps to Test

Outline the steps to test and verify the PR here.

Example:

  1. Check out PR.
  2. Run npm run build
  3. Run the command in the description, but with a user that do not have admin role to the organization.
  4. Verify the error message.

Copy link

Quality Gate Passed Quality Gate passed

Issues
0 New issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

Copy link
Contributor

@saroshaga saroshaga left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can we add any other info on the message?

@aswasif007
Copy link
Contributor Author

aswasif007 commented Feb 14, 2024

Can we add any other info on the message?

If this is information regarding what permission the user needs, I'd say we shouldn't.
Instead maybe we can add something like "contact your site admin or org admin" but with better wordings. What do you think?

@saroshaga
Copy link
Contributor

Instead maybe we can add something like "contact your site admin or org admin" but with better wordings. What do you think?

Umm I think it is good as is then

@aswasif007 aswasif007 merged commit 112ac7a into trunk Feb 14, 2024
16 checks passed
@aswasif007 aswasif007 deleted the add/permission-msg branch February 14, 2024 09:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants