Skip to content

Commit

Permalink
migrate repo link/branch/tests/tag to refiner
Browse files Browse the repository at this point in the history
Signed-off-by: Pranay Valson <pranay.valson@gmail.com>
  • Loading branch information
noslav committed Jan 17, 2024
1 parent f06d425 commit 5f4a8c5
Show file tree
Hide file tree
Showing 66 changed files with 800 additions and 796 deletions.
2 changes: 1 addition & 1 deletion .credo.exs
Expand Up @@ -159,7 +159,7 @@
#
# Controversial and experimental checks (opt-in, just move the check to `:enabled`
# and be sure to use `mix credo --strict` to see low priority checks)
# Disabled for rudder repo
# Disabled for brp-refiner repo
{Credo.Check.Readability.FunctionNames, []},
{Credo.Check.Refactor.LongQuoteBlocks, []},
{Credo.Check.Design.TagTODO, [exit_status: 2]},
Expand Down
4 changes: 2 additions & 2 deletions .env_example
Expand Up @@ -3,12 +3,12 @@ WEB3_JWT=<WEB3-JWT>
# used to submit block result proofs
BLOCK_RESULT_OPERATOR_PRIVATE_KEY=<PRIVATE-KEY-OF-BLOCK-RESULT-OPERATOR>

# if running rudder and all supporting services using docker compose
# if running brp-refiner and all supporting services using docker compose
NODE_ETHEREUM_MAINNET=http://hardhat-node:8545/
IPFS_PINNER_URL=http://ipfs-pinner:3001
EVM_SERVER_URL=http://evm-server:3002

# if running rudder locally and all other services using docker compose
# if running brp-refiner locally and all other services using docker compose
NODE_ETHEREUM_MAINNET=http://127.0.0.1:8545/
IPFS_PINNER_URL=http://127.0.0.1:3001
EVM_SERVER_URL=http://127.0.0.1:3002
10 changes: 5 additions & 5 deletions .github/workflows/docker-ci-test.yaml
Expand Up @@ -31,7 +31,7 @@ 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/rudder: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: |
Expand All @@ -48,7 +48,7 @@ jobs:
echo "CI=${{ secrets.CI }}"
echo "CODECOV_TOKEN=${{ secrets.CODECOV_TOKEN }}"
echo "GITHUB_REF=${{ github.ref_name }}"
echo "CODECOV_SLUG=covalenthq/rudder"
echo "CODECOV_SLUG=covalenthq/refiner"
echo "GITHUB_SHA=$GITHUB_SHA"
echo "GITHUB_HEAD_REF=$GITHUB_HEAD_REF"
echo "GITHUB_ENV=$GITHUB_ENV"
Expand All @@ -62,10 +62,10 @@ jobs:
uses: xom9ikk/dotenv@v1.0.2

- name: Run containers
run: docker compose --env-file ".env" -f "docker-compose-ci.yml" up --remove-orphans --exit-code-from rudder
run: docker compose --env-file ".env" -f "docker-compose-ci.yml" up --remove-orphans --exit-code-from refiner

- name: Check running rudder
run: docker inspect rudder
- name: Check running refiner
run: docker inspect refiner

- name: Check running containers
run: docker ps
Expand Down
3 changes: 1 addition & 2 deletions .github/workflows/tag-release.yaml
Expand Up @@ -25,7 +25,7 @@ jobs:

- 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/rudder:stable -t us-docker.pkg.dev/covalent-project/network/rudder:"${{ env.TAG }}" --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:stable -t us-docker.pkg.dev/covalent-project/network/refiner:"${{ env.TAG }}" --push
- uses: "marvinpinto/action-automatic-releases@latest"
with:
Expand All @@ -35,4 +35,3 @@ jobs:
files: |
*.zip
*.tar.gz
4 changes: 2 additions & 2 deletions .gitignore
Expand Up @@ -20,15 +20,15 @@ erl_crash.dump
*.ez

# Ignore package tarball (built via "mix hex.build").
rudder-*.tar
brp-refiner-*.tar

# Temporary files, for example, from tests.
/tmp/

# Generated beam files
*.beam

# secrets for rudder app
# secrets for brp-refiner app
/config/*.secret.exs

#ElixirLS vscode extension
Expand Down
4 changes: 2 additions & 2 deletions Dockerfile
Expand Up @@ -43,13 +43,13 @@ COPY --from=builder-elixir /mix/lib /mix/lib
COPY --from=builder-elixir /mix/priv /mix/priv
COPY --from=builder-elixir /mix/mix.exs /mix/
COPY --from=builder-elixir /mix/mix.lock /mix/
# COPY --from=builder-elixir /mix/_build/dev/rel/rudder/ /mix/prod/
# COPY --from=builder-elixir /mix/_build/dev/rel/refiner/ /mix/prod/
COPY --from=builder-elixir /mix/test/ /mix/test
COPY --from=builder-elixir /mix/test-data/ /mix/test-data

# Used only for testing in compose
# CMD [ "mix", "test", "./test/block_specimen_decoder_test.exs", "./test/block_result_uploader_test.exs"]

CMD ["/mix/prod/bin/rudder", "start"]
CMD ["/mix/prod/bin/refiner", "start"]

EXPOSE 9568

0 comments on commit 5f4a8c5

Please sign in to comment.