From 1ee65967a7ed70a4ef0f2e92f7ecc2a1691c78af Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jun 2024 19:42:01 +0000 Subject: [PATCH 01/17] Bump elixir from 1.14.3-otp-24 to 1.16.2-otp-26 Bumps elixir from 1.14.3-otp-24 to 1.16.2-otp-26. --- updated-dependencies: - dependency-name: elixir dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 97eeb5e3..645272c2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ #=========== #(Elixir) Build Stage #=========== -FROM elixir:1.14.3-otp-24 as builder-elixir +FROM elixir:1.16.2-otp-26 as builder-elixir RUN mkdir -p /mix WORKDIR /mix @@ -24,7 +24,7 @@ RUN mix local.hex --force && \ #================ #Deployment Stage #================ -FROM elixir:1.14.3-otp-24 as deployer +FROM elixir:1.16.2-otp-26 as deployer # RUN mkdir -p /app/test /app/prod RUN apt-get update && apt-get install -y git bash curl netcat-traditional && apt-get clean && rm -rf /var/lib/apt/lists/* From 070dc9aabc1bdde744278cc61a8e8c2fc172988c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jun 2024 19:44:03 +0000 Subject: [PATCH 02/17] Bump confex from 3.5.0 to 3.5.1 Bumps [confex](https://github.com/Nebo15/confex) from 3.5.0 to 3.5.1. - [Changelog](https://github.com/Nebo15/confex/blob/master/CHANGELOG.md) - [Commits](https://github.com/Nebo15/confex/compare/3.5.0...3.5.1) --- updated-dependencies: - dependency-name: confex dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- mix.lock | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mix.lock b/mix.lock index 38ab1d65..ede01910 100644 --- a/mix.lock +++ b/mix.lock @@ -8,7 +8,7 @@ "castore": {:hex, :castore, "0.1.22", "4127549e411bedd012ca3a308dede574f43819fe9394254ca55ab4895abfa1a2", [:mix], [], "hexpm", "c17576df47eb5aa1ee40cc4134316a99f5cad3e215d5c77b8dd3cfef12a22cac"}, "certifi": {:hex, :certifi, "2.13.0", "e52be248590050b2dd33b0bb274b56678f9068e67805dca8aa8b1ccdb016bbf6", [:rebar3], [], "hexpm", "8f3d9533a0f06070afdfd5d596b32e21c6580667a492891851b0e2737bc507a1"}, "comeonin": {:hex, :comeonin, "5.3.3", "2c564dac95a35650e9b6acfe6d2952083d8a08e4a89b93a481acb552b325892e", [:mix], [], "hexpm", "3e38c9c2cb080828116597ca8807bb482618a315bfafd98c90bc22a821cc84df"}, - "confex": {:hex, :confex, "3.5.0", "163857c73dd8f88a3815663f4bc00bee1b9c65daf40aa6e0d6ef272757fd22c7", [:mix], [], "hexpm", "34a9e31230c7fbb3dbe60db00341d0c84ee44ba3caf84b498f501c0bc8563570"}, + "confex": {:hex, :confex, "3.5.1", "c29ea741715de06afe6294ea2e127ee7a54382f2b33656b9ed7eedf3e7b6fcaf", [:mix], [], "hexpm", "c72824a267edc96c09a35f6556f48c139d00393dd1b726b18faeb8efee62c0b0"}, "cors_plug": {:hex, :cors_plug, "3.0.3", "7c3ac52b39624bc616db2e937c282f3f623f25f8d550068b6710e58d04a0e330", [:mix], [{:plug, "~> 1.13", [hex: :plug, repo: "hexpm", optional: false]}], "hexpm", "3f2d759e8c272ed3835fab2ef11b46bddab8c1ab9528167bd463b6452edf830d"}, "cowboy": {:hex, :cowboy, "2.12.0", "f276d521a1ff88b2b9b4c54d0e753da6c66dd7be6c9fca3d9418b561828a3731", [:make, :rebar3], [{:cowlib, "2.13.0", [hex: :cowlib, repo: "hexpm", optional: false]}, {:ranch, "1.8.0", [hex: :ranch, repo: "hexpm", optional: false]}], "hexpm", "8a7abe6d183372ceb21caa2709bec928ab2b72e18a3911aa1771639bef82651e"}, "cowboy_telemetry": {:hex, :cowboy_telemetry, "0.4.0", "f239f68b588efa7707abce16a84d0d2acf3a0f50571f8bb7f56a15865aae820c", [:rebar3], [{:cowboy, "~> 2.7", [hex: :cowboy, repo: "hexpm", optional: false]}, {:telemetry, "~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "7d98bac1ee4565d31b62d59f8823dfd8356a169e7fcbb83831b8a5397404c9de"}, From 123063890cb919d6bba37a3061ab2ed1d346d62c Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jun 2024 19:44:28 +0000 Subject: [PATCH 03/17] Bump ex_secp256k1 from 0.7.2 to 0.7.3 Bumps [ex_secp256k1](https://github.com/ayrat555/ex_secp256k1) from 0.7.2 to 0.7.3. - [Release notes](https://github.com/ayrat555/ex_secp256k1/releases) - [Changelog](https://github.com/ayrat555/ex_secp256k1/blob/master/CHANGELOG.md) - [Commits](https://github.com/ayrat555/ex_secp256k1/compare/v0.7.2...v0.7.3) --- updated-dependencies: - dependency-name: ex_secp256k1 dependency-type: direct:production update-type: version-update:semver-patch ... Signed-off-by: dependabot[bot] --- mix.exs | 2 +- mix.lock | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mix.exs b/mix.exs index 66dde19a..42d2107c 100644 --- a/mix.exs +++ b/mix.exs @@ -50,7 +50,7 @@ defmodule Refiner.MixProject do github: "tsutsu/ethereum_abi", branch: "feature-parse-events-from-abi-specifications", override: true}, - {:ex_secp256k1, "0.7.2", override: true}, + {:ex_secp256k1, "0.7.3", override: true}, {:ex_keccak, "~> 0.7.1", override: true}, {:mnemonic, "~> 0.3"}, {:ex_rlp, "~> 0.6.0", override: true}, diff --git a/mix.lock b/mix.lock index 38ab1d65..1aef2dda 100644 --- a/mix.lock +++ b/mix.lock @@ -22,7 +22,7 @@ "etfs": {:hex, :etfs, "0.2.0", "5dba0d765ef673af8ff8367aee1824b06f5ee4fb75ed34d88318f014ae9575ee", [:mix], [], "hexpm", "e80b8d667663e6894525fba9666b372e28a8e07866b242217dc0bab1abc46e07"}, "ex_keccak": {:hex, :ex_keccak, "0.7.5", "f3b733173510d48ae9a1ea1de415e694b2651f35c787e63f33b5ed0013fbfd35", [:mix], [{:rustler, ">= 0.0.0", [hex: :rustler, repo: "hexpm", optional: true]}, {:rustler_precompiled, "~> 0.7", [hex: :rustler_precompiled, repo: "hexpm", optional: false]}], "hexpm", "8a5e1cb7f96fff5e480ff6a121477b90c4fd8c150984086dffd98819f5d83763"}, "ex_rlp": {:hex, :ex_rlp, "0.6.0", "985391d2356a7cb8712a4a9a2deb93f19f2fbca0323f5c1203fcaf64d077e31e", [:mix], [], "hexpm", "7135db93b861d9e76821039b60b00a6a22d2c4e751bf8c444bffe7a042f1abaf"}, - "ex_secp256k1": {:hex, :ex_secp256k1, "0.7.2", "33398c172813b90fab9ab75c12b98d16cfab472c6dcbde832b13c45ce1c01947", [:mix], [{:rustler, ">= 0.0.0", [hex: :rustler, repo: "hexpm", optional: true]}, {:rustler_precompiled, "~> 0.6", [hex: :rustler_precompiled, repo: "hexpm", optional: false]}], "hexpm", "f3b1bf56e6992e28b9d86e3bf741a4aca3e641052eb47d13ae4f5f4d4944bdaf"}, + "ex_secp256k1": {:hex, :ex_secp256k1, "0.7.3", "489b6fd57fab5a7259ace927d8cb5171aad835e9c7279c2a859a0483cb069415", [:mix], [{:rustler, ">= 0.0.0", [hex: :rustler, repo: "hexpm", optional: true]}, {:rustler_precompiled, "~> 0.7", [hex: :rustler_precompiled, repo: "hexpm", optional: false]}], "hexpm", "ea63159442f4d8143166cd1507da03edc43216d6e7c6bac4b416bdce04f0daa8"}, "excoveralls": {:hex, :excoveralls, "0.16.1", "0bd42ed05c7d2f4d180331a20113ec537be509da31fed5c8f7047ce59ee5a7c5", [:mix], [{:hackney, "~> 1.16", [hex: :hackney, repo: "hexpm", optional: false]}, {:jason, "~> 1.0", [hex: :jason, repo: "hexpm", optional: false]}], "hexpm", "dae763468e2008cf7075a64cb1249c97cb4bc71e236c5c2b5e5cdf1cfa2bf138"}, "expo": {:hex, :expo, "0.5.1", "249e826a897cac48f591deba863b26c16682b43711dd15ee86b92f25eafd96d9", [:mix], [], "hexpm", "68a4233b0658a3d12ee00d27d37d856b1ba48607e7ce20fd376958d0ba6ce92b"}, "file_system": {:hex, :file_system, "0.2.10", "fb082005a9cd1711c05b5248710f8826b02d7d1784e7c3451f9c1231d4fc162d", [:mix], [], "hexpm", "41195edbfb562a593726eda3b3e8b103a309b733ad25f3d642ba49696bf715dc"}, From 2ba2306e6124d91bb4b5e0e5cd0a8bc1c32370e0 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jun 2024 19:45:11 +0000 Subject: [PATCH 04/17] Bump poison from 5.0.0 to 6.0.0 Bumps [poison](https://github.com/devinus/poison) from 5.0.0 to 6.0.0. - [Changelog](https://github.com/devinus/poison/blob/master/CHANGELOG.md) - [Commits](https://github.com/devinus/poison/compare/5.0.0...6.0.0) --- updated-dependencies: - dependency-name: poison dependency-type: direct:production update-type: version-update:semver-major ... Signed-off-by: dependabot[bot] --- mix.exs | 2 +- mix.lock | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/mix.exs b/mix.exs index 66dde19a..156bf117 100644 --- a/mix.exs +++ b/mix.exs @@ -32,7 +32,7 @@ defmodule Refiner.MixProject do defp deps do [ # system exec - {:poison, "~> 5.0"}, + {:poison, "~> 6.0"}, {:distillery, "~> 2.0"}, # frameworks diff --git a/mix.lock b/mix.lock index 38ab1d65..2e4b0ea6 100644 --- a/mix.lock +++ b/mix.lock @@ -52,7 +52,7 @@ "plug": {:hex, :plug, "1.16.0", "1d07d50cb9bb05097fdf187b31cf087c7297aafc3fed8299aac79c128a707e47", [:mix], [{:mime, "~> 1.0 or ~> 2.0", [hex: :mime, repo: "hexpm", optional: false]}, {:plug_crypto, "~> 1.1.1 or ~> 1.2 or ~> 2.0", [hex: :plug_crypto, repo: "hexpm", optional: false]}, {:telemetry, "~> 0.4.3 or ~> 1.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "cbf53aa1f5c4d758a7559c0bd6d59e286c2be0c6a1fac8cc3eee2f638243b93e"}, "plug_cowboy": {:hex, :plug_cowboy, "2.7.1", "87677ffe3b765bc96a89be7960f81703223fe2e21efa42c125fcd0127dd9d6b2", [:mix], [{:cowboy, "~> 2.7", [hex: :cowboy, repo: "hexpm", optional: false]}, {:cowboy_telemetry, "~> 0.3", [hex: :cowboy_telemetry, repo: "hexpm", optional: false]}, {:plug, "~> 1.14", [hex: :plug, repo: "hexpm", optional: false]}], "hexpm", "02dbd5f9ab571b864ae39418db7811618506256f6d13b4a45037e5fe78dc5de3"}, "plug_crypto": {:hex, :plug_crypto, "2.1.0", "f44309c2b06d249c27c8d3f65cfe08158ade08418cf540fd4f72d4d6863abb7b", [:mix], [], "hexpm", "131216a4b030b8f8ce0f26038bc4421ae60e4bb95c5cf5395e1421437824c4fa"}, - "poison": {:hex, :poison, "5.0.0", "d2b54589ab4157bbb82ec2050757779bfed724463a544b6e20d79855a9e43b24", [:mix], [{:decimal, "~> 2.0", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "11dc6117c501b80c62a7594f941d043982a1bd05a1184280c0d9166eb4d8d3fc"}, + "poison": {:hex, :poison, "6.0.0", "9bbe86722355e36ffb62c51a552719534257ba53f3271dacd20fbbd6621a583a", [:mix], [{:decimal, "~> 2.1", [hex: :decimal, repo: "hexpm", optional: true]}], "hexpm", "bb9064632b94775a3964642d6a78281c07b7be1319e0016e1643790704e739a2"}, "poolboy": {:hex, :poolboy, "1.5.2", "392b007a1693a64540cead79830443abf5762f5d30cf50bc95cb2c1aaafa006b", [:rebar3], [], "hexpm", "dad79704ce5440f3d5a3681c8590b9dc25d1a561e8f5a9c995281012860901e3"}, "ranch": {:hex, :ranch, "2.1.0", "2261f9ed9574dcfcc444106b9f6da155e6e540b2f82ba3d42b339b93673b72a3", [:make, :rebar3], [], "hexpm", "244ee3fa2a6175270d8e1fc59024fd9dbc76294a321057de8f803b1479e76916"}, "redix": {:hex, :redix, "1.0.0", "4f310341744ffceab3031394450a4e603d4d1001a697c3f18ae57ae776cbd3fb", [:mix], [{:castore, "~> 0.1.0", [hex: :castore, repo: "hexpm", optional: true]}, {:telemetry, "~> 0.4.0", [hex: :telemetry, repo: "hexpm", optional: false]}], "hexpm", "8c8d9b33b5491737adcd5bb9e0f43b85212a384ac0042f64c156113518266ecb"}, From 765748b06805ca64750ea41e5fa4ed03e1c762e2 Mon Sep 17 00:00:00 2001 From: Pranay Valson Date: Tue, 11 Jun 2024 12:45:53 -0700 Subject: [PATCH 05/17] bump elixir version to 1.16.2-otp-26 Signed-off-by: Pranay Valson --- mix.exs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mix.exs b/mix.exs index 66dde19a..0bcf8358 100644 --- a/mix.exs +++ b/mix.exs @@ -5,7 +5,7 @@ defmodule Refiner.MixProject do [ app: :refiner, version: "0.5.2", - elixir: "~> 1.14.3", + elixir: "~> 1.16.2", start_permanent: Mix.env() == :prod, deps: deps(), test_coverage: [tool: ExCoveralls, export: "cov"], From 3623a2f18070e3c76e4d902871f2e6c03864c4c6 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 11 Jun 2024 22:33:21 +0000 Subject: [PATCH 06/17] Bump elixir from 1.14.3-otp-24 to 1.16.2-otp-26 Bumps elixir from 1.14.3-otp-24 to 1.16.2-otp-26. --- updated-dependencies: - dependency-name: elixir dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 97eeb5e3..645272c2 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ #=========== #(Elixir) Build Stage #=========== -FROM elixir:1.14.3-otp-24 as builder-elixir +FROM elixir:1.16.2-otp-26 as builder-elixir RUN mkdir -p /mix WORKDIR /mix @@ -24,7 +24,7 @@ RUN mix local.hex --force && \ #================ #Deployment Stage #================ -FROM elixir:1.14.3-otp-24 as deployer +FROM elixir:1.16.2-otp-26 as deployer # RUN mkdir -p /app/test /app/prod RUN apt-get update && apt-get install -y git bash curl netcat-traditional && apt-get clean && rm -rf /var/lib/apt/lists/* From a783873537853cac9b4bfbec1c58c71c0ee18762 Mon Sep 17 00:00:00 2001 From: Pranay Valson Date: Wed, 12 Jun 2024 10:41:33 -0700 Subject: [PATCH 07/17] update elixir and otp versions in ci/cd Signed-off-by: Pranay Valson --- .github/workflows/compile-format.yaml | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/.github/workflows/compile-format.yaml b/.github/workflows/compile-format.yaml index b0fb345d..9f756d8c 100644 --- a/.github/workflows/compile-format.yaml +++ b/.github/workflows/compile-format.yaml @@ -3,11 +3,11 @@ name: compile-format on: push: branches: - - "main" + - "main" pull_request: - branches: - - "main" - - "develop" + branches: + - "main" + - "develop" env: MIX_ENV: test @@ -18,8 +18,8 @@ jobs: runs-on: ubuntu-20.04 strategy: matrix: - elixir: [1.14.3] - otp: [24] + elixir: [1.16.2] + otp: [26] steps: - name: Cancel Previous Runs uses: styfle/cancel-workflow-action@0.6.0 @@ -45,7 +45,6 @@ jobs: unzip elixir-otp-24.zip -d einstall echo "$PWD/einstall/bin" >> $GITHUB_PATH - - name: Install hex run: mix local.hex --force From 92c661679936b6dc5b59b865632a2326934e1ea6 Mon Sep 17 00:00:00 2001 From: Pranay Valson Date: Wed, 12 Jun 2024 15:52:28 -0700 Subject: [PATCH 08/17] update elixir and otp versions to 1.14.5-otp-26 ci/cd Signed-off-by: Pranay Valson --- .github/workflows/compile-format.yaml | 10 +++++----- .github/workflows/docker-ci-test.yaml | 5 ++++- Dockerfile | 4 ++-- mix.exs | 2 +- 4 files changed, 12 insertions(+), 9 deletions(-) diff --git a/.github/workflows/compile-format.yaml b/.github/workflows/compile-format.yaml index 9f756d8c..81b0f334 100644 --- a/.github/workflows/compile-format.yaml +++ b/.github/workflows/compile-format.yaml @@ -18,8 +18,8 @@ jobs: runs-on: ubuntu-20.04 strategy: matrix: - elixir: [1.16.2] - otp: [26] + elixir: [1.14.5] + otp: [25] steps: - name: Cancel Previous Runs uses: styfle/cancel-workflow-action@0.6.0 @@ -40,9 +40,9 @@ jobs: - name: Install Elixir run: | - wget https://github.com/elixir-lang/elixir/releases/download/v1.14.3/elixir-otp-24.zip + wget https://github.com/elixir-lang/elixir/releases/download/v1.14.5/elixir-otp-25.zip mkdir einstall - unzip elixir-otp-24.zip -d einstall + unzip elixir-otp-25.zip -d einstall echo "$PWD/einstall/bin" >> $GITHUB_PATH - name: Install hex @@ -53,7 +53,7 @@ jobs: - name: Install OTP run: | - wget -q -O otp.tar.gz https://repo.hex.pm/builds/otp/ubuntu-20.04/OTP-25.0.4.tar.gz + wget -q -O otp.tar.gz https://repo.hex.pm/builds/otp/ubuntu-20.04/OTP-25.0.tar.gz mkdir -p .setup-elixir/otp tar zxf otp.tar.gz -C .setup-elixir/otp --strip-components=1 rm otp.tar.gz diff --git a/.github/workflows/docker-ci-test.yaml b/.github/workflows/docker-ci-test.yaml index 613a3536..b58226e3 100644 --- a/.github/workflows/docker-ci-test.yaml +++ b/.github/workflows/docker-ci-test.yaml @@ -31,7 +31,10 @@ jobs: continue-on-error: true - name: Build & Publish the Docker image run: | - docker buildx create --name builder --use --platform=linux/amd64,linux/arm64 && docker buildx build --platform=linux/amd64,linux/arm64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push + + docker buildx create --name builder --use --platform=linux/amd64 && docker buildx build --platform=linux/amd64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push + + # docker buildx create --name builder --use --platform=linux/amd64,linux/arm64 && docker buildx build --platform=linux/amd64,linux/arm64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push - name: Create .env file run: | diff --git a/Dockerfile b/Dockerfile index 645272c2..27bbebdb 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ #=========== #(Elixir) Build Stage #=========== -FROM elixir:1.16.2-otp-26 as builder-elixir +FROM elixir:1.14.5-otp-26 as builder-elixir RUN mkdir -p /mix WORKDIR /mix @@ -24,7 +24,7 @@ RUN mix local.hex --force && \ #================ #Deployment Stage #================ -FROM elixir:1.16.2-otp-26 as deployer +FROM elixir:1.14.5-otp-26 as deployer # RUN mkdir -p /app/test /app/prod RUN apt-get update && apt-get install -y git bash curl netcat-traditional && apt-get clean && rm -rf /var/lib/apt/lists/* diff --git a/mix.exs b/mix.exs index 0bcf8358..4a6ceaaa 100644 --- a/mix.exs +++ b/mix.exs @@ -5,7 +5,7 @@ defmodule Refiner.MixProject do [ app: :refiner, version: "0.5.2", - elixir: "~> 1.16.2", + elixir: "~> 1.14.5", start_permanent: Mix.env() == :prod, deps: deps(), test_coverage: [tool: ExCoveralls, export: "cov"], From 2a8f4ecf843d97c14b5d51b0527d0e2abe04681c Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Mon, 24 Jun 2024 15:04:50 -0700 Subject: [PATCH 09/17] Switch to alpine based images --- Dockerfile | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/Dockerfile b/Dockerfile index 27bbebdb..adde7d42 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ #=========== #(Elixir) Build Stage #=========== -FROM elixir:1.14.5-otp-26 as builder-elixir +FROM elixir:1.14.5-otp-26-alpine as builder-elixir RUN mkdir -p /mix WORKDIR /mix @@ -24,14 +24,13 @@ RUN mix local.hex --force && \ #================ #Deployment Stage #================ -FROM elixir:1.14.5-otp-26 as deployer +FROM elixir:1.14.5-otp-26-alpine as deployer # RUN mkdir -p /app/test /app/prod -RUN apt-get update && apt-get install -y git bash curl netcat-traditional && apt-get clean && rm -rf /var/lib/apt/lists/* +RUN apk add --no-cache git bash curl netcat-openbsd && rm -rf /var/cache/apk/* RUN mkdir -p /mix/_build /mix/config /mix/deps /mix/lib /mix/priv node/test /mix/test-data -# used in case alpine image are used -# RUN apk update && apk add --no-cache git=2.36.3-r0 bash=5.1.16-r2 curl=7.83.1-r4 go=1.18.7-r0 make=4.3-r0 gcc=11.2.1_git20220219-r2 + WORKDIR /app RUN mix local.hex --force RUN mix local.rebar --force From a23d369cf9bdf07e7c8126074915aaa34126579f Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Mon, 24 Jun 2024 15:36:50 -0700 Subject: [PATCH 10/17] add the installation of Git to the builder-elixir stage. --- Dockerfile | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/Dockerfile b/Dockerfile index adde7d42..f14eed1f 100644 --- a/Dockerfile +++ b/Dockerfile @@ -2,6 +2,10 @@ #(Elixir) Build Stage #=========== FROM elixir:1.14.5-otp-26-alpine as builder-elixir + +# Install git +RUN apk add --no-cache git + RUN mkdir -p /mix WORKDIR /mix From 1228ddfea76fb33c9c08a77bed72dc5f2f4ba031 Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Mon, 24 Jun 2024 15:46:22 -0700 Subject: [PATCH 11/17] install the necessary build tools in your builder-elixir stage. --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index f14eed1f..29fc81fa 100644 --- a/Dockerfile +++ b/Dockerfile @@ -3,8 +3,8 @@ #=========== FROM elixir:1.14.5-otp-26-alpine as builder-elixir -# Install git -RUN apk add --no-cache git +# Install git and build essentials +RUN apk add --no-cache git build-base RUN mkdir -p /mix WORKDIR /mix From d203476fcb27805b753e560ad33651632893b390 Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Mon, 24 Jun 2024 19:05:00 -0700 Subject: [PATCH 12/17] using 1.14-otp-25-alpine --- Dockerfile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Dockerfile b/Dockerfile index 29fc81fa..9cd48d2c 100644 --- a/Dockerfile +++ b/Dockerfile @@ -1,7 +1,7 @@ #=========== #(Elixir) Build Stage #=========== -FROM elixir:1.14.5-otp-26-alpine as builder-elixir +FROM elixir:1.14-otp-25-alpine as builder-elixir # Install git and build essentials RUN apk add --no-cache git build-base @@ -28,7 +28,7 @@ RUN mix local.hex --force && \ #================ #Deployment Stage #================ -FROM elixir:1.14.5-otp-26-alpine as deployer +FROM elixir:1.14-otp-25-alpine as deployer # RUN mkdir -p /app/test /app/prod RUN apk add --no-cache git bash curl netcat-openbsd && rm -rf /var/cache/apk/* From cb7013f77167f7c057117e2dbe68235bf8bdc27b Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Mon, 24 Jun 2024 23:22:41 -0700 Subject: [PATCH 13/17] netcat-openbsd compatibility and re-enabling arm64 builds --- .github/workflows/docker-ci-test.yaml | 4 ++-- docker-compose-ci.yml | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/.github/workflows/docker-ci-test.yaml b/.github/workflows/docker-ci-test.yaml index b58226e3..47f37c09 100644 --- a/.github/workflows/docker-ci-test.yaml +++ b/.github/workflows/docker-ci-test.yaml @@ -32,9 +32,9 @@ jobs: - name: Build & Publish the Docker image run: | - docker buildx create --name builder --use --platform=linux/amd64 && docker buildx build --platform=linux/amd64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push + # docker buildx create --name builder --use --platform=linux/amd64 && docker buildx build --platform=linux/amd64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push - # docker buildx create --name builder --use --platform=linux/amd64,linux/arm64 && docker buildx build --platform=linux/amd64,linux/arm64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push + docker buildx create --name builder --use --platform=linux/amd64,linux/arm64 && docker buildx build --platform=linux/amd64,linux/arm64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push - name: Create .env file run: | diff --git a/docker-compose-ci.yml b/docker-compose-ci.yml index c6beb59d..1c6641fa 100644 --- a/docker-compose-ci.yml +++ b/docker-compose-ci.yml @@ -101,7 +101,7 @@ services: echo "evm-server-address:" $EVM_SERVER_URL; echo "code-test-coverage:" $CODECOV_TOKEN; echo Waiting for proof-chain to be deployed...; - while ! nc -v -l -k -p 8008; + while ! nc -l -p 8008; do sleep 1; done; From 1424c5ce2bea5aa932e788d4e7a1fabb06fc8521 Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Mon, 24 Jun 2024 23:27:18 -0700 Subject: [PATCH 14/17] reverting to only amd64 build for now because arm64 builderror needs further debugging --- .github/workflows/docker-ci-test.yaml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/.github/workflows/docker-ci-test.yaml b/.github/workflows/docker-ci-test.yaml index 47f37c09..b58226e3 100644 --- a/.github/workflows/docker-ci-test.yaml +++ b/.github/workflows/docker-ci-test.yaml @@ -32,9 +32,9 @@ jobs: - name: Build & Publish the Docker image run: | - # docker buildx create --name builder --use --platform=linux/amd64 && docker buildx build --platform=linux/amd64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push + docker buildx create --name builder --use --platform=linux/amd64 && docker buildx build --platform=linux/amd64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push - docker buildx create --name builder --use --platform=linux/amd64,linux/arm64 && docker buildx build --platform=linux/amd64,linux/arm64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push + # docker buildx create --name builder --use --platform=linux/amd64,linux/arm64 && docker buildx build --platform=linux/amd64,linux/arm64 . -t us-docker.pkg.dev/covalent-project/network/refiner:latest --push - name: Create .env file run: | From 6c9dbce8d3a3e267909a19d1ddfa5aa8739cb84b Mon Sep 17 00:00:00 2001 From: Rodrigo Garcia Date: Tue, 25 Jun 2024 00:02:27 -0700 Subject: [PATCH 15/17] apparently need build dependencies on image to compile snappyer on client systems --- Dockerfile | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Dockerfile b/Dockerfile index 9cd48d2c..bcb78c20 100644 --- a/Dockerfile +++ b/Dockerfile @@ -31,7 +31,7 @@ RUN mix local.hex --force && \ FROM elixir:1.14-otp-25-alpine as deployer # RUN mkdir -p /app/test /app/prod -RUN apk add --no-cache git bash curl netcat-openbsd && rm -rf /var/cache/apk/* +RUN apk add --no-cache git bash curl netcat-openbsd build-base && rm -rf /var/cache/apk/* RUN mkdir -p /mix/_build /mix/config /mix/deps /mix/lib /mix/priv node/test /mix/test-data From 242f42995200481deaa5a3207a9cd99f1a77d4e4 Mon Sep 17 00:00:00 2001 From: Pranay Valson Date: Tue, 25 Jun 2024 12:12:27 -0700 Subject: [PATCH 16/17] add correct ipfs upload path for test files Signed-off-by: Pranay Valson --- docker-compose-ci.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docker-compose-ci.yml b/docker-compose-ci.yml index 1c6641fa..0e34b06a 100644 --- a/docker-compose-ci.yml +++ b/docker-compose-ci.yml @@ -107,8 +107,8 @@ services: done; echo Proof-chain contracts deployed!; echo Uploading test files to local .ipfs...; - curl -F "filedata=@/app/test-data/codec-0.37/encoded/1-20063050" http://ipfs-pinner:3001/upload; - curl -F "filedata=@/app/test-data/codec-0.37/encoded/1-20063085" http://ipfs-pinner:3001/upload; + curl -F "filedata=@/app/mix/test-data/codec-0.37/encoded/1-20063050" http://ipfs-pinner:3001/upload; + curl -F "filedata=@/app/mix/test-data/codec-0.37/encoded/1-20063085" http://ipfs-pinner:3001/upload; echo Test bsp files uploaded!; cd /mix; MIX_ENV=docker mix coveralls.json; From 1386bfb220c333f8b251e70676db85f5ea676c88 Mon Sep 17 00:00:00 2001 From: Pranay Valson Date: Tue, 25 Jun 2024 12:13:15 -0700 Subject: [PATCH 17/17] fresh pull dependencies with deps.get in compose Signed-off-by: Pranay Valson --- docker-compose-mbase.yml | 1 + docker-compose-mbeam.yml | 1 + 2 files changed, 2 insertions(+) diff --git a/docker-compose-mbase.yml b/docker-compose-mbase.yml index 4d2eaad6..aa342815 100644 --- a/docker-compose-mbase.yml +++ b/docker-compose-mbase.yml @@ -55,6 +55,7 @@ services: echo "evm-server:" $EVM_SERVER_URL; echo "ipfs-node:" $IPFS_PINNER_URL; cd /mix; + MIX_ENV=dev mix deps.get; MIX_ENV=dev mix release --overwrite; MIX_ENV=dev mix run --no-halt --eval 'Refiner.ProofChain.BlockSpecimenEventListener.start()';" environment: diff --git a/docker-compose-mbeam.yml b/docker-compose-mbeam.yml index 57306361..b80b7f3c 100644 --- a/docker-compose-mbeam.yml +++ b/docker-compose-mbeam.yml @@ -56,6 +56,7 @@ services: echo "evm-server:" $EVM_SERVER_URL; echo "ipfs-node:" $IPFS_PINNER_URL; cd /mix; + MIX_ENV=prod mix deps.get; MIX_ENV=prod mix release --overwrite; MIX_ENV=prod mix run --no-halt --eval 'Refiner.ProofChain.BlockSpecimenEventListener.start()';" environment: