deploy without errors
compile failed:
Compile failed:
2016/11/23 03:04:00 go-app-builder: Failed parsing input (12 errors)
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:140:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:141:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:142:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:143:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:144:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:145:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:146:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:147:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:148:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:149:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:150:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
2016/11/23 03:04:00 golang.org/x/crypto/ocsp/ocsp.go:151:32: composite struct literal encoding/asn1.ObjectIdentifier with unkeyed fields
--- end server output ---
install last version then deploy to app engine
master
Can you provide an example and steps to deploy?
sorry for being late
yes sure:
app engine simple code:
package main
import (
"github.com/labstack/echo"
"github.com/labstack/echo/middleware"
"net/http"
)
func createMux() *echo.Echo {
e := echo.New()
e.Debug = true
e.Pre(middleware.RemoveTrailingSlash())
http.Handle("/", e)
return e
}
func init() {
e := createMux()
e.GET("/", mainPage)
}
func mainPage(c echo.Context) error {
return c.String(200,"hello world !")
}
this main.go file
another file is important for app engine app.yaml:
application: [app id in console.cloud.google.com]
version: 1
runtime: go
api_version: go1
handlers:
- url: /assets
static_dir: static
- url: /.*
script: _go_app
and after you download app engine SDK you can deploy it using "goapp deploy" I'm using ubuntu.
I think the problem in go version because it can serve (test it locally) without any problem "goapp serve" and when I deploy it comes that error
google app engine support go1.6 and the error in this package golang.org/x/crypto/ocsp
https://github.com/golang/crypto/pull/19/files
I found a way to fix it.
However, the contribution process of Golang is complicated and difficult...
@mostafadahab Are you good at English?
Please help this discussion.
https://github.com/golang/crypto/pull/19/
I am borrowing the power of Google translation.
@koba-ninkigumi @vishr thanks guys 馃槂
as app engine sdk release notes says:
Go runtime notes
App Engine Go runtime updated to Go 1.6.2.
and in the latest version of app engine is 1.9.46:
Go runtime notes
This release does not include a new Go SDK
it turns out to be issue in go1.6 but it's as @bradfitz says it already fixed but we should wait until go app engine sdk upgrade to go1.7 馃槥
@koba-ninkigumi no worries man I hope google app engine team upgrade to go1.7 as fast as japan fiexd Fukuoka sinkhole 馃槂
@vishr do you any any workaround to this? if there's no workaround I think it's will be good idea to mention in echo documentation that is go1.6 have this issue or somehow disable go vet
Thank you for sharing very important information @poweroftrue @koba-ninkigumi
Actually I met the same problem this weekend and I wasted my precious two days 馃槩
I also wish google would upgrade soon 馃檹
@koba-ninkigumi @iwag I found a workaround 馃槃
after reading google app engine go group I think it will take some time because maybe they'll skip go1.7 to go1.8 directly
so until then if you need to deploy your app you can just remove github.com/rsc/letsencrypt package from echo.go line 55, and remove line 72:
tlsManager letsencrypt.Manager
and finally remvoe StartAutoTLS func line 522 to line 531:
//StartAutoTLS starts the HTTPS server using certificates automatically from https://letsencrypt.org.
func (e *Echo) StartAutoTLS(address string, hosts []string, cacheFile string) (err error) {
config := new(tls.Config)
config.GetCertificate = e.tlsManager.GetCertificate
e.tlsManager.SetHosts(hosts) // Added security
if err = e.tlsManager.CacheFile(cacheFile); err != nil {
return
}
return e.startTLS(address, config)
}
you can find echo.go inside github.com/labstack/echo folder in your GOPATH
after that you can deploy without any hassle 馃槈
* because app engine automatically handles https nothing will break
happy coding !
@poweroftrue We can have a build flag for not including auto TLS for gae. Do they have any issue open for this - just for tracking, once resolved, we can revert back.
I really get confused!
I tried to build and run standalone simple echo v3 with go1.6.3 and go1.6.2 and even go1.6 and there is no problem
@vishr maybe the problem in the modified version of go (goapp) so I reported the issue here
This issue is fixed Go SDK version 1.9.48.
https://console.cloud.google.com/storage/browser/appengine-sdks/featured/
馃憦