Created
March 6, 2020 12:55
-
-
Save holms/b797f62525ef90e1fe3a4e346cc0ff82 to your computer and use it in GitHub Desktop.
go problem
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package aerospike_shared | |
import ( | |
"bytes" | |
"fmt" | |
"log" | |
"math" | |
"os" | |
"runtime" | |
"strconv" | |
as "github.com/aerospike/aerospike-client-go" | |
) | |
var WritePolicy = as.NewWritePolicy(0, 0) | |
var Policy = as.NewPolicy() | |
var Host = os.Getenv("AEROSPIKE_HOST") | |
var Port, PortErr = strconv.Atoi(os.Getenv("AEROSPIKE_PORT")) | |
var Namespace = "prebid" | |
var Set = "prebid_configs" | |
var Client *as.Client | |
func init() { | |
// use all cpus in the system for concurrency | |
runtime.GOMAXPROCS(runtime.NumCPU()) | |
log.SetOutput(os.Stdout) | |
var err error | |
Сlient, err = as.NewClient(Host, Port) | |
if err != nil { | |
PanicOnError(err) | |
} | |
} | |
func PanicOnError(err error) { | |
if err != nil { | |
log.Fatalln(err.Error()) | |
} | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
package prebid_config | |
import ( | |
"net/http" | |
"github.com/labstack/echo/v4" | |
"github.com/labstack/echo/v4/middleware" | |
"github.com/labstack/gommon/log" | |
) | |
import aero "prebid_config/aerospike_shared" | |
func main() { | |
// Echo instance | |
e := echo.New() | |
e.Logger.SetLevel(log.ERROR) | |
e.Use(middleware.Logger()) | |
e.GET("/", func(c echo.Context) error { | |
return c.String(http.StatusOK, "Hello, World!") | |
}) | |
// Connect to Aerospike | |
var a = aero.Client | |
// Start server | |
e.Logger.Fatal(e.Start(":1323")) | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Step 11/12 : RUN go install -v ./... | |
---> Running in 43c57f19e813 | |
github.com/aerospike/aerospike-client-go/internal/lua/resources | |
github.com/aerospike/aerospike-client-go/internal/particle_type | |
github.com/valyala/bytebufferpool | |
golang.org/x/text/transform | |
net | |
github.com/valyala/fasttemplate | |
golang.org/x/sys/unix | |
golang.org/x/text/unicode/bidi | |
golang.org/x/text/unicode/norm | |
golang.org/x/text/secure/bidirule | |
golang.org/x/net/http2/hpack | |
github.com/labstack/gommon/bytes | |
golang.org/x/net/idna | |
github.com/labstack/gommon/random | |
github.com/aerospike/aerospike-client-go/internal/atomic | |
github.com/aerospike/aerospike-client-go/logger | |
github.com/aerospike/aerospike-client-go/types | |
github.com/mattn/go-isatty | |
github.com/yuin/gopher-lua/ast | |
github.com/mattn/go-colorable | |
github.com/yuin/gopher-lua/pm | |
github.com/yuin/gopher-lua/parse | |
github.com/labstack/gommon/color | |
crypto/x509 | |
github.com/labstack/gommon/log | |
net/textproto | |
vendor/golang.org/x/net/http/httpproxy | |
github.com/aerospike/aerospike-client-go/pkg/bcrypt | |
vendor/golang.org/x/net/http/httpguts | |
golang.org/x/net/http/httpguts | |
github.com/aerospike/aerospike-client-go/pkg/ripemd160 | |
github.com/aerospike/aerospike-client-go/types/rand | |
github.com/yuin/gopher-lua | |
github.com/aerospike/aerospike-client-go/utils/buffer | |
golang.org/x/sync/errgroup | |
github.com/dgrijalva/jwt-go | |
crypto/tls | |
net/http/httptrace | |
net/http | |
github.com/aerospike/aerospike-client-go/internal/lua | |
github.com/aerospike/aerospike-client-go | |
net/http/httputil | |
golang.org/x/net/http2 | |
golang.org/x/crypto/acme | |
golang.org/x/crypto/acme/autocert | |
golang.org/x/net/http2/h2c | |
github.com/labstack/echo/v4 | |
prebid_config/aerospike_shared | |
# prebid_config/aerospike_shared | |
aerospike_shared/client.go:33:2: undefined: Сlient | |
github.com/labstack/echo/v4/middleware | |
ERROR: Service 'app-prebid-config' failed to build: The command '/bin/sh -c go install -v ./...' returned a non-zero code: 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment