Skip to content

Version cni plugin, ipamD, cni docker image with git tag and hash#106

Merged
mattlandis merged 1 commit intoaws:masterfrom
ewbankkit:issue-90
Jul 5, 2018
Merged

Version cni plugin, ipamD, cni docker image with git tag and hash#106
mattlandis merged 1 commit intoaws:masterfrom
ewbankkit:issue-90

Conversation

@ewbankkit
Copy link
Copy Markdown
Contributor

Issue #, if available: Fixes #90.

Description of changes:
Use the git tag and hash of the current commit as the version number for IPAMD, CNI Plugin and Docker image.
The calculated version number can be overridden via the VERSION environment variable.

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@ewbankkit
Copy link
Copy Markdown
Contributor Author

This PR replaces #103.

@ewbankkit
Copy link
Copy Markdown
Contributor Author

$ make
go build -o aws-k8s-agent -ldflags "-X main.version=v1.0.0-9-gcb6547f" main.go
go build -o aws-cni -ldflags "-X main.version=v1.0.0-9-gcb6547f" plugins/routed-eni/cni.go

2018-06-12T16:10:00Z [INFO] Starting L-IPAMD v1.0.0-9-gcb6547f  ...

2018-06-12T16:10:52Z [INFO] Starting CNI Plugin v1.0.0-9-gcb6547f  ...

$ VERSION=42 make
go build -o aws-k8s-agent -ldflags "-X main.version=42" main.go

@vsiddharth vsiddharth requested a review from mattlandis July 3, 2018 18:19
@vsiddharth
Copy link
Copy Markdown
Contributor

@ewbankkit could you please resolve the conflicts and update the pull request?

@vsiddharth
Copy link
Copy Markdown
Contributor

@mattlandis Could you please take another look at this one?

@ewbankkit
Copy link
Copy Markdown
Contributor Author

Rebased to resolve conflict.

$ make
GOOS=linux CGO_ENABLED=0 go build -o aws-k8s-agent -ldflags "-X main.version=v1.0.0-18-gcdbd144-dirty"
GOOS=linux CGO_ENABLED=0 go build -o aws-cni -ldflags "-X main.version=v1.0.0-18-gcdbd144-dirty" ./plugins/routed-eni/

2018-07-03T20:31:55Z [INFO] Starting L-IPAMD v1.0.0-18-gcdbd144-dirty  ...

$ VERSION=42 make
GOOS=linux CGO_ENABLED=0 go build -o aws-k8s-agent -ldflags "-X main.version=42"
GOOS=linux CGO_ENABLED=0 go build -o aws-cni -ldflags "-X main.version=42" ./plugins/routed-eni/

2018-07-03T20:40:23Z [INFO] Starting L-IPAMD 42  ...

@mattlandis
Copy link
Copy Markdown
Contributor

Looks good. Thanks for the contribution.

@mattlandis mattlandis merged commit c903c7b into aws:master Jul 5, 2018
@vsiddharth vsiddharth added this to the v1.1 milestone Jul 9, 2018
@ewbankkit ewbankkit deleted the issue-90 branch October 9, 2018 13:58
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