Frontend: Create and update rotation for secrets
Why are we doing this work
The Secrets manager form already has a rotation field in its UI, but we currently do not save this data yet. Once #499945 (closed) and #555420 (closed) are complete, we can update the frontend to save and render the rotation data for secrets.
Implementation plan
- Remove cron syntax UI and allow users to add custom numbers for
rotationIntervalDays - Add rotation field in the create and update mutation (
ee/app/assets/javascripts/ci/secrets/graphql/mutations) - Save rotation field through the UI (the rotation field is already available in the UI, so we just need to include the data to GraphQL)
- Render the rotation data on the secret detail page and the secrets table (update fetch query to include the data)
Implementation Table
Verification steps
Setup
- Make sure your gdk is on an Ultimate license.
- Set up openbao on your gdk.
- Enable the Secrets Manager on gdk.
Verification
- Visit
/path/to/project/-/secrets(or go to your project and from the sidebar visit Secure > Secrets) - From the secrets table, you can create a new secret by clicking the Add secret button on the top right. You can also edit an existing secret through the actions column.
- Successfully creating and updating a secret will automatically redirect you to the secret details page. Verify that the rotation data is displayed on this page, as well as in the corresponding secrets row on the secrets table.
Edited by 🤖 GitLab Bot 🤖