Skip to content

docker-compose error #140

@Armando0z

Description

@Armando0z

I´ve encountered a problem trying to use the technical dependency with docker-compose (I´m able to use it when running freqtrade without docker). When trying to backtest or run a custom strategy I get this message:

2020-12-29 13:56:12,112 - freqtrade.resolvers.iresolver - WARNING - Could not import /freqtrade/user_data/strategies/trend_strategy.py due to 'No module named 'technical.vendor''

I carefully followed the steps in the guide:

https://www.freqtrade.io/en/latest/docker_quickstart/#additional-dependencies-with-docker-compose

and also tryed from scratch 2 times, but so far I have not succeed. After verifying I can run freqtrade on the default image (docker-compose comands working fine), these are the steps I took to add technical dependency:

  1. Create the file with the installation steps Dockerfile.technical with the following instructions (copied from: https://github.com/freqtrade/freqtrade/blob/develop/docker/Dockerfile.technical ) :
FROM freqtradeorg/freqtrade:develop

RUN apt-get update \
    && apt-get -y install git \
    && apt-get clean \
    && pip install git+https://github.com/freqtrade/technical
  1. Modify the docker-compose.yml file as the stated in the guide. after that, my file looks like this:
---
version: '3'
services:
  freqtrade:
    #image: freqtradeorg/freqtrade:stable
    image: freqtradeorg/freqtrade:custom
    # image: freqtradeorg/freqtrade:develop
    # Use plotting image
    #image: freqtradeorg/freqtrade:stable_plot
    # Build step - only needed when additional dependencies are needed
    build:
      context: .
      dockerfile: "./Dockerfile.technical"
    restart: unless-stopped
    container_name: freqtrade
    volumes:
      - "./user_data:/freqtrade/user_data"
    # Default command used when running `docker compose up`
    command: >
      trade
      --logfile /freqtrade/user_data/logs/freqtrade.log
      --db-url sqlite:////freqtrade/user_data/tradesv3.sqlite
      --config /freqtrade/user_data/config.json
      --strategy SampleStrategy
  1. Run command docker-compose build, to build the new image.

After this steps freqtrade rus correctly, but I'm still not able to backtest or run strategies that require the technical dependency (from docker-compose). Please tell me if I´m missing something in my installation steps, I haven´t been able to find the problem

Thanks in advance for your time and for helping me

Metadata

Metadata

Assignees

No one assigned

    Labels

    questionFurther information is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions