From b5ae155dfded53c1f33468850a526973ba8e7f5c Mon Sep 17 00:00:00 2001 From: Peter Broadhurst Date: Wed, 13 Jul 2022 08:15:12 -0400 Subject: [PATCH 1/2] Update to Go 1.17 Signed-off-by: Peter Broadhurst --- .github/workflows/go.yaml | 2 +- .golangci.yml | 4 +- Dockerfile | 4 +- go.mod | 81 +++++++++++++++++++++++++++++---------- 4 files changed, 66 insertions(+), 25 deletions(-) diff --git a/.github/workflows/go.yaml b/.github/workflows/go.yaml index 2a550359..6e2d855a 100644 --- a/.github/workflows/go.yaml +++ b/.github/workflows/go.yaml @@ -22,7 +22,7 @@ jobs: - name: Set up Go uses: actions/setup-go@v2 with: - go-version: 1.16 + go-version: 1.17 - name: Install solc run: | diff --git a/.golangci.yml b/.golangci.yml index 3cc690ef..7e1f9b9b 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -3,10 +3,10 @@ run: linters-settings: golint: {} staticcheck: - go: "1.16" + go: "1.17" checks: ["all"] stylecheck: - go: "1.16" + go: "1.17" checks: ["all", "-ST1005"] gocritic: enabled-checks: [] diff --git a/Dockerfile b/Dockerfile index ce0d00e2..6e7d9313 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,8 +1,8 @@ -FROM golang:1.16-buster AS builder +FROM golang:1.17-buster AS builder WORKDIR /ethconnect RUN apt-get update -y \ && apt-get install -y build-essential git \ - && curl -Lo /usr/bin/solc https://github.com/ethereum/solidity/releases/download/v0.7.6/solc-static-linux \ + && curl -Lo /usr/bin/solc https://github.com/ethereum/solidity/releases/download/v0.8.15/solc-static-linux \ && chmod 755 /usr/bin/solc ADD go.mod go.sum ./ RUN grep -v ethbinding go.mod > go.mod.new \ diff --git a/go.mod b/go.mod index d6f65fea..3efbdcea 100644 --- a/go.mod +++ b/go.mod @@ -2,61 +2,102 @@ module github.com/hyperledger/firefly-ethconnect require ( github.com/Masterminds/semver v1.5.0 - github.com/PuerkitoBio/purell v1.1.1 // indirect - github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect github.com/Shopify/sarama v1.33.0 github.com/alecthomas/template v0.0.0-20190718012654-fb15b899a751 - github.com/bketelsen/crypt v0.0.4 // indirect - github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect - github.com/dsnet/compress v0.0.1 // indirect github.com/ethereum/go-ethereum v1.10.17 - github.com/fsnotify/fsnotify v1.5.4 // indirect github.com/globalsign/mgo v0.0.0-20181015135952-eeefdecb41b8 github.com/go-openapi/jsonreference v0.20.0 github.com/go-openapi/spec v0.20.6 - github.com/go-openapi/swag v0.21.1 // indirect github.com/gorilla/websocket v1.5.0 - github.com/hashicorp/errwrap v1.1.0 // indirect - github.com/hashicorp/go-uuid v1.0.3 // indirect github.com/hashicorp/golang-lru v0.5.5-0.20210104140557-80c98217689d github.com/hyperledger/firefly-common v0.1.4 github.com/icza/dyno v0.0.0-20210726202311-f1bafe5d9996 github.com/julienschmidt/httprouter v1.3.0 github.com/kaleido-io/ethbinding v0.0.0-20220405144420-999853435d9e + github.com/mholt/archiver v3.1.1+incompatible + github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d + github.com/oklog/ulid/v2 v2.0.2 + github.com/sirupsen/logrus v1.8.1 + github.com/spf13/cobra v1.4.0 + github.com/stretchr/testify v1.7.1 + github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 + github.com/tidwall/gjson v1.14.1 + github.com/x-cray/logrus-prefixed-formatter v0.5.2 + gopkg.in/yaml.v2 v2.4.0 +) + +require ( + github.com/PuerkitoBio/purell v1.1.1 // indirect + github.com/PuerkitoBio/urlesc v0.0.0-20170810143723-de5bf2ad4578 // indirect + github.com/aidarkhanov/nanoid v1.0.8 // indirect + github.com/bketelsen/crypt v0.0.4 // indirect + github.com/btcsuite/btcd/btcec/v2 v2.2.0 // indirect + github.com/davecgh/go-spew v1.1.1 // indirect + github.com/deckarep/golang-set v1.8.0 // indirect + github.com/decred/dcrd/dcrec/secp256k1/v4 v4.0.1 // indirect + github.com/docker/go-units v0.4.0 // indirect + github.com/dsnet/compress v0.0.1 // indirect + github.com/eapache/go-resiliency v1.2.0 // indirect + github.com/eapache/go-xerial-snappy v0.0.0-20180814174437-776d5712da21 // indirect + github.com/eapache/queue v1.1.0 // indirect + github.com/fsnotify/fsnotify v1.5.4 // indirect + github.com/go-ole/go-ole v1.2.6 // indirect + github.com/go-openapi/jsonpointer v0.19.5 // indirect + github.com/go-openapi/swag v0.21.1 // indirect + github.com/go-resty/resty/v2 v2.7.0 // indirect + github.com/go-stack/stack v1.8.1 // indirect + github.com/golang/snappy v0.0.4 // indirect + github.com/google/uuid v1.3.0 // indirect + github.com/hashicorp/errwrap v1.1.0 // indirect + github.com/hashicorp/go-multierror v1.1.1 // indirect + github.com/hashicorp/go-uuid v1.0.3 // indirect + github.com/hashicorp/hcl v1.0.0 // indirect + github.com/inconshreveable/mousetrap v1.0.0 // indirect + github.com/jcmturner/aescts/v2 v2.0.0 // indirect + github.com/jcmturner/dnsutils/v2 v2.0.0 // indirect + github.com/jcmturner/gofork v1.0.0 // indirect + github.com/jcmturner/gokrb5/v8 v8.4.2 // indirect + github.com/jcmturner/rpc/v2 v2.0.3 // indirect + github.com/josharian/intern v1.0.0 // indirect github.com/klauspost/compress v1.15.4 // indirect + github.com/magiconair/properties v1.8.6 // indirect github.com/mailru/easyjson v0.7.7 // indirect github.com/mattn/go-colorable v0.1.12 // indirect + github.com/mattn/go-isatty v0.0.14 // indirect github.com/mgutz/ansi v0.0.0-20200706080929-d51e80ef957d // indirect - github.com/mholt/archiver v3.1.1+incompatible github.com/microcosm-cc/bluemonday v1.0.18 // indirect github.com/mitchellh/mapstructure v1.5.0 // indirect - github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d github.com/nwaples/rardecode v1.1.3 // indirect - github.com/oklog/ulid/v2 v2.0.2 github.com/pelletier/go-toml v1.9.5 // indirect github.com/pelletier/go-toml/v2 v2.0.1 // indirect + github.com/pierrec/lz4 v2.6.1+incompatible // indirect + github.com/pkg/errors v0.9.1 // indirect + github.com/rcrowley/go-metrics v0.0.0-20201227073835-cf1acfcdf475 // indirect github.com/shirou/gopsutil v3.21.11+incompatible // indirect - github.com/sirupsen/logrus v1.8.1 + github.com/spf13/afero v1.8.2 // indirect github.com/spf13/cast v1.5.0 // indirect - github.com/spf13/cobra v1.4.0 + github.com/spf13/jwalterweatherman v1.1.0 // indirect + github.com/spf13/pflag v1.0.5 // indirect github.com/spf13/viper v1.11.0 // indirect - github.com/stretchr/testify v1.7.1 - github.com/syndtr/goleveldb v1.0.1-0.20210819022825-2ae1ddf74ef7 - github.com/tidwall/gjson v1.14.1 + github.com/subosito/gotenv v1.2.0 // indirect + github.com/tidwall/match v1.1.1 // indirect + github.com/tidwall/pretty v1.2.0 // indirect github.com/tklauser/go-sysconf v0.3.10 // indirect github.com/tklauser/numcpus v0.5.0 // indirect github.com/ulikunitz/xz v0.5.10 // indirect - github.com/x-cray/logrus-prefixed-formatter v0.5.2 github.com/xi2/xz v0.0.0-20171230120015-48954b6210f8 // indirect github.com/yusufpapurcu/wmi v1.2.2 // indirect golang.org/x/crypto v0.0.0-20220513210258-46612604a0f9 // indirect golang.org/x/net v0.0.0-20220516155154-20f960328961 // indirect golang.org/x/sys v0.0.0-20220513210249-45d2b4557a2a // indirect golang.org/x/term v0.0.0-20220411215600-e5f449aeb171 // indirect - gopkg.in/yaml.v2 v2.4.0 + golang.org/x/text v0.3.7 // indirect + gopkg.in/ini.v1 v1.66.4 // indirect + gopkg.in/natefinch/lumberjack.v2 v2.0.0 // indirect + gopkg.in/natefinch/npipe.v2 v2.0.0-20160621034901-c1b8fa8bdcce // indirect gopkg.in/yaml.v3 v3.0.0-20220512140231-539c8e751b99 // indirect ) replace github.com/kaleido-io/ethbinding => ../ethbinding -go 1.16 +go 1.17 From 9568e3ab20289d23b843131a1e3777fec5ca7ebb Mon Sep 17 00:00:00 2001 From: Peter Broadhurst Date: Mon, 10 Oct 2022 12:01:15 -0400 Subject: [PATCH 2/2] Tweak Signed-off-by: Peter Broadhurst --- ethconnect_config.yaml | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/ethconnect_config.yaml b/ethconnect_config.yaml index a21ed029..f2ade182 100644 --- a/ethconnect_config.yaml +++ b/ethconnect_config.yaml @@ -1,10 +1,7 @@ rest: rest-gateway: rpc: - # url: http://localhost:5100 - # url: https://rinkeby.infura.io/v3/58c5cbc3c9914486920a3af499524e2e - # url: https://zznk5vma71:oa46BpfMExfJdJXn8KKp2-DAYZmdjAUB4qS5LjlIxxI@zzebuedy57-zzne11vbct-rpc.dev2-ws.photic.io/ - url: https://zzwvqdkvg2:NA9LRWV0TTH9v2A4IkuBDD6h4BHhFH9ItbEbYySvKW0@zzldved9px-zziextwnth-rpc.dev2-ws.photic.io/ + url: http://localhost:5100 openapi: eventPollingIntervalSec: 1 storagePath: /tmp/ethc