The answer to your question:

I don't know what is the proper way to define the import path for local packages.

As @JimB said:

If you want to use the Go tools you need to follow the conventions. If you want go get to work, then you need to import it with the full name, otherwise put it wherever you want in GOPATH

github.com/levin/foogo get

The answer to your second question:

Wouldn't it cause much rework if I move my codes to Bitbucket or I host my own git server in AWS?

There is a way to use a custom domain name as import path and still host your code wherever you want, it's called a vanity import path I think. You just need to add some meta tags to the html file that gets served in the import file that you use.

go-importgithub.com/foo/barfoo.com/bar
foo.com/bar
<meta name="go-import" content="golang.org/x/tools git http://github.com/foo/bar">
"foo.com/bar
foo.com/bargithub.com/foo/bar
package bar // import "foo.com/bar"
go get
github.com/levin/foofoo2foo2foo2