update refs

This commit is contained in:
poma 2020-12-16 00:15:51 +03:00
parent adaaa7d844
commit cf430641cc
No known key found for this signature in database
GPG Key ID: BA20CB01FE165657
5 changed files with 83 additions and 83 deletions

View File

@ -12,74 +12,75 @@ jobs:
steps: steps:
- name: Checkout - name: Checkout
uses: actions/checkout@v2 uses: actions/checkout@v2
# - uses: actions/setup-node@v1 - uses: actions/setup-node@v1
# with: with:
# node-version: 12 node-version: 12
# - run: npm ci - run: yarn install
# - run: npm run eslint - run: yarn test
# - name: Telegram Failure Notification - run: yarn lint
# uses: appleboy/telegram-action@0.0.7 - name: Telegram Failure Notification
# if: failure() uses: appleboy/telegram-action@0.0.7
# with: if: failure()
# message: ❗ Build failed for [${{ github.repository }}](https://github.com/${{ github.repository }}/actions) because of ${{ github.actor }} with:
# format: markdown message: ❗ Build failed for [${{ github.repository }}](https://github.com/${{ github.repository }}/actions) because of ${{ github.actor }}
# to: ${{ secrets.TELEGRAM_CHAT_ID }} format: markdown
# token: ${{ secrets.TELEGRAM_BOT_TOKEN }} to: ${{ secrets.TELEGRAM_CHAT_ID }}
# token: ${{ secrets.TELEGRAM_BOT_TOKEN }}
# publish:
# runs-on: ubuntu-latest publish:
# needs: build runs-on: ubuntu-latest
# if: startsWith(github.ref, 'refs/tags') needs: build
# steps: if: startsWith(github.ref, 'refs/tags')
# - name: Checkout steps:
# uses: actions/checkout@v2 - name: Checkout
# uses: actions/checkout@v2
# - name: Set vars
# id: vars - name: Set vars
# run: | id: vars
# echo "::set-output name=version::$(echo ${GITHUB_REF#refs/tags/v})" run: |
# echo "::set-output name=repo_name::$(echo ${GITHUB_REPOSITORY#*/})" echo "::set-output name=version::$(echo ${GITHUB_REF#refs/tags/v})"
# echo "::set-output name=repo_name::$(echo ${GITHUB_REPOSITORY#*/})"
# - name: Check package.json version vs tag
# run: | - name: Check package.json version vs tag
# [ ${{ steps.vars.outputs.version }} = $(grep '"version":' package.json | grep -o "[0-9.]*") ] || (echo "Git tag doesn't match version in package.json" && false) run: |
# [ ${{ steps.vars.outputs.version }} = $(grep '"version":' package.json | grep -o "[0-9.]*") ] || (echo "Git tag doesn't match version in package.json" && false)
# - name: Build and push Docker image
# uses: docker/build-push-action@v1.1.0 - name: Build and push Docker image
# with: uses: docker/build-push-action@v1.1.0
# dockerfile: Dockerfile with:
# repository: tornadocash/relayer dockerfile: Dockerfile
# tag_with_ref: true repository: tornadocash/relayer
# tags: latest tag_with_ref: true
# username: ${{ secrets.DOCKER_USERNAME }} tags: latest
# password: ${{ secrets.DOCKER_TOKEN }} username: ${{ secrets.DOCKER_USERNAME }}
# password: ${{ secrets.DOCKER_TOKEN }}
# - name: Telegram Message Notify
# uses: appleboy/telegram-action@0.0.7 - name: Telegram Message Notify
# with: uses: appleboy/telegram-action@0.0.7
# to: ${{ secrets.TELEGRAM_CHAT_ID }} with:
# token: ${{ secrets.TELEGRAM_BOT_TOKEN }} to: ${{ secrets.TELEGRAM_CHAT_ID }}
# message: 🚀 Published a [${{ steps.vars.outputs.repo_name }}](https://github.com/${{ github.repository }}) version ${{ steps.vars.outputs.version }} to docker hub token: ${{ secrets.TELEGRAM_BOT_TOKEN }}
# debug: true message: 🚀 Published a [${{ steps.vars.outputs.repo_name }}](https://github.com/${{ github.repository }}) version ${{ steps.vars.outputs.version }} to docker hub
# format: markdown debug: true
# format: markdown
# - name: Telegram Notification
# uses: appleboy/telegram-action@0.0.7 - name: Telegram Notification
# with: uses: appleboy/telegram-action@0.0.7
# to: ${{ secrets.TELEGRAM_RELAYER_CHAT_ID }} with:
# token: ${{ secrets.TELEGRAM_BOT_TOKEN }} to: ${{ secrets.TELEGRAM_RELAYER_CHAT_ID }}
# message: | token: ${{ secrets.TELEGRAM_BOT_TOKEN }}
# 🚀 Published a new version of the relayer node service to docker hub: `tornadocash/relayer:v${{ steps.vars.outputs.version }}` and `tornadocash/relayer:latest`. message: |
# 🚀 Published a new version of the relayer node service to docker hub: `tornadocash/relayer:v${{ steps.vars.outputs.version }}` and `tornadocash/relayer:latest`.
# ❗Please update your nodes ❗️
# debug: true Please update your nodes ❗️
# format: markdown debug: true
# format: markdown
# - name: Telegram Failure Notification
# uses: appleboy/telegram-action@0.0.7 - name: Telegram Failure Notification
# if: failure() uses: appleboy/telegram-action@0.0.7
# with: if: failure()
# message: ❗ Failed to publish [${{ steps.vars.outputs.repo_name }}](https://github.com/${{ github.repository }}/actions) because of ${{ env.GITHUB_ACTOR }} with:
# format: markdown message: ❗ Failed to publish [${{ steps.vars.outputs.repo_name }}](https://github.com/${{ github.repository }}/actions) because of ${{ env.GITHUB_ACTOR }}
# to: ${{ secrets.TELEGRAM_CHAT_ID }} format: markdown
# token: ${{ secrets.TELEGRAM_BOT_TOKEN }} to: ${{ secrets.TELEGRAM_CHAT_ID }}
token: ${{ secrets.TELEGRAM_BOT_TOKEN }}

