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

Overview

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.

Comments
  • Deployment security questions and docker hub login problem

    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!

    opened by lsiem 3
  • rnn

    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

    opened by brusand 2
  • How do I run this

    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

    opened by Cryptoseen 2
  • Docker permissions missing

    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

    opened by leader80 1
  • [Question] How far is the development? Can I contribute ?

    [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.

    opened by arunavo4 1
Owner
p-zombie
p-zombie
Automation for grabbing keys from a Linux host. Useful during red team exercises to quickly help assess what access to a Linux host can lead to.

keygrabber Automation for grabbing keys from a Linux host. This can be helpful during red team exercises when you gain access to a Linux host and want

Cedric Owens 14 Sep 27, 2022
Retrieve information from DBLP and update BibTex files automatically

Rebib TLDR: This script retrieves information from DBLP to update your BibTex files. python rebib.py --bibfile xxx.bib It first parses the bib entries

Shangtong Zhang 49 Jan 1, 2023
A script to automatically update bot status at GitHub as well as in Telegram channel.

Support BotStatus ~ A simple & short repository to show your bot's status in your GitHub README.md file as well as in you channel. ⚠️ This repo should

Jainam Oswal 55 Dec 13, 2022
A powerful application to automatically deploy GitHub Release.

A powerful application to automatically deploy GitHub Release.

Fentaniao 43 Sep 17, 2022
Baota-docker - Deploying baota panel via docker

baota-docker Deploying baota panel via docker. 通过docker一键部署宝塔面板。 一、前言 好像很多人对这个感兴

Mr. Cat 15 Dec 12, 2022
Automatically commits and pushes changes from a specified directory to remote repository

autopush a simple python program that checks a directory for updates and automatically commits any updated files (and optionally pushes them) installa

carreb 1 Jan 16, 2022
Freqtrade is a free and open source crypto trading bot written in Python.

Freqtrade is a free and open source crypto trading bot written in Python. It is designed to support all major exchanges and be controlled via Telegram. It contains backtesting, plotting and money management tools as well as strategy optimization by machine learning.

Kazune Takeda 5 Dec 30, 2021
Trading strategy for the Freqtrade crypto bot

NostalgiaForInfinity Trading strategy for the Freqtrade crypto bot Change strategy Add strategies to the user_data/strategies folder and also in the d

iterativ 1.5k Jan 1, 2023
trading strategy for freqtrade crypto bot it base on CDC-ActionZone

ft-action-zone trading strategy for freqtrade crypto bot it base on CDC-ActionZone Indicator by piriya33 Clone The Repository if you just clone this r

Miwtoo 17 Aug 13, 2022
Fully Dockerized cryptocurrencies Trading Bot, based on Freqtrade engine. Multi instances.

Cryptocurrencies Trading Bot - Freqtrade Manager This automated Trading Bot is based on the amazing Freqtrade one. It allows you to manage many Freqtr

Cédric Dugat 47 Dec 6, 2022
Freqtrade 3commas wrapper for python

Freqtrade 3commas wrapper The aim of this project is to provide an easy way to integrate freqtrade with 3commas. The main reason someone would want to

Alex Babescu 43 Dec 17, 2022
Discord Auto bumper made in python, just a simple auto bumper that I made.

Discord Auto bumper made in python, just a simple auto bumper that I made.

XPTGR 0 Dec 4, 2021
Auto like & auto followers facebook

Auto like & auto followers facebook

Fahmi Dev 23 Dec 8, 2022
Auto-Approved-Bot - Auto Approved Invaite Link Request Telegram Bot

?? ????????-??????????????-?????? ?? ℹ️ ?????????? ℹ️ When a join request invita

Muhammed 32 Dec 18, 2022
Auto-commiter - Auto commiter Github

auto committer Github Follow the steps below to use this repository: 1-install c

Arman Ebtekari 8 Nov 14, 2022
Auto-Rollnumber-sender - Auto Rollnumber sender with python

Auto-Rollnumber-sender The above code fits better on my system but it can vary s

Riya Tripathi 2 Feb 14, 2022
Improved file host. Change of interface and storage: 15 GB available.

File hosting v2 Improved file host. Change of interface and storage: 15 GB available. This app now uses the Google API to store, view, and delete file

Sarusman 1 Jan 18, 2022
Auto Join: A GitHub action script to automatically invite everyone to the organization who comment at the issue page.

Auto Invite To Org By Issue Comment A GitHub action script to automatically invite everyone to the organization who comment at the issue page. What is

Max Base 6 Jun 8, 2022