Skip to content

feat: surface remote_owner in component list + warn on WordPress deploy#936

Merged
chubes4 merged 1 commit intomainfrom
feat/component-list-remote-owner
Mar 23, 2026
Merged

feat: surface remote_owner in component list + warn on WordPress deploy#936
chubes4 merged 1 commit intomainfrom
feat/component-list-remote-owner

Conversation

@chubes4
Copy link
Member

@chubes4 chubes4 commented Mar 23, 2026

Summary

Fixes #602 — makes remote_owner visible so missing config doesn't silently break WordPress deployments.

Changes

1. component list always shows remote_owner

Before: remote_owner was omitted from JSON when None (serde skip_serializing_if).
After: explicitly null in list output, making it easy to spot missing config:

{
  "id": "data-machine",
  "remote_owner": null,          // ← now visible
  "remote_path": "wp-content/plugins/data-machine"
}

The skip_serializing_if on RawComponent is unchanged — homeboy.json files won't get polluted with "remote_owner": null.

2. Deploy warning for WordPress paths

When deploying to a wp-content/ path without remote_owner, a warning is logged with the exact fix command:

⚠ Component 'data-machine' deploys to a WordPress path but has no remote_owner set.
  Files may deploy as root:root.
  Fix: homeboy component set data-machine --json '{"remote_owner":"www-data:www-data"}'

Context

Root cause of the original issue: fix_deployed_ownership() auto-detects ownership from existing files, but on first deploy the directory doesn't exist yet — files end up as root:root, breaking WordPress.

…oy (#602)

Two changes to prevent the 'files deployed as root:root' footgun:

1. component list: always include remote_owner in JSON output (explicit
   null when unset) so missing config is visible at a glance.

2. deploy: warn when deploying to a wp-content/ path without
   remote_owner configured, with the exact fix command in the message.
@chubes4 chubes4 merged commit 9e3d4c6 into main Mar 23, 2026
@chubes4 chubes4 deleted the feat/component-list-remote-owner branch March 23, 2026 01:16
@homeboy-ci
Copy link
Contributor

homeboy-ci bot commented Mar 23, 2026

Homeboy Results — homeboy

Audit

Failure Digest

Audit Failure Digest

  • Alignment score: 0.921
  • Severity counts: info: 1, unknown: 3, warning: 7
  • Outliers in current run: 3
  • Parsed outlier entries: 3
  • Drift increased: yes
  • New findings since baseline: 3
    1. structural — File has 16 top-level items (threshold: 15) (structural::src/commands/component.rs::HighItemCount)
    2. intra-method-duplication — Duplicated block in execute_artifact_deploy — 5 identical lines at line 239 and line 261 (intra-method-duplication::src/core/deploy/execution.rs::IntraMethodDuplicate)
    3. intra-method-duplication — Duplicated block in execute_component_deploy — 5 identical lines at line 59 and line 101 (intra-method-duplication::src/core/deploy/execution.rs::IntraMethodDuplicate)
  • Top actionable findings:
    1. src/commands/component.rs — high_item_count — File has 16 top-level items (threshold: 15)
    2. src/commands/component.rs — intra_method_duplicate — Duplicated block in run — 5 identical lines at line 284 and line 294
    3. src/commands/component.rs — intra_method_duplicate — Duplicated block in shared — 6 identical lines at line 666 and line 681
    4. src/core/deploy/execution.rs — intra_method_duplicate — Duplicated block in execute_artifact_deploy — 5 identical lines at line 239 and line 261
    5. src/core/deploy/execution.rs — intra_method_duplicate — Duplicated block in execute_component_deploy — 5 identical lines at line 59 and line 101
All parsed audit findings (11)
1. **src/commands/component.rs** — high_item_count — File has 16 top-level items (threshold: 15)
2. **src/commands/component.rs** — intra_method_duplicate — Duplicated block in `run` — 5 identical lines at line 284 and line 294
3. **src/commands/component.rs** — intra_method_duplicate — Duplicated block in `shared` — 6 identical lines at line 666 and line 681
4. **src/core/deploy/execution.rs** — intra_method_duplicate — Duplicated block in `execute_artifact_deploy` — 5 identical lines at line 239 and line 261
5. **src/core/deploy/execution.rs** — intra_method_duplicate — Duplicated block in `execute_component_deploy` — 5 identical lines at line 59 and line 101
6. **src/core/deploy/orchestration.rs** — intra_method_duplicate — Duplicated block in `checkout_latest_tags` — 6 identical lines at line 389 and line 407
7. **src/core/deploy/execution.rs** — missing_test_file — No test file found (expected 'tests/core/deploy/execution_test.rs') and no inline tests
8. **src/core/deploy/orchestration.rs** — missing_test_file — No test file found (expected 'tests/core/deploy/orchestration_test.rs') and no inline tests
9. **src/commands/docs.rs** — outlier — (outlier)
10. **tests/commands/deploy_test.rs** — outlier — (outlier)
11. **src/core/engine/undo/snapshot.rs** — outlier — (outlier)
- Full audit log: https://github.com/Extra-Chill/homeboy/actions/runs/23417296446

Autofixability classification

  • Overall: auto_fixable
  • Autofix enabled: yes
  • Autofix attempted this run: no
  • Auto-fixable failed commands:
    • audit
  • Failed commands with available automated fixes:
    • audit

Machine-readable artifacts

  • homeboy-lint-summary.json
  • homeboy-test-failures.json
  • homeboy-audit-summary.json
  • homeboy-autofixability.json

⚡ Scope: changed files only

audit (changed files only)

Auto-refactor

ℹ️ Autofix enabled, but no fixable file changes were produced

Failure Digest

Autofixability classification

  • Overall: human_needed
  • Autofix enabled: yes
  • Autofix attempted this run: no
  • Human-needed failed commands:
    • refactor --from all

Machine-readable artifacts

  • homeboy-lint-summary.json
  • homeboy-test-failures.json
  • homeboy-audit-summary.json
  • homeboy-autofixability.json

⚡ Scope: changed files only

refactor --from all

Tooling versions
  • Homeboy CLI: homeboy 0.85.3+2690f37
  • Extension: rust from https://github.com/Extra-Chill/homeboy-extensions
  • Extension revision: unknown
  • Action: Extra-Chill/homeboy-action@v2

Homeboy Action v1

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

component list should show remote_owner field

1 participant