update docker image, compose file

This commit is contained in:
smart_ex 2022-07-26 18:09:26 +10:00
parent 09429eb276
commit 74dbd94de8
3 changed files with 18 additions and 17 deletions

@ -6,7 +6,7 @@ WORKDIR /usr/app
COPY yarn.lock .
COPY package.json .
RUN apk update && apk add --no-cache g++ make python3 git openssh && rm -rf /var/cache/apk/*
RUN apk update && apk add --no-cache g++ make python3 && rm -rf /var/cache/apk/*
RUN yarn install --network-concurrency 2
COPY . ./
@ -17,7 +17,7 @@ ENV NODE_ENV=production
WORKDIR /app
RUN apk update && apk add --no-cache g++ make python3 git openssh && rm -rf /var/cache/apk/*
RUN apk update && apk add --no-cache g++ make python3 && rm -rf /var/cache/apk/*
COPY --from=dev /usr/app/build /app
COPY --from=dev /usr/app/package.json /app/

@ -1,4 +1,4 @@
version: '2'
version: '3'
services:
server:
@ -9,6 +9,7 @@ services:
environment:
REDIS_URL: redis://redis/0
nginx_proxy_read_timeout: 600
VIRTUAL_PORT: ${APP_PORT}
depends_on: [redis]
worker1:
@ -68,11 +69,12 @@ services:
redis:
image: redis
restart: always
command: [redis-server, '/usr/local/etc/redis/redis.conf', --appendonly, 'yes']
environment:
- REDIS_APPENDONLY=yes
- REDIS_APPENDFSYNC=always
ports:
- '6379:6379'
- '127.0.0.1:6379:6379' # do not expose redis port
volumes:
- ./redis.conf:/usr/local/etc/redis/redis.conf
- redis:/data
nginx:
@ -95,9 +97,11 @@ services:
container_name: dockergen
restart: always
command: -notify-sighup nginx -watch /etc/docker-gen/templates/nginx.tmpl /etc/nginx/conf.d/default.conf
volumes_from:
- nginx
volumes:
- conf:/etc/nginx/conf.d
- vhost:/etc/nginx/vhost.d
- html:/usr/share/nginx/html
- certs:/etc/nginx/certs
- /var/run/docker.sock:/var/run/docker.sock:ro
letsencrypt:
@ -106,9 +110,11 @@ services:
restart: always
environment:
NGINX_DOCKER_GEN_CONTAINER: dockergen
volumes_from:
- nginx
- dockergen
volumes:
- conf:/etc/nginx/conf.d
- vhost:/etc/nginx/vhost.d
- html:/usr/share/nginx/html
- certs:/etc/nginx/certs
volumes:
conf:

@ -14,12 +14,7 @@ import {
tornToken,
} from '../config';
import { ChainIds, Token } from '../types';
import {
getProvider,
getTornadoProxyContract,
getTornadoProxyLightContract,
getTornTokenContract
} from '../modules/contracts';
import { getProvider, getTornadoProxyContract, getTornadoProxyLightContract, getTornTokenContract } from '../modules/contracts';
import { resolve } from '../modules';
import { ERC20Abi, ProxyLightABI, TornadoProxyABI } from '../contracts';
import { availableIds, netIds, NetInstances } from 'torn-token';