Skip to content

Commit

Permalink
Merge pull request #104 from kaleido-io/revert-103-update-enterprise-…
Browse files Browse the repository at this point in the history
…version

Revert "Update enterprise version"
  • Loading branch information
nguyer authored Apr 15, 2024
2 parents eebfba9 + 1f82aa9 commit 226c765
Show file tree
Hide file tree
Showing 203 changed files with 26,543 additions and 17,031 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/docker_release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ jobs:
- name: Set build tag
id: build_tag_generator
run: |
RELEASE_TAG=${{ github.ref_name }}
RELEASE_TAG=$(curl https://api.github.com/repos/${{ github.repository }}/releases/latest -s | jq .tag_name -r)
BUILD_TAG=$RELEASE_TAG-$(date +"%Y%m%d")-$GITHUB_RUN_NUMBER
BUILD_DATE=$(date -u +"%Y-%m-%dT%H:%M:%SZ")
echo "BUILD_TAG=$BUILD_TAG" >> $GITHUB_OUTPUT
Expand All @@ -76,7 +76,7 @@ jobs:
builder: ${{ steps.buildx.outputs.name }}
push: true
platforms: linux/amd64
tags: ghcr.io/${{ github.repository }}:${{ steps.build_tag_generator.outputs.RELEASE_TAG }},ghcr.io/${{ github.repository }}:head,${{ env.DOCKER_TAGS }}
tags: ghcr.io/${{ github.repository }}:${{ github.ref_name }},ghcr.io/${{ github.repository }}:head,${{ env.DOCKER_TAGS }}
labels: |
commit=${{ github.sha }}
build_date=${{ steps.build_tag_generator.outputs.BUILD_DATE }}
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/go.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.21
go-version: 1.19

- name: Build and Test
run: make
Expand All @@ -38,7 +38,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.21
go-version: 1.19

- name: Build Docker image
run: make docker
Expand Down Expand Up @@ -130,7 +130,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.21
go-version: 1.19

- name: Download Docker image
uses: actions/download-artifact@v3
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.21
go-version: 1.18

- name: Update manifest to latest commit for every service
run: ./manifestgen.sh head
Expand Down Expand Up @@ -91,7 +91,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: 1.21
go-version: 1.18

- name: Update manifest to latest commit for every service
run: ./manifestgen.sh head
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/solidity.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ jobs:
- name: Use Node.js
uses: actions/setup-node@v2
with:
node-version: "20.x"
node-version: "16.x"
- run: npm ci
working-directory: ./smart_contracts/ethereum/solidity_firefly
- run: npm run test
Expand Down
53 changes: 13 additions & 40 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,33 +9,17 @@ ARG GIT_REF
FROM $FIREFLY_BUILDER_TAG AS firefly-builder
ARG BUILD_VERSION
ARG GIT_REF
RUN apk add make=4.4.1-r2 \
gcc=13.2.1_git20231014-r0 \
build-base=0.5-r3 \
curl=8.5.0-r0 \
git=2.43.0-r0
RUN apk add make gcc build-base curl git
WORKDIR /firefly
RUN chgrp -R 0 /firefly \
&& chmod -R g+rwX /firefly \
&& mkdir /.cache \
&& chgrp -R 0 /.cache \
&& chmod -R g+rwX /.cache
USER 1001
ADD --chown=1001:0 go.mod go.sum ./
ADD go.mod go.sum ./
RUN go mod download
ADD --chown=1001:0 . .
ADD . .
RUN make build

FROM --platform=$FABRIC_BUILDER_PLATFORM $FABRIC_BUILDER_TAG AS fabric-builder
RUN apk add gcompat=1.1.0-r4
RUN apk add libc6-compat
WORKDIR /firefly/smart_contracts/fabric/firefly-go
RUN chgrp -R 0 /firefly \
&& chmod -R g+rwX /firefly \
&& mkdir /.cache \
&& chgrp -R 0 /.cache \
&& chmod -R g+rwX /.cache
USER 1001
ADD --chown=1001:0 smart_contracts/fabric/firefly-go .
ADD smart_contracts/fabric/firefly-go .
RUN GO111MODULE=on go mod vendor
WORKDIR /tmp/fabric
RUN wget https://github.com/hyperledger/fabric/releases/download/v2.3.2/hyperledger-fabric-linux-amd64-2.3.2.tar.gz
Expand All @@ -45,11 +29,9 @@ RUN ./bin/peer lifecycle chaincode package /firefly/smart_contracts/fabric/firef

FROM $SOLIDITY_BUILDER_TAG AS solidity-builder
WORKDIR /firefly/solidity_firefly
RUN chgrp -R 0 /firefly \
&& chmod -R g+rwX /firefly
ADD --chown=1001:0 smart_contracts/ethereum/solidity_firefly/ .
USER 1001
RUN mkdir -p build/contracts \
ADD smart_contracts/ethereum/solidity_firefly/ .
RUN apk add jq \
&& mkdir -p build/contracts \
&& cd contracts \
&& solc --combined-json abi,bin,devdoc -o ../build/contracts Firefly.sol \
&& cd ../build/contracts \
Expand All @@ -66,24 +48,15 @@ RUN trivy sbom /sbom.spdx.json --severity UNKNOWN,HIGH,CRITICAL --exit-code 1
FROM $BASE_TAG
ARG UI_TAG
ARG UI_RELEASE
RUN apk add --update --no-cache \
sqlite=3.44.2-r0 \
postgresql16-client=16.2-r0 \
curl=8.5.0-r0 \
jq=1.7.1-r0
RUN apk add --update --no-cache sqlite postgresql-client curl jq
WORKDIR /firefly
RUN chgrp -R 0 /firefly \
&& chmod -R g+rwX /firefly \
&& mkdir /etc/firefly \
&& chgrp -R 0 /etc/firefly \
&& chmod -R g+rwX /etc/firefly
RUN curl -sL "https://github.com/golang-migrate/migrate/releases/download/$(curl -sL https://api.github.com/repos/golang-migrate/migrate/releases/latest | jq -r '.name')/migrate.linux-amd64.tar.gz" | tar xz \
&& chmod +x ./migrate \
&& mv ./migrate /usr/bin/migrate
COPY --from=firefly-builder --chown=1001:0 /firefly/firefly ./firefly
COPY --from=firefly-builder --chown=1001:0 /firefly/db ./db
COPY --from=solidity-builder --chown=1001:0 /firefly/solidity_firefly/build/contracts ./contracts
COPY --from=fabric-builder --chown=1001:0 /firefly/smart_contracts/fabric/firefly-go/firefly_fabric.tar.gz ./contracts/firefly_fabric.tar.gz
COPY --from=firefly-builder /firefly/firefly ./firefly
COPY --from=firefly-builder /firefly/db ./db
COPY --from=solidity-builder /firefly/solidity_firefly/build/contracts ./contracts
COPY --from=fabric-builder /firefly/smart_contracts/fabric/firefly-go/firefly_fabric.tar.gz ./contracts/firefly_fabric.tar.gz
ENV UI_RELEASE https://github.com/hyperledger/firefly-ui/releases/download/$UI_TAG/$UI_RELEASE.tgz
COPY --from=SBOM /sbom.spdx.json /sbom.spdx.json
RUN mkdir /firefly/frontend \
Expand Down
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ lint: ${LINT}
${MOCKERY}:
$(VGO) install github.com/vektra/mockery/v2@latest
${LINT}:
$(VGO) install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.54.0
$(VGO) install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.47.3
ffcommon:
$(eval WSCLIENT_PATH := $(shell $(VGO) list -f '{{.Dir}}' github.com/hyperledger/firefly-common/pkg/wsclient))

Expand Down
9 changes: 4 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ Other repositories you might be interested in containing those microservice comp
- Permissioned Ethereum connector - https://github.com/hyperledger/firefly-ethconnect
- Private/permissioned: Hyperledger Besu / Quorum
- Hyperledger Fabric connector - https://github.com/hyperledger/firefly-fabconnect
- Tezos connector - https://github.com/hyperledger/firefly-tezosconnect
- Corda connector starter: https://github.com/hyperledger/firefly-cordaconnect
- CorDapp specific customization is required

Expand Down Expand Up @@ -246,10 +245,10 @@ Plugins: Each plugin comprises a Go shim, plus a remote agent microservice runti
│ │ interface │ * Standardized operations, and custom on-chain coupling
│ └─────┬─────────┘
│ │
│ ├─────────────────────┬───────────────────┬-───────────────────
│ ┌─────┴─────────┐ ┌───────┴───────┐ ┌───────┴────────┐ ┌───────┴────────┐
│ │ ethereum │ │ fabric │ │ corda/cordapps │ │ tezos │
│ └─────┬─────────┘ └───────────────┘ └────────────────┘ └────────────────┘
│ ├─────────────────────┬───────────────────┐
│ ┌─────┴─────────┐ ┌───────┴───────┐ ┌───────┴────────┐
│ │ ethereum │ │ fabric │ │ corda/cordapps │
│ └─────┬─────────┘ └───────────────┘ └────────────────┘
│ [REST/WebSockets]
│ ┌─────┴────────────────────┐ ┌────────────────────────┐ ┌─
│ │ transaction manager [Tm] ├───┤ Connector API [ffcapi] ├───┤ Simple framework for building blockchain connectors
Expand Down
3 changes: 0 additions & 3 deletions db/migrations/postgres/000116_tx_type_not_null.down.sql

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrations/postgres/000116_tx_type_not_null.up.sql

This file was deleted.

4 changes: 0 additions & 4 deletions db/migrations/sqlite/000116_tx_type_not_null.down.sql

This file was deleted.

5 changes: 0 additions & 5 deletions db/migrations/sqlite/000116_tx_type_not_null.up.sql

This file was deleted.

9 changes: 2 additions & 7 deletions docker_build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -16,16 +16,10 @@
# See the License for the specific language governing permissions and
# limitations under the License.

handle_error() {
docker buildx rm firefly --keep-state
exit 1
}
trap handle_error ERR

set -e
echo $@

if [[ ! -x `which jq` ]]; then echo "Please install \"jq\" to continue"; exit 1; fi
if [[ ! -x `which jq` ]]; then echo "Please install \"jq\" to continue"; exit 1; fi

FIREFLY_BUILDER_TAG=$(cat manifest.json | jq -r '.build."firefly-builder".image')
FABRIC_BUILDER_TAG=$(cat manifest.json | jq -r '.build."fabric-builder".image')
Expand Down Expand Up @@ -59,3 +53,4 @@ docker buildx build \
--build-arg GIT_REF=$GIT_REF \
$@ \
.
docker buildx rm firefly --keep-state
2 changes: 1 addition & 1 deletion docs/Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,4 @@ group :jekyll_plugins do
gem "jekyll-multiple-languages-plugin"
gem "html-proofer"
gem "webrick"
end
end
25 changes: 0 additions & 25 deletions docs/Gemfile.lock
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,6 @@ GEM
minitest (>= 5.1)
mutex_m
tzinfo (~> 2.0)
addressable (2.8.6)
connection_pool (>= 2.2.5)
drb
i18n (>= 1.6, < 2)
minitest (>= 5.1)
mutex_m
tzinfo (~> 2.0)
addressable (2.8.6)
public_suffix (>= 2.0.2, < 6.0)
afm (0.2.2)
Expand Down Expand Up @@ -47,7 +40,6 @@ GEM
em-websocket (0.5.3)
eventmachine (>= 0.12.9)
http_parser.rb (~> 0)
ethon (0.16.0)
ethon (0.16.0)
ffi (>= 1.15.0)
eventmachine (1.2.7)
Expand All @@ -61,15 +53,12 @@ GEM
fiber-local (1.0.0)
forwardable-extended (2.6.0)
gemoji (3.0.1)
github-pages (228)
github-pages (228)
github-pages-health-check (= 1.17.9)
jekyll (= 3.9.3)
jekyll (= 3.9.3)
jekyll-avatar (= 0.7.0)
jekyll-coffeescript (= 1.1.1)
jekyll-commonmark-ghpages (= 0.4.0)
jekyll-commonmark-ghpages (= 0.4.0)
jekyll-default-layout (= 0.1.4)
jekyll-feed (= 0.15.1)
jekyll-gist (= 1.5.0)
Expand Down Expand Up @@ -104,7 +93,6 @@ GEM
kramdown (= 2.3.2)
kramdown-parser-gfm (= 1.1.0)
liquid (= 4.0.4)
liquid (= 4.0.4)
mercenary (~> 0.3)
minima (= 2.5.1)
nokogiri (>= 1.13.6, < 2.0)
Expand All @@ -130,7 +118,6 @@ GEM
yell (~> 2.0)
zeitwerk (~> 2.5)
http_parser.rb (0.8.0)
i18n (1.14.1)
i18n (1.14.1)
concurrent-ruby (~> 1.0)
io-event (1.4.2)
Expand All @@ -139,7 +126,6 @@ GEM
colorator (~> 1.0)
em-websocket (~> 0.5)
i18n (>= 0.7, < 2)
i18n (>= 0.7, < 2)
jekyll-sass-converter (~> 1.0)
jekyll-watch (~> 2.0)
kramdown (>= 1.17, < 3)
Expand All @@ -155,14 +141,11 @@ GEM
coffee-script-source (~> 1.11.1)
jekyll-commonmark (1.4.0)
commonmarker (~> 0.22)
jekyll-commonmark-ghpages (0.4.0)
commonmarker (~> 0.23.7)
jekyll-commonmark-ghpages (0.4.0)
commonmarker (~> 0.23.7)
jekyll (~> 3.9.0)
jekyll-commonmark (~> 1.4.0)
rouge (>= 2.0, < 5.0)
rouge (>= 2.0, < 5.0)
jekyll-default-layout (0.1.4)
jekyll (~> 3.0)
jekyll-feed (0.15.1)
Expand Down Expand Up @@ -253,8 +236,6 @@ GEM
kramdown-parser-gfm (1.1.0)
kramdown (~> 2.0)
liquid (4.0.4)
listen (3.8.0)
liquid (4.0.4)
listen (3.8.0)
rb-fsevent (~> 0.10, >= 0.10.3)
rb-inotify (~> 0.9, >= 0.9.10)
Expand Down Expand Up @@ -286,13 +267,11 @@ GEM
ttfunk
public_suffix (4.0.7)
racc (1.7.3)
racc (1.7.3)
rainbow (3.1.1)
rb-fsevent (0.11.2)
rb-inotify (0.10.1)
ffi (~> 1.0)
rexml (3.2.6)
rexml (3.2.6)
rouge (3.26.0)
ruby-rc4 (0.1.5)
ruby2_keywords (0.0.5)
Expand All @@ -316,18 +295,14 @@ GEM
ethon (>= 0.9.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
tzinfo (2.0.6)
concurrent-ruby (~> 1.0)
unf (0.1.4)
unf_ext
unf_ext (0.0.9.1)
unf_ext (0.0.9.1)
unicode-display_width (1.8.0)
uri (0.13.0)
webrick (1.8.1)
yell (2.2.2)
zeitwerk (2.6.12)
zeitwerk (2.6.12)

PLATFORMS
arm64-darwin-21
Expand Down
1 change: 0 additions & 1 deletion docs/_i18n/en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,3 @@ pages:
xdc_testnet: XDC Testnet
zksync_testnet: zkSync Testnet
rotate_dx_certs: Rotate Data Exchange Certificates
tezos_testnet: Tezos Testnet
Loading

0 comments on commit 226c765

Please sign in to comment.