这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@Theosakamg
Copy link
Collaborator

No description provided.

@pjcdawkins pjcdawkins requested a review from Copilot October 23, 2025 12:01
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR enhances environment variable handling and configuration management by introducing environment-specific .env files and adding support for configurable API and OAuth URLs. The changes enable dynamic configuration based on the deployment environment (development vs. production) while maintaining backward compatibility.

  • Adds environment-specific configuration loading with variable expansion support
  • Introduces configurable API and OAuth URLs via environment variables
  • Creates separate environment files for development and default configurations

Reviewed Changes

Copilot reviewed 5 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
upsun-mcp/src/mcpUpsun.ts Adds createConfig() method to inject environment-based API/OAuth URLs into UpsunClient configuration
upsun-mcp/src/index.ts Updates dotenv loading to support environment-specific files and variable expansion
upsun-mcp/package.json Adds dotenv-expand dependency for environment variable interpolation
.env.development Introduces development-specific environment configuration with test/staging URLs
.env Adds default environment configuration with production URLs
Files not reviewed (1)
  • upsun-mcp/package-lock.json: Language not supported

Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.

@Theosakamg Theosakamg added this to the v0.2.0 milestone Oct 23, 2025
@Theosakamg Theosakamg self-assigned this Oct 23, 2025
@Theosakamg Theosakamg added the enhancement New feature or request label Oct 23, 2025
@github-actions
Copy link

Coverage after merging dyn_oauth2 into main will be

94.61%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   mcpUpsun.ts96.43%87.50%100%97.50%191–192
src/command
   activity.ts100%100%100%100%
   backup.ts100%100%100%100%
   certificate.ts100%100%100%100%
   domain.ts100%100%100%100%
   environment.ts100%100%100%100%
   organization.ts100%100%100%100%
   project.ts95.35%75%100%100%70, 77
   route.ts100%100%100%100%
   ssh.ts100%100%100%100%
src/core
   authentication.ts87.32%84.38%84.62%90.77%107–108, 125, 143, 148, 155–156, 248–249, 299–300, 300, 300, 300, 300–301
   config.ts98.65%97.92%100%100%85
   gateway.ts80.26%100%66.67%80.70%227–230, 254, 257–258, 260–261, 265, 269
   helper.ts93.55%80%100%96.15%243–245, 329–330, 334
   logger.ts96.77%91.43%100%100%24, 74, 97
   telemetry.ts90.98%88.24%100%91.01%149–150, 183–184, 233–234, 282–283, 333–334, 355–356
src/core/transport
   http.ts88.42%87.10%62.50%92.86%100, 58, 82, 85, 91, 91, 91–92
   sse.ts82.52%64.29%85.71%89.71%100, 112, 120, 123, 123, 123–125, 136, 56, 95, 95, 95, 95, 95–96, 99
src/task
   config.ts100%100%100%100%

@github-actions
Copy link

Coverage after merging dyn_oauth2 into main will be

94.61%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   mcpUpsun.ts96.43%87.50%100%97.50%191–192
src/command
   activity.ts100%100%100%100%
   backup.ts100%100%100%100%
   certificate.ts100%100%100%100%
   domain.ts100%100%100%100%
   environment.ts100%100%100%100%
   organization.ts100%100%100%100%
   project.ts95.35%75%100%100%70, 77
   route.ts100%100%100%100%
   ssh.ts100%100%100%100%
src/core
   authentication.ts87.32%84.38%84.62%90.77%107–108, 125, 143, 148, 155–156, 248–249, 299–300, 300, 300, 300, 300–301
   config.ts98.65%97.92%100%100%85
   gateway.ts80.26%100%66.67%80.70%227–230, 254, 257–258, 260–261, 265, 269
   helper.ts93.55%80%100%96.15%243–245, 329–330, 334
   logger.ts96.77%91.43%100%100%24, 74, 97
   telemetry.ts90.98%88.24%100%91.01%149–150, 183–184, 233–234, 282–283, 333–334, 355–356
src/core/transport
   http.ts88.42%87.10%62.50%92.86%100, 58, 82, 85, 91, 91, 91–92
   sse.ts82.52%64.29%85.71%89.71%100, 112, 120, 123, 123, 123–125, 136, 56, 95, 95, 95, 95, 95–96, 99
src/task
   config.ts100%100%100%100%

@github-actions
Copy link

Coverage after merging dyn_oauth2 into main will be

94.64%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   mcpUpsun.ts96.15%75%100%97.50%192–193
src/command
   activity.ts100%100%100%100%
   backup.ts100%100%100%100%
   certificate.ts100%100%100%100%
   domain.ts100%100%100%100%
   environment.ts100%100%100%100%
   organization.ts100%100%100%100%
   project.ts95.35%75%100%100%70, 77
   route.ts100%100%100%100%
   ssh.ts100%100%100%100%
