Skip to content

Model and DB changes for Status Page Settings

Sean Arnold requested to merge 207181-status-page-settings-backend into master

What does this MR do?

This is the backend part of #207181 (closed) and sets up the Rails model, DB table and helpers. This is needed so that the frontend UI can be implemented. Frontend MR is here: !25820 (merged). This is an EE feature.

This is part of the Status Page MVC.

Implementation

The implementation of this is very similar to how we implemented the Grafana integration settings (!17234 (merged)).

We save the following fields in the database:

  • aws_s3_bucket_name (Limited to 63 chars, as per Amazon S3 Bucket Naming Requirements
  • aws_region
  • aws_access_key
  • aws_secret_key (Encrypted, and stored as fields encrypted_aws_secret_key and encrypted_aws_secret_key_iv, using attr_encrypted Gem)
  • enabled (indexed, where enabled is true)
  • project_id (indexed)

This model can be created through the Project's nested_attriubutes. It can also be destroyed. We do this when we receive a PATCH without both the aws_secret_key and aws_access_key fields.

Does this MR meet the acceptance criteria?

Conformity

Related to #207181 (closed)

Edited by Heinrich Lee Yu

Merge request reports