Implement Doppler as a centralized configuration provider - #39
Merged
Conversation
…tings integration
…figuration strategy
…ntralize Devops/ops002 doppler config centralize
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing touches🧪 Generate unit tests (beta)
Comment |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This pull request introduces several improvements and new features across the build pipeline, configuration management, and development tooling. The most significant change is the integration of Doppler as a cloud-based configuration provider, which streamlines secret and configuration management. The Jenkins pipeline is refactored for better maintainability and more robust Docker image labeling and cleanup. Additionally, development environment settings are improved for better usability, and a new custom exception is added for configuration errors.
Configuration Management and Cloud Integration:
Added Doppler as a configuration provider by introducing
Doppler.Extensions.Configurationto the project dependencies and implementingAddConfigurationFromDopplerCloudinDependencyInjection.cs, allowing the app to load secrets from Doppler if a token is present. This includes propagating user-level environment variables and logging the configuration source. (SnakeAid.Api/DI/DependencyInjection.cs[1] [2];SnakeAid.Api/Program.cs[3] [4];SnakeAid.Api/SnakeAid.Api.csproj[5];Directory.Packages.props[6]Introduced a new
ConfigurationExceptionclass to standardize error handling for configuration-related failures. (SnakeAid.Core/Exceptions/ApiException.csSnakeAid.Core/Exceptions/ApiException.csR115-R122)CI/CD Pipeline Improvements:
Refactored the Jenkins pipeline by extracting Docker build and push logic into reusable functions (
withDockerImage,dockerBuildOnly,dockerBuildAndPush), enhancing maintainability and ensuring images are cleaned up after builds. Also, added more OCI-compliant Docker labels for traceability and context, and improved environment detection logic. (Jenkinsfile[1] [2] [3] [4] [5] [6]Removed the obsolete GitHub Actions workflow for deploying Docsify documentation, likely in favor of another documentation deployment strategy. (
.github/workflows/deploy-docsify.yml.github/workflows/deploy-docsify.ymlL1-L44)Development Environment and Tooling:
Added a
.vscode/settings.jsonto define default solution, file search, and watcher exclusions, improving the developer experience in VS Code. (.vscode/settings.json.vscode/settings.jsonR1-R41)Updated launch configurations in
.vscode/launch.jsonto improve the accuracy of server URL detection regex patterns for debugging. (.vscode/launch.json[1] [2] [3] [4]Modified
launchSettings.jsonto clear the default browser launch URLs, preventing automatic navigation to Swagger and giving developers more control. (SnakeAid.Api/Properties/launchSettings.json[1] [2]Other Minor Changes:
SnakeAid.Core/Settings/AppSettings.csSnakeAid.Core/Settings/AppSettings.csR47)These changes collectively improve the project's configuration security, CI/CD robustness, and developer productivity.