src/core
   authentication.ts85.94%80%84.62%90.77%108–109, 126, 144, 149, 156–157, 249–250, 300–301, 301, 301, 301, 301–302
   config.ts97.74%97.06%100%100%173, 208, 244
   gateway.ts79.73%100%66.67%80.70%228–231, 255, 258–259, 261–262, 266, 270
   helper.ts93.55%80%100%96.15%243–245, 329–330, 334
   logger.ts98.90%96.97%100%100%98
   telemetry.ts90.98%88.24%100%91.01%149–150, 183–184, 233–234, 282–283, 333–334, 355–356
src/core/transport
   http.ts88.42%87.10%62.50%92.86%100, 58, 82, 85, 91, 91, 91–92
   sse.ts82.52%64.29%85.71%89.71%100, 112, 120, 123, 123, 123–125, 136, 56, 95, 95, 95, 95, 95–96, 99
src/task
   config.ts100%100%100%100%

@github-actions
Copy link

Coverage after merging dyn_oauth2 into main will be

93.95%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   mcpUpsun.ts96.15%75%100%97.50%192–193
src/command
   activity.ts100%100%100%100%
   backup.ts100%100%100%100%
   certificate.ts100%100%100%100%
   domain.ts100%100%100%100%
   environment.ts100%100%100%100%
   organization.ts100%100%100%100%
   project.ts95.35%75%100%100%70, 77
   route.ts100%100%100%100%
   ssh.ts100%100%100%100%
src/core
   authentication.ts83.19%77.08%81.82%88.33%116, 128–130, 142, 147, 154, 157, 247–248, 298–299, 299, 299, 299, 299–300, 98
   config.ts92.06%92.62%100%89.47%107, 114, 114, 114, 119, 123, 130, 136, 290, 327, 36, 38–40, 95
   gateway.ts79.73%100%66.67%80.70%228–231, 255, 258–259, 261–262, 266, 270
   helper.ts93.55%80%100%96.15%243–245, 329–330, 334
   logger.ts98.61%96.15%100%100%83
   telemetry.ts90.23%85.29%100%91.01%108, 149–150, 183–184, 233–234, 282–283, 333–334, 355–356
   types.ts100%100%100%100%
src/core/transport
   http.ts88.42%87.10%62.50%92.86%100, 58, 82, 85, 91, 91, 91–92
   sse.ts82.52%64.29%85.71%89.71%100, 112, 120, 123, 123, 123–125, 136, 56, 95, 95, 95, 95, 95–96, 99
src/task
   config.ts100%100%100%100%

@Theosakamg Theosakamg requested a review from Copilot October 28, 2025 09:50
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Copilot reviewed 29 out of 30 changed files in this pull request and generated 2 comments.

Files not reviewed (1)
  • upsun-mcp/package-lock.json: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link

Coverage after merging dyn_oauth2 into main will be

93.95%

Coverage Report
FileStmtsBranchesFuncsLinesUncovered Lines
src
   mcpUpsun.ts96.15%75%100%97.50%192–193
src/command
   activity.ts100%100%100%100%
   backup.ts100%100%100%100%
   certificate.ts100%100%100%100%
   domain.ts100%100%100%100%
   environment.ts100%100%100%100%
   organization.ts100%100%100%100%
   project.ts95.35%75%100%100%70, 77
   route.ts100%100%100%100%
   ssh.ts100%100%100%100%
src/core
   authentication.ts83.19%77.08%81.82%88.33%116, 128–130, 142, 147, 154, 157, 247–248, 298–299, 299, 299, 299, 299–300, 98
   config.ts92.06%92.62%100%89.47%107, 114, 114, 114, 119, 123, 130, 136, 290, 327, 36, 38–40, 95
   gateway.ts79.73%100%66.67%80.70%228–231, 255, 258–259, 261–262, 266, 270
   helper.ts93.55%80%100%96.15%243–245, 329–330, 334
   logger.ts98.61%96.15%100%100%83
   telemetry.ts90.23%85.29%100%91.01%108, 149–150, 183–184, 233–234, 282–283, 333–334, 355–356
   types.ts100%100%100%100%
src/core/transport
   http.ts88.42%87.10%62.50%92.86%100, 58, 82, 85, 91, 91, 91–92
   sse.ts82.52%64.29%85.71%89.71%100, 112, 120, 123, 123, 123–125, 136, 56, 95, 95, 95, 95, 95–96, 99
src/task
   config.ts100%100%100%100%

@Theosakamg Theosakamg requested a review from Copilot October 28, 2025 10:07
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

Copilot reviewed 29 out of 30 changed files in this pull request and generated 2 comments.

Files not reviewed (1)
  • upsun-mcp/package-lock.json: Language not supported

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@Theosakamg Theosakamg merged commit 6468c42 into main Oct 28, 2025
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants