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

Replacing dep with go modules #662

Merged
merged 12 commits into from
Jan 4, 2019
Merged

Conversation

marcosy
Copy link
Contributor

@marcosy marcosy commented Dec 27, 2018

Pull Request check list

  • Commit conforms to CONTRIBUTING.md?
  • Proper tests/regressions included?
  • Documentation updated?

Affected functionality
SPIRE build experience

Description of change

  • Dep removed
  • Go modules added
  • Help target added to makefile
  • Docs updated
  • Import path of gofrs/uuid updated (due to issue 61)
  • Additional module created for tools/utils as recommended.

Which issue this PR fixes

Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
azdagron
azdagron previously approved these changes Jan 2, 2019
Copy link
Member

@azdagron azdagron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awesome!

@azdagron
Copy link
Member

azdagron commented Jan 2, 2019

Thinking about this more, is there a reason we created utils/utils.go instead of tools/tools.go? tools/ already has a subfolder for a build related tool. tools.go also follows officially recommended naming conventions.

@marcosy
Copy link
Contributor Author

marcosy commented Jan 3, 2019

You are right, I will update the PR to use the "tools" folder

Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Signed-off-by: Marcos G. Yedro <marcosyedro@gmail.com>
Copy link
Member

@azdagron azdagron left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💯

@@ -22,25 +21,23 @@ For development that requires changes to the gRPC interfaces you will need:

# Building

It is assumed that this repository lives in $GOPATH/src/github.com/spiffe/spire on your local disk,
and that your GOPATH only contains one element.
Since go modules are used, this repository can live in any folder on your local disk (it is not required to be in GOPATH).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we need a reminder here to set env flag?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think so... It is not required to set the GO111MODULE env flag manually if SPIRE is built using make. This variable is exported in the Makefile (line 13).

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 thanks @marcosy !

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, if unset, or set to auto, go modules mode will be automatically activated if the current directory (or a parent directory) contains a valid go.mod file. So you should be able to check out the repo, step into the directory, and run go build github.com/spiffe/spire/cmd/spire-server and have it just work.

@marcosy marcosy merged commit a70be87 into spiffe:master Jan 4, 2019
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.

Improve SPIRE build experience
3 participants