Skip to content

Remove realhostip references from the code#12856

Draft
vishesh92 wants to merge 1 commit intoapache:mainfrom
shapeblue:remove-realhostip-references
Draft

Remove realhostip references from the code#12856
vishesh92 wants to merge 1 commit intoapache:mainfrom
shapeblue:remove-realhostip-references

Conversation

@vishesh92
Copy link
Member

Description

This PR removes references for realhostip.

Types of changes

  • Breaking change (fix or feature that would cause existing functionality to change)
  • New feature (non-breaking change which adds functionality)
  • Bug fix (non-breaking change which fixes an issue)
  • Enhancement (improves an existing feature and functionality)
  • Cleanup (Code refactoring and cleanup, that may add test cases)
  • Build/CI
  • Test (unit or integration test code)

Feature/Enhancement Scale or Bug Severity

Feature/Enhancement Scale

  • Major
  • Minor

Bug Severity

  • BLOCKER
  • Critical
  • Major
  • Minor
  • Trivial

Screenshots (if appropriate):

How Has This Been Tested?

How did you try to break this feature and the system with this change?

@codecov
Copy link

codecov bot commented Mar 18, 2026

Codecov Report

❌ Patch coverage is 0% with 4 lines in your changes missing coverage. Please review.
✅ Project coverage is 18.02%. Comparing base (93239e0) to head (545ddbb).
⚠️ Report is 2 commits behind head on main.

Files with missing lines Patch % Lines
...java/com/cloud/server/ConfigurationServerImpl.java 0.00% 2 Missing ⚠️
...va/com/cloud/storage/upload/UploadMonitorImpl.java 0.00% 2 Missing ⚠️
Additional details and impacted files
@@             Coverage Diff              @@
##               main   #12856      +/-   ##
============================================
+ Coverage     17.95%   18.02%   +0.07%     
- Complexity    16259    16451     +192     
============================================
  Files          5954     5968      +14     
  Lines        534838   537081    +2243     
  Branches      65423    65959     +536     
============================================
+ Hits          96010    96818     +808     
- Misses       428053   429342    +1289     
- Partials      10775    10921     +146     
Flag Coverage Δ
uitests 3.53% <ø> (-0.12%) ⬇️
unittests 19.19% <0.00%> (+0.12%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Contributor

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 aims to remove legacy realhostip domain references across CloudStack (tests, SystemVM packaging/scripts, and management-server logic), and to clear stale configuration values during upgrade.

Changes:

  • Replace *.realhostip.com/realhostip.com references in tests and comments with *.example.com/example.com.
  • Rename/update SystemVM truststore/cert/key filenames from realhostip.* to systemvm.* and update related scripts/poms to reference the new names.
  • Remove legacy “only realhostip supported” warnings and add an upgrade SQL to null out stale realhostip configuration values.

Reviewed changes

Copilot reviewed 13 out of 18 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
utils/src/test/java/org/apache/cloudstack/utils/imagestore/ImageStoreUtilTest.java Updates test domain strings away from realhostip.
systemvm/pom.xml Updates quickcloud trustStore filename to systemvm.keystore.
systemvm/patch-sysvms.sh Updates keystore path used when importing JVM cacerts.
systemvm/debian/opt/cloud/bin/setup/bootstrap.sh Updates keystore path used during systemvm bootstrap.
systemvm/agent/scripts/config_ssl.sh Renames default cert/key/keystore filenames used for SSL setup.
systemvm/agent/scripts/_run.sh Updates agent JVM trustStore filename to systemvm.keystore.
systemvm/agent/certs/systemvm.keystore Adds/renames keystore artifact used by SystemVM components.
systemvm/agent/certs/systemvm.key Adds/renames private key artifact used by SystemVM SSL setup.
systemvm/agent/certs/systemvm.csr Adds/renames CSR artifact.
systemvm/agent/certs/systemvm.crt Adds/renames certificate artifact.
services/secondary-storage/server/pom.xml Updates trustStore filename to systemvm.keystore.
services/console-proxy/server/pom.xml Updates excluded CSR filename to systemvm.csr.
server/src/test/java/com/cloud/keystore/KeystoreTest.java Updates hard-coded test domain strings away from realhostip.
server/src/main/java/com/cloud/storage/upload/UploadMonitorImpl.java Removes legacy realhostip fallback/logic and adjusts URL generation behavior.
server/src/main/java/com/cloud/storage/download/DownloadMonitorImpl.java Removes legacy warning tied to realhostip domain/cert expectations.
server/src/main/java/com/cloud/server/ConfigurationServerImpl.java Clears the legacy secstorage.secure.copy.cert default value.
engine/schema/src/main/resources/META-INF/db/schema-42210to42300.sql Clears stale realhostip configuration values during upgrade.
.pre-commit-config.yaml Updates pre-commit allowlist to match the renamed private key filename.

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

^services/console-proxy/rdpconsole/src/test/doc/rdp-key\.pem$|
^systemvm/agent/certs/localhost\.key$|
^systemvm/agent/certs/realhostip\.key$|
^systemvm/agent/certs/systemvm\.key$|
Comment on lines 366 to +370
hostname = hostname + "." + _ssvmUrlDomain;
} else {
hostname = hostname + ".realhostip.com";
logger.warn("SSL copy is enabled but secstorage.ssl.cert.domain is not configured; "
+ "using IP address directly. Configure a wildcard SSL certificate domain for proper HTTPS support.");
hostname = ipAddress;
Comment on lines +55 to +56
customPrivKey=$(dirname $0)/certs/systemvm.key
customPrivCert=$(dirname $0)/certs/systemvm.crt
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants