GithubHelp home page GithubHelp logo

p-zombie / freqtrade Goto Github PK

View Code? Open in Web Editor NEW
144.0 11.0 53.0 16.76 MB

Automatically deploy freqtrade to a remote Docker host and auto update strategies.

Dockerfile 0.01% Makefile 0.02% Shell 0.01% Python 20.32% Jupyter Notebook 79.65% Procfile 0.01%
freqtrade trader bitcoin cryptocurrency algotrading

freqtrade's Introduction

Freqtrade

Automatically deploy freqtrade to a remote Docker host and auto update strategies. I've been using it to automatically deploy to vultr, but you can use it with any provider of your choice, as long as you have a docker host running.

Requirements

  • First of all, you need a docker host to deploy the app, like https://www.vultr.com/docs/one-click-docker/ or any other provider you want.
  • Then, you need to have a docker hub account
  • Optionally, you may setup a telegram bot to receive deployment messages.

Once you have everything above, fork the repo, then you'll need to setup a few GitHub secrets to make it work:

Github Secrets

Workflow

Every-time you commit something to the repo, it will trigger a new docker build and push the image to docker hub (https://github.com/p-zombie/freqtrade/blob/master/.github/workflows/main.yml), and it will deploy production.yml to the host you setup using a docker deployment action.

PS; you may need to modify production.yml and change the image name to match your docker hub username, if not, it will use the image under my username.

I also added a scheduled job to run using GitHub actions: https://github.com/p-zombie/freqtrade/blob/master/.github/workflows/update_strat.yml it is set to run every minute but GitHub actually runs it about every 5 minutes; it pulls strategies, blacklists and pairlist files from https://github.com/iterativv/NostalgiaForInfinity and if the files changed, it will commit to the repo, which will trigger a new deploy and send a message in the telegram chat specified in the secrets.

That's about it, the hardest part is probably setting up the secrets for docker-deployment-action, but it should be pretty straightforward. I also added a docker prune file to prevent docker cache consuming all space in your docker host, copy to your docker host and run chmod +x docker-prune && mv docker-prune /etc/cron.daily and it should run every day.

if you plan to run it locally, it works exactly as the heroku repo, take a look at the makefile to check the available commands, or simply run make or make help to get a list of commands.

Feel free to open an Issue if you need help to setup this repo or if you find any issues.

freqtrade's People

Contributors

degiorgig avatar joaorafaelm 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  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

freqtrade's Issues

.env variable

what do you set in the .env file?
DOCKER_BUILDKIT=1

what else?

[Question] How far is the development? Can I contribute ?

Hi this project looks very interesting. I have worked with Rllib a lot before and with the Tensortrade Library. This repo does need a basic readme.
Also, if you need extra hands I would like to contribute if and when possible.

Deployment security questions and docker hub login problem

First of all, thank you for making this project available.
I have a few questions/problems regarding the deployment that I hope you can answer for me.

When running the build-deploy action, I always get at the "Dockerhub login" step that the username and password is incorrect, even though I entered the correct data.
I have also tried with a personal access token, but also without success

The folder user_data contains important information (API Keys etc...). Can I also provide this via the Github Secrets? Or how do I do that without everyone being able to see this data (you can't make forked repos private).

Thank you for helping me out!

How do I run this

Did I copy it to my own computer? The name of the file is freqtrade-master. So how do I run this? What codes should I write? Can you write step by step? I'm not a programmer, I'm using ubuntu 18.4. Thank you

Is a typo in documentation?

In https://www.freqtrade.io/en/2019.8/data-analysis/#change-directory-to-root I think there is a typo.

import os
from pathlib import Path

# Change directory
# Modify this cell to insure that the output shows the correct path.
# Define all paths relative to the project root shown in the cell output
project_root = "somedir/freqtrade"
i=0
try:
    os.chdirdir(project_root)
    assert Path('LICENSE').is_file()
except:
    while i<4 and (not Path('LICENSE').is_file()):
        os.chdir(Path(Path.cwd(), '../'))
        i+=1
    project_root = Path.cwd()
print(Path.cwd())

There's a typo in the line (os.chdirdir should be os.chdir). It's likely meant to change the directory using os.chdir().

rnn

hy did you test the Lstm policy ?
#from stable_baselines3.common.evaluation import MlpLstmPolicy

How to be profitable, i tried both freqtradegym and your version and both generate one buy , one sell and a big loss lollll. I even try the gym on the same coin on the same period and get big losss. How to improve it ?

thx
Bruno

Docker permissions missing

The image is missing the right permissions:

Creating freqtrade_freqtrade_run ... done
./load_env.sh: line 9: live.json: Permission denied
./load_env.sh: line 10: dry.json: Permission denied
./load_env.sh: line 11: test.json: Permission denied
./load_env.sh: line 12: hyper.json: Permission denied

I added:
RUN chown -R ftuser:ftuser /freqtrade
RUN chmod 755 /freqtrade

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.