Cross MA Strategy with Docker Swarm

Welcome to the Cross MA (Moving Average Cross) strategy repository. This strategy is based on the principle of moving average crossovers, where buy/sell signals are generated when a short-term moving average crosses above/below a long-term moving average. The strategy is implemented using the Freqtrade platform and deployed using Docker Swarm.

Overview

The Cross MA strategy leverages the crossing of short-term and long-term moving averages to make trading decisions. With the Freqtrade platform's capabilities, we've been able to automate and optimize this strategy efficiently.

To ensure that our trading signals are communicated promptly, we've integrated a service named "Plotter" that sends these signals directly to Telegram.

Deployment with Docker Swarm

We use Docker Swarm to deploy and manage our services, ensuring high availability and scalability. The entire setup is orchestrated using a docker-compose.yml file.

Deploying with docker stack deploy

To deploy the Cross MA strategy and other associated services, follow these steps:

  1. Navigate to the directory containing your docker-compose.yml file.
  2. Run the following command:
docker stack deploy -c docker-compose.yml cross_ma_stack

This will deploy all the services defined in your docker-compose.yml file under a stack named cross_ma_stack.

Networking in Swarm

The services communicate with each other using Docker's internal networking. This allows, for example, our Freqtrade service to seamlessly integrate with the Plotter service for instant notifications.

Conclusion

With Docker Swarm, Freqtrade, and our supplementary service, Plotter, we've created a robust and scalable infrastructure for the Cross MA strategy. This ensures timely delivery of trading signals for efficient decision-making.


As before, please adjust paths, names, or any specific details according to your actual setup and requirements.