Skip to content

Update to go 1.18, using go modules.#14

Merged
jepio merged 3 commits intoflatcar:flatcar-masterfrom
nat-henderson:go-1.18
Aug 2, 2022
Merged

Update to go 1.18, using go modules.#14
jepio merged 3 commits intoflatcar:flatcar-masterfrom
nat-henderson:go-1.18

Conversation

@nat-henderson
Copy link
Copy Markdown
Contributor

Update this tool to go 1.18 and use go modules instead of vendoring.

Removed all the vendored code + replaced it with equivalent go modules - did not need to upgrade any versions, because the vendoring manifest provided what was needed to get the same versions of the code in go modules.

How to use

No changes needed.

Testing done

Built and tested using the scripts included in the repo.

  • Changelog entries added in the respective changelog/ directory (user-facing change, bug fix, security fix, update)
    No need, no user-visible change.

@jepio
Copy link
Copy Markdown
Member

jepio commented Aug 2, 2022

Thanks for this! I'm really curious how you were able to build this though, when I try it I get:

$ GOBIN=$PWD/ ./build
go: downloading github.com/cloudsigma/cepgo v0.0.0-20140805094338-1bfc4895bf5c
go: downloading github.com/coreos/yaml v0.0.0-20141224210557-6b16a5714269
go: downloading github.com/sigma/vmw-guestinfo v0.0.0-20160204083807-95dd4126d6e8
go: downloading github.com/sigma/vmw-ovflib v0.0.0-20150531125353-56b4f44581ca
go: downloading github.com/coreos/go-systemd v0.0.0-20140326023052-4fbc5060a317
go: downloading github.com/dotcloud/docker v0.11.2-0.20140522020950-55d41c3e21e1
go: downloading github.com/tarm/goserial v0.0.0-20140420040555-cdabc8d44e8e
go: downloading github.com/guelfey/go.dbus v0.0.0-20131113121618-f6a3a2366cc3
go: downloading github.com/sigma/bdoor v0.0.0-20160202064022-babf2a4017b0
../go/pkg/mod/github.com/sigma/vmw-guestinfo@v0.0.0-20160204083807-95dd4126d6e8/rpcvmx/rpcvmx.go:7:2: no required module provides package github.com/vmware/vmw-guestinfo/rpcout; to add it:
	go get github.com/vmware/vmw-guestinfo/rpcout

I then tried various go get but those cause other issues.

I found a way to get it to work with a replace, will push that.

Other comments:

  • I don't think we ever actively used travis, so I will remove it. I've added github actions on the main branch
  • I'll vendor the code, it makes building this into flatcar easier

@jepio jepio merged commit 02ed608 into flatcar:flatcar-master Aug 2, 2022
jepio added a commit to flatcar-archive/coreos-overlay that referenced this pull request Aug 3, 2022
This pulls in these PRs:
- flatcar/coreos-cloudinit#13 (imdsv2)
- flatcar/coreos-cloudinit#14 (go.mod)

Since go.mod is now present, rework the ebuild to remove unused bits and
enable go module support.
jepio added a commit to flatcar-archive/coreos-overlay that referenced this pull request Aug 4, 2022
This pulls in these PRs:
- flatcar/coreos-cloudinit#13 (imdsv2)
- flatcar/coreos-cloudinit#14 (go.mod)

Since go.mod is now present, rework the ebuild to remove unused bits and
enable go module support.
jepio added a commit to flatcar-archive/coreos-overlay that referenced this pull request Aug 4, 2022
This pulls in these PRs:
- flatcar/coreos-cloudinit#13 (imdsv2)
- flatcar/coreos-cloudinit#14 (go.mod)

Since go.mod is now present, rework the ebuild to remove unused bits and
enable go module support.
jepio added a commit to flatcar-archive/coreos-overlay that referenced this pull request Aug 4, 2022
This pulls in these PRs:
- flatcar/coreos-cloudinit#13 (imdsv2)
- flatcar/coreos-cloudinit#14 (go.mod)

Since go.mod is now present, rework the ebuild to remove unused bits and
enable go module support.
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.

2 participants