Hacktoberfest 2026: những issue maintainer đã đánh dấu cho tháng Mười, đang mở và phù hợp người mới. Xem issue Hacktoberfest

Add `--no-trunc` option to `docker stack deploy` for full error messages

Đang mở
#6,225 2 bình luận 1 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

Đánh giá

Độ khó
3/5
Thời gian dự kiến
1-2 ngày
Mức phù hợp với người mới
45/100
Loại issue
Tính năng
Độ rõ ràng
Khá rõ ràng
Mức độ hoạt động
Đình trệ
Công nghệ
docker, go
Lĩnh vực
cli

Hướng nghiên cứu

Bắt đầu từ điểm vào CLI của docker stack deploy và so sánh cách xử lý đầu ra với phần triển khai hiện có của docker service ps --no-trunc. Theo dõi trạng thái triển khai và đầu ra lỗi, sau đó xác minh rằng tùy chọn mới vẫn giữ nguyên các thông báo đầy đủ và các bài kiểm thử CLI liên quan đều đạt.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Mô tả

kind/feature status/0-triage
Description
Problem

When running docker stack deploy, deployment errors (especially scheduling constraint failures) are truncated in the CLI output. For example:

1/1: no suitable node (scheduling constraints not satisfied on 1 node; host-mod…
overall progress: 0 out of 1 tasks

This truncation makes it difficult to understand why a service could not be scheduled, as the most relevant part of the message is often cut off. This behavior appears to be hardcoded and does not respect terminal width or environment variables like COLUMNS.

Workarounds
  • Manually running docker service ps <service> --no-trunc after deployment
  • Inspecting tasks individually with docker inspect
  • Writing custom scripts to combine deployment and diagnostic commands

These add friction and delay in understanding deployment issues.

Proposal

Add a --no-trunc flag to docker stack deploy, similar to the one already available in docker service ps, which disables truncation of deployment status and error messages.

Other alternatives could include:

  • Respecting the actual terminal width or COLUMNS environment variable
  • Automatically disabling truncation when output is non-interactive (e.g. in CI pipelines)
  • Supporting full output when --verbose or --debug is enabled
Benefits
  • Immediate visibility into deployment failures without requiring follow-up commands
  • Better support for CI/CD pipelines where error visibility is critical
  • Makes docker stack deploy consistent with other CLI commands that support --no-trunc
Related
  • docker service ps already supports --no-trunc and behaves as expected
  • No current CLI flags exist to control truncation during stack deployment
Ngôn ngữ chính
Go
Star
6.1k
Fork
2.2k
Merge trung bình
1 ngày 10 giờ
Pull request đã merge (30 ngày)
47

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Issue khác của docker/cli

Tất cả issue của docker/cli

Issue tương tự

Thêm issue về Go

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.