Coder Social home page Coder Social logo

exchanges_dashboard's Introduction

Exchanges dashboard

This repository is meant to provide an easy-to-run (local) web-UI that provides insight into your account(s) activities on exchanges. It uses a custom script to retrieve data from one or more exchanges (via websocket and/or REST), which is then inserted into a database (sqlite by default). A metabase container is then launched with a default configuration to display this information.

Screenshots

Overview of the dashboard: Futures

When a value is entered in the DCA field (top left), the DCA quantity and the DCA price (x% above the current price) will be displayed in the additional fields in the table. DCA

Metabase configuration:

Credentials

  • First name: First
  • Last name: Last
  • Email: [email protected]
  • Password: ExchangesDashboard1!
  • Department: Department of Awesome

Database

  • Database type: SQLite
  • Name: Exchanges
  • Filename: /data/exchanges_db.sqlite

Starting the dashboard

  • Clone this repo:
    • git clone https://github.com/hoeckxer/exchanges_dashboard.git
  • Copy the config.example.json to config.json
    • cp config.example.json config.json
  • Enter the api-key & secret
    • nano config.json
  • Start the dashboard
    • Run docker-compose up -d
  • Go to http://localhost:3000
WARNING: If you change the config.json file, make sure you rebuild the container using docker-compose up -d --build
INFO: If you get a message about $PWD being unknown, replace $PWD the docker-compose.yaml file with the full path

Stopping the dashboard

  • Run docker-compose stop

Multiple dashboard

  • If you want to deploy a second dashboard instance on the same machine, please clone the repo and update the config.json and docker-compose.yaml files.
  • In the docker-compose.yaml you'll have to modify container names, exposed port and network interface. An example is provided in docker-compose.yaml.example-second-dashboard

Running on Raspberry Pi

  • The metabase image is built for x86. Therefore, on Raspberry Pi, a new image needs to be created using an ARM based image.
  • I created a Dockerfile that creates this kind of image, which supposed to be identical to the metabase one.
  • To use the new image, replace line 13 of docker-compose.yml from image: metabase/metabase:latest to build: metabase_rpi

exchanges_dashboard's People

Contributors

amit-sides avatar doftorul avatar hawkeye-bot avatar kvn3 avatar msei99 avatar neuhausj avatar rayures avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

exchanges_dashboard's Issues

Trades

Scraper doesnt save Trades to DB

Cannot create container for service metabase-app: create .: volume name is too short

WARNING: The PWD variable is not set. Defaulting to a blank string.
exchanges_dashboard_scraper_1 is up-to-date
Creating metabase ... error

ERROR: for metabase Cannot create container for service metabase-app: create .: volume name is too short, names should be at least two alphanumeric characters

ERROR: for metabase-app Cannot create container for service metabase-app: create .: volume name is too short, names should be at least two alphanumeric characters
ERROR: Encountered errors while bringing up the project.

New installation from git.

No scraping in the logs, empty database

I have configured config. json with 2 accounts ( exchange binance and bybit_derivates ), build and started the container but nothing is going on regarding the scraping when checking the container logs ( though no errors ) and DB is empty. What should I look for ? What to check ?

I see my config.json in /metabase-data.
I noticed that time is incorrect inside container and files /etc/localtime and /etc/timezone are missing there. I tried to recreate those and after restart the time is fine but still nothing going on, empty dashboard/empty exchages_db database.

Webserver is not coming up on MacOS

Is there anything special I need to do to get it working under MacOS?
I am starting It but the https://localhost:3000 is not opening anything ...?

