Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

App logs with follow option does not work after upgrade to 1.5 #777

Closed
morgoth opened this issue Apr 26, 2024 · 3 comments · Fixed by #779
Closed

App logs with follow option does not work after upgrade to 1.5 #777

morgoth opened this issue Apr 26, 2024 · 3 comments · Fixed by #779

Comments

@morgoth
Copy link
Contributor

morgoth commented Apr 26, 2024

Having the command:
bin/kamal app logs -r web -f
It worked fine on kamal 1.4.0, thus giving output:

  INFO Following logs on i-0d1a6eb781c5d3ad2...
  INFO ssh -o ProxyCommand='aws ssm start-session --target %h --document-name AWS-StartSSHSession --parameters 'portNumber=%p'' -t ubuntu@<ip> -p 22 'docker ps --quiet --filter label=service=replenisher --filter label=role=web --filter status=running --filter status=restarting --latest | xargs docker logs --timestamps --tail 10 --follow 2>&1'

while on 1.5.0, it throws:

  INFO Following logs on i-0d1a6eb781c5d3ad2...
  INFO ssh -o ProxyCommand='aws ssm start-session --target %h --document-name AWS-StartSSHSession --parameters 'portNumber=%p'' -t ubuntu@<ip> -p 22 'sh -c 'docker ps --latest --quiet --filter label=service=replenisher --filter label=role=web --filter status=running --filter status=restarting --filter ancestor=$(docker image ls --filter reference=ecr-repo-address/image-name:latest --format '\''{{.ID}}'\'') ; docker ps --latest --quiet --filter label=service=replenisher --filter label=role=web --filter status=running --filter status=restarting' | head -1 | xargs docker logs --timestamps --tail 10 --follow 2>&1'
sh: 1: Syntax error: Unterminated quoted string

Running ``bin/kamal app logs -r web` (without follow option) works fine

My nonstandard SSH config:

ssh:
  user: ubuntu
  proxy_command: <%= %q(aws ssm start-session --target %h --document-name AWS-StartSSHSession --parameters 'portNumber=%p') %>
@djmb
Copy link
Collaborator

djmb commented Apr 26, 2024

Thanks @morgoth - looks like it was generally broken and nothing to do with your specific config. Fixed in #779

@djmb djmb closed this as completed in #779 Apr 26, 2024
@djmb
Copy link
Collaborator

djmb commented Apr 26, 2024

I've released v1.5.1, could you confirm that it's fixed for you now @morgoth?

@morgoth
Copy link
Contributor Author

morgoth commented Apr 26, 2024

It works. Thank you

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 a pull request may close this issue.

2 participants