View File

@ -1,13 +1,8 @@
# syntax=docker/dockerfile:experimental
# export DOCKER_BUILDKIT=1
FROM node:12 FROM node:12
WORKDIR /app WORKDIR /app
RUN mkdir -p -m 0600 ~/.ssh && ssh-keyscan github.com >> ~/.ssh/known_hosts && echo "Host github.com\n\tUser git" > ~/.ssh/config
COPY package.json yarn.lock ./ COPY package.json yarn.lock ./
RUN --mount=type=ssh yarn && yarn cache clean --force RUN yarn && yarn cache clean --force
COPY . . COPY . .
EXPOSE 8000 EXPOSE 8000

View File

@ -7,6 +7,7 @@ docker-compose.yml contains a stack that will automatically provision SSL certif
1. Download [docker-compose.yml](/docker-compose.yml) and [env.example](/env.example) 1. Download [docker-compose.yml](/docker-compose.yml) and [env.example](/env.example)
2. `mv .env.example .env` 2. `mv .env.example .env`
3. Setup environment variables 3. Setup environment variables
- set `NET_ID` (1 for mainnet, 5 for Goerli) - set `NET_ID` (1 for mainnet, 5 for Goerli)
- set `HTTP_RPC_URL` rpc url for your ethereum node - set `HTTP_RPC_URL` rpc url for your ethereum node
- set `WS_RPC_URL` websocket url - set `WS_RPC_URL` websocket url
@ -22,6 +23,7 @@ docker-compose.yml contains a stack that will automatically provision SSL certif
- update `MAX_GAS_PRICE` if needed - maximum value of gwei value for relayer's transaction - update `MAX_GAS_PRICE` if needed - maximum value of gwei value for relayer's transaction
If you want to use more than 1 eth address for relaying transactions, please add as many `workers` as you want. For example, you can comment out `worker2` in docker-compose.yml file, but please use a different `PRIVATE_KEY` for each worker. If you want to use more than 1 eth address for relaying transactions, please add as many `workers` as you want. For example, you can comment out `worker2` in docker-compose.yml file, but please use a different `PRIVATE_KEY` for each worker.
4. Run `docker-compose up -d` 4. Run `docker-compose up -d`
## Run locally ## Run locally