`AirvonThomasexchanges_dashboard % docker-compose build
[+] Building 54.6s (16/16) FINISHED
=> [internal] load build definition from Dockerfile 0.0s
=> => transferring dockerfile: 32B 0.0s
=> [internal] load .dockerignore 0.0s
=> => transferring context: 2B 0.0s
=> resolve image config for docker.io/docker/dockerfile:1 0.6s
=> CACHED docker-image://docker.io/docker/dockerfile:1@sha256:42399d4635eddd7a9b8a24be879d2f9a930d0ed040a61324cfdf59ef1357b3b2 0.0s
=> [internal] load build definition from Dockerfile 0.0s
=> [internal] load .dockerignore 0.0s
=> [internal] load metadata for docker.io/library/python:3.8.7-alpine 0.5s
=> CACHED [1/7] FROM docker.io/library/python:3.8.7-alpine@sha256:4b710739b8088ba0e14751845bba81609c05628547bb941968a7928cb736 0.0s
=> [internal] load build context 0.0s
=> => transferring context: 867B 0.0s
=> [2/7] COPY scraper_root /scraper/scraper_root 0.0s
=> [3/7] RUN apk add --no-cache gcc musl-dev linux-headers libffi-dev g++ 4.2s
=> [4/7] RUN pip install --upgrade pip 2.3s
=> [5/7] RUN pip install -r /scraper/scraper_root/requirements.txt 45.8s
=> [6/7] COPY config.json /scraper 0.1s
=> [7/7] WORKDIR /scraper 0.0s
=> exporting to image 0.8s
=> => exporting layers 0.8s
=> => writing image sha256:536fafb9e63c3c7ee7f5be752a7608d36769cdc2430e5b4a78c3fa553cbfbbe5 0.0s
=> => naming to docker.io/library/exchanges_dashboard_scraper 0.0s

Use 'docker scan' to run Snyk tests against images to find vulnerabilities and learn how to fix them`

No data in order question

Hello hoeckxer!

Nothing in order table. I added symbols in config.json, but sql can not get data from binance future. Could you help me to fix it?

Thanks

Template

Hello, is it possible to have a template in dark mode?

Start On RPI4

Hello. How can I run this dashboard on RPI4?
I managed to achieve some success, however, I was not able to launch it fully.
For a successful installation, I edited the dockfile and docker-compose files.
In docker-compose i replaced "metabase/metabase:latest" => "magm3333/metabase-armv7"
As I understand it, this is the version of the metabase for arm architecture
In Dockfile i replaced "FROM python:3.8.7-alpine" => "FROM python:3.8.6-alpine" If this is not done, you get an error during installation, many people encounter this, and the reason is not completely clear.
image
Also I added
"ENV CRYPTOGRAPHY_DONT_BUILD_RUST=1"
"RUN apk add cargo openssl-dev"
Failure to do so results in a Rust cryptography error. I found the solution somewhere on stackoverflow.
After these changes and manipulations, the installation proceeds without errors, the web interface starts. However, the dashboard is empty. Perhaps there is an incompatibility in the metabase.db files, since I changed it in the docker-compose.
Or maybe he doesn't see those files. There is one step left until the full launch, but I don’t know what else to do)
Thanks for the help!

Is this a bug?

Hello,
After 8 p.m. I'm still stuck on this line.

=> [3/7] RUN apk add --no-cache gcc musl-dev linux-headers libffi-dev g++

Is it normal?

Timezone

Timezone doesn't seem to be set to local. How do I alter it? I have changed it in the admin settings after the server is started, but it doesn't seem right.

Only daily balance is updated after power loss

Hi, I have power loss on my machine before, and when my vm is restarted it's only update daily balance, not update order, position, or anything, here is the screenshot after docker rebuild

image

can you help me? if possible i don't want to start from scratch

Fresh install after the pull didnt work.

Something in recent update its not right.
I recreated docker and all, but something its missing, some charts not working.

Screenshot 2023-01-15 at 22 29 43

In positions:
[SQLITE_ERROR] SQL error or missing database (no such column: account)

ADG:
[SQLITE_ERROR] SQL error or missing database (no such column: INCOME.account)

Monthly summary:
[SQLITE_ERROR] SQL error or missing database (no such column: db.account)

Nice work BTW, thanks for sharing.

Error with docker compose on windows

PS C:\Users\Dario\exchanges_dashboard> docker-compose up -d
time="2022-01-03T14:39:18+01:00" level=warning msg="The \"PWD\" variable is not set. Defaulting to a blank string."
time="2022-01-03T14:39:18+01:00" level=warning msg="The \"PWD\" variable is not set. Defaulting to a blank string."
time="2022-01-03T14:39:18+01:00" level=warning msg="The \"PWD\" variable is not set. Defaulting to a blank string."
1 error(s) decoding:

* error decoding 'Volumes[1]': invalid spec: :/metabase-data: empty section between colons

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.