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

Use AgentServiceCheck.Args when registering Consul script/container checks #627

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

scottatron
Copy link

Consul recently replaced the Script field from AgentServiceCheck with an Args string slice.

This updates the creation of these checks to use the Args field.

…hecks

Consul [recently replaced][1] the Script field from AgentServiceCheck with an
Args string slice.

This updates the creation of these checks to use the Args field.

[1]: hashicorp/consul@b73323a#diff-4f360b6361d9900f98e2f244a3411bc4
@scottatron
Copy link
Author

I have tested this against Consul v.1.0.7 and v.1.1.0

@scottatron
Copy link
Author

I've looked at this a little more closely, and it seems as though AgentServiceCheck.Args was only added in v1.0.1, and AgentServiceCheck.Script was deprecated. AgentServiceCheck.Script was then removed in v1.1.0

Seems like a pretty quick deprecation/removal, and I wouldn't have expected a breaking change like that in a point release.

In order to all versions of Consul, this change will need to be updated to support both the Args and Script fields based on the version of Consul.

@jhsolor
Copy link

jhsolor commented Oct 8, 2018

Hi @scottatron, looks like we both stumbled on the same issue and the same fix. I have an updated PR that also pins the Gopkg.toml so that dep ensure works with this change. #643

@pmundt
Copy link
Contributor

pmundt commented Sep 22, 2019

Issue is still outstanding, and I've also introduced a similar PR in #669 before finding these. Let's hope there is some action on this soon.

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.

3 participants