View File

@ -28,8 +28,8 @@
"gas-price-oracle": "^0.2.2", "gas-price-oracle": "^0.2.2",
"ioredis": "^4.14.1", "ioredis": "^4.14.1",
"node-fetch": "^2.6.0", "node-fetch": "^2.6.0",
"torn-token": "git+ssh://git@github.com/tornadocash/torn-token.git#04c4df88d470ca7503ef5d97882c56cba4f3647d", "torn-token": "^1.0.0",
"tornado-cash-anonymity-mining": "git+ssh://git@github.com/tornadocash/tornado-anonymity-mining.git#b13228c20126f212ebbcc5a8493ce2105210739e", "tornado-cash-anonymity-mining": "^1.0.0",
"tx-manager": "^0.2.9", "tx-manager": "^0.2.9",
"uuid": "^8.3.0", "uuid": "^8.3.0",
"web3": "^1.3.0", "web3": "^1.3.0",

View File

@ -4322,9 +4322,10 @@ toidentifier@1.0.0:
resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553" resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.0.tgz#7e1be3470f1e77948bc43d94a3c8f4d7752ba553"
integrity sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw== integrity sha512-yaOH/Pk/VEhBWWTlhI+qXxDFXlejDGcQipMlyxda9nthulaxLZUNcUqFxokp0vcYnvteJln5FNQDRrxj3YcbVw==
"torn-token@git+ssh://git@github.com/tornadocash/torn-token.git#04c4df88d470ca7503ef5d97882c56cba4f3647d": torn-token@^1.0.0:
version "1.0.0" version "1.0.0"
resolved "git+ssh://git@github.com/tornadocash/torn-token.git#04c4df88d470ca7503ef5d97882c56cba4f3647d" resolved "https://registry.yarnpkg.com/torn-token/-/torn-token-1.0.0.tgz#73e47025646c3e07ab733afbf7aa53b6ab9cad55"
integrity sha512-BRzt3fy4211jCb64cWyOb5/NMGt9M9EV2ZFnGQYMubKrVkszoYm97Nex+EBa0mvV2KfXzCmJ6tehoDgOFAPGug==
dependencies: dependencies:
"@openzeppelin/contracts" "^3.1.0" "@openzeppelin/contracts" "^3.1.0"
dotenv "^8.2.0" dotenv "^8.2.0"
@ -4332,9 +4333,10 @@ toidentifier@1.0.0:
ethereumjs-util "^7.0.3" ethereumjs-util "^7.0.3"
web3 "^1.2.11" web3 "^1.2.11"
"tornado-cash-anonymity-mining@git+ssh://git@github.com/tornadocash/tornado-anonymity-mining.git#b13228c20126f212ebbcc5a8493ce2105210739e": tornado-cash-anonymity-mining@^1.0.0:
version "1.0.0" version "1.0.0"
resolved "git+ssh://git@github.com/tornadocash/tornado-anonymity-mining.git#b13228c20126f212ebbcc5a8493ce2105210739e" resolved "https://registry.yarnpkg.com/tornado-cash-anonymity-mining/-/tornado-cash-anonymity-mining-1.0.0.tgz#1e9d68e60097de6fa3ff6989558ca313030daf5c"
integrity sha512-OVwj1N6g6NqRrkj0QkSrrGSY7Mlmb0BMeJUh7BeI9doOY/tS1OMky/G/xHdcVRLTbJN34MHIepTSF6/xRM33eg==
dependencies: dependencies:
circomlib "git+https://github.com/tornadocash/circomlib.git#3b492f9801573eebcfe1b6c584afe8a3beecf2b4" circomlib "git+https://github.com/tornadocash/circomlib.git#3b492f9801573eebcfe1b6c584afe8a3beecf2b4"
decimal.js "^10.2.0" decimal.js "^10.2.0"