Skip to content

feat: add app logs command for streaming application logs#24

Open
megamattron wants to merge 3 commits intoDokploy:mainfrom
megamattron:feat/app-logs
Open

feat: add app logs command for streaming application logs#24
megamattron wants to merge 3 commits intoDokploy:mainfrom
megamattron:feat/app-logs

Conversation

@megamattron
Copy link

Summary

  • Adds dokploy app logs command for viewing application logs from the terminal
  • Supports live streaming (--follow), tail count, time-based filtering (--since), and keyword search (--search)
  • Uses the existing /docker-container-logs WebSocket endpoint, tries Swarm mode first then falls back to native containers
  • Falls back to SSH-based docker service logs for Dokploy Cloud instances where WebSocket is unavailable
  • Also includes a small fix for missing environmentId destructuring in the redis create command

Closes #23

The environmentId variable was referenced but never destructured from
flags, causing a build error.
Adds `dokploy app logs` to view application logs via WebSocket,
with automatic swarm/native detection and SSH fallback for
Dokploy Cloud. Includes interactive project/environment/app
selection and --follow, --tail, --since, and --search flags.

Also adds getApplication(), getServer() helpers and Server type
to shared utils, and adds ws dependency.
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.

Add app logs command for viewing application logs

1 participant