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

Backslash in env causes pipeline upload to freeze #585

Closed
toolmantim opened this issue Nov 13, 2017 · 0 comments
Closed

Backslash in env causes pipeline upload to freeze #585

toolmantim opened this issue Nov 13, 2017 · 0 comments

Comments

@toolmantim
Copy link
Contributor

toolmantim commented Nov 13, 2017

The following YML seems to cause 3.0 beta 34+ agents to enter an infinite loop during pipeline upload (with high CPU and unbounded memory growth):

steps:
- env:
    BOOM: \ 

To test, save the above to /tmp/pipeline.yml and run the below command (job and agent token don't need to be valid):

$ docker run -it --rm -e BUILDKITE_AGENT_DEBUG=true -e BUILDKITE_AGENT_DEBUG_HTTP=true -v /tmp/pipeline.yml:/tmp/pipeline.yml buildkite/agent:3.0-beta.34 pipeline upload --job 111 --agent-access-token 111 /tmp/pipeline.yml
2017-11-13 12:04:04 DEBUG  Debug mode enabled
2017-11-13 12:04:04 INFO   Reading pipeline config from "/tmp/pipeline.yml"
2017-11-13 12:04:04 DEBUG  Parsing pipeline configuration as YAML

Beta 33 doesn't show this behaviour:

$ docker run -it --rm -e BUILDKITE_AGENT_DEBUG=true -e BUILDKITE_AGENT_DEBUG_HTTP=true -v /tmp/pipeline.yml:/tmp/pipeline.yml buildkite/agent:3.0-beta.33 pipeline upload --job 111 --agent-access-token 111 /tmp/pipeline.yml
2017-11-13 12:04:15 DEBUG  Debug mode enabled
2017-11-13 12:04:15 INFO   Reading pipeline config from "/tmp/pipeline.yml"
2017-11-13 12:04:15 DEBUG  Parsing pipeline configuration as YAML
2017-11-13 12:04:15 DEBUG  ERR: %!s(<nil>)
POST /v3/jobs/abc123/pipelines HTTP/1.1
Host: agent.buildkite.com
User-Agent: buildkite-agent/3.0-beta.33.1802 (linux; amd64)
Content-Length: 93
Content-Type: application/json
Accept-Encoding: gzip
@lox lox closed this as completed in 3f09c9b Nov 14, 2017
lox added a commit that referenced this issue Nov 14, 2017
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

No branches or pull requests

1 participant