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

cannot unmarshal servicePort from variable #42

Open
kamsz opened this issue Feb 27, 2017 · 3 comments
Open

cannot unmarshal servicePort from variable #42

kamsz opened this issue Feb 27, 2017 · 3 comments
Assignees

Comments

@kamsz
Copy link

kamsz commented Feb 27, 2017

Hi,

I've set my portMappings as below:

          portMappings:
            - containerPort: 80
              servicePort: ${SERVICE_PORT}
              protocol: tcp

But I'm unable to create an application with servicePort as a variable due to:

2017-02-27 08:43:01 ERROR [depcon]: error unmarshaling JSON: json: cannot unmarshal string into Go value of type int

Is there any way to convert this value to an integer?

@gondor gondor self-assigned this Mar 18, 2017
@gondor
Copy link
Member

gondor commented Mar 27, 2017

Can you provide the exact command you're using? I just test this using the latest 0.9.4 release and it worked/parsed just fine. Note: My variable name was ${SP} and ran it using a -p SP=4444 and it worked fine.

@kamsz
Copy link
Author

kamsz commented Mar 27, 2017

@gondor Hi. I'm using vars file to supply variables for substitution.

@kamsz
Copy link
Author

kamsz commented Mar 27, 2017

@gondor Tested with 0.9.4:

              servicePort: ${SERVICE_PORT}

vars file:

SERVICE_PORT=10201

results in:

2017-03-27 10:19:14 ERROR [depcon]: error unmarshaling JSON: json: cannot unmarshal string into Go value of type int

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

2 participants