diff --git a/frontend/src/components/Dashboard/QuickStartWizard.tsx b/frontend/src/components/Dashboard/QuickStartWizard.tsx index 23dca52..c42553d 100644 --- a/frontend/src/components/Dashboard/QuickStartWizard.tsx +++ b/frontend/src/components/Dashboard/QuickStartWizard.tsx @@ -135,8 +135,16 @@ const QuickStartWizard: React.FC = ({ // Step 3: Create policy const policyName = `${setupData.bucketName}-${setupData.policyType}-policy`; + + // Map policy types to template keys + const templateKey = setupData.policyType === 'readwrite' + ? 'bucketFullAccess' + : setupData.policyType === 'readonly' + ? 'bucketReadOnly' + : 'bucketWriteOnly'; + const policyJson = policyService.generatePolicyFromTemplate( - `bucket${setupData.policyType.charAt(0).toUpperCase() + setupData.policyType.slice(1).replace('only', 'Only')}`, + templateKey, setupData.bucketName ); @@ -220,21 +228,22 @@ const QuickStartWizard: React.FC = ({ setSetupData({ ...setupData, userName: e.target.value })} error={!!error && activeStep === 1} + helperText="This will be the user's Access Key for MinIO" /> setSetupData({ ...setupData, userPassword: e.target.value })} error={!!error && activeStep === 1} - helperText={error || "Min 8 chars, uppercase, lowercase, and number required"} + helperText={error || "This will be the user's Secret Key - Min 8 chars, uppercase, lowercase, and number"} InputProps={{ endAdornment: ( @@ -317,7 +326,7 @@ const QuickStartWizard: React.FC = ({ @@ -326,7 +335,7 @@ const QuickStartWizard: React.FC = ({