Skip to content

feat: auto-show deployment logs on failure#75

Open
JoshSalway wants to merge 1 commit intolaravel:mainfrom
JoshSalway:fix/show-logs-on-deploy-failure
Open

feat: auto-show deployment logs on failure#75
JoshSalway wants to merge 1 commit intolaravel:mainfrom
JoshSalway:fix/show-logs-on-deploy-failure

Conversation

@JoshSalway
Copy link

Summary

  • Automatically fetches and displays deployment logs when cloud deploy or cloud ship fails
  • Shows which phase failed (Build vs Deploy) with the actual error output
  • Adds GetDeploymentLogsRequest for GET /deployments/{id}/logs and a logs() method on DeploymentsResource
  • Gracefully handles cases where the logs endpoint is unavailable or returns empty

Closes #73

Example output

✗ Deployment failed: Build failed

  Build output:
  | Installing composer dependencies...
  | npm ci --audit false
  | npm ERR! Could not resolve dependency: @inertiajs/vue3@^2.0
  | npm ERR! peer dep missing: vue@^3.0

  Do you want to edit the build and deploy commands and try again?

Test plan

  • Added test: displays build logs when deployment fails with build error
  • Added test: displays deploy logs when deployment fails with deploy error
  • Added test: handles failed deployment when logs endpoint returns empty
  • All existing tests pass
  • PHPStan passes with no errors

🤖 Generated with Claude Code

When a deployment fails, automatically fetch and display the build/deploy
logs so users can immediately see what went wrong without needing to visit
the dashboard. Shows which phase failed (Build vs Deploy) and the actual
error output.

Closes laravel#73

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
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.

Bug: cloud ship has 8 issues affecting reliability in both interactive and non-interactive modes

1 participant