Merge pull request #4902 from docbobo/arm64-docs

Documentation for running arm64 builds
This commit is contained in:
Matthias 2021-05-14 05:48:08 +02:00 committed by GitHub
commit ff7bbec1bc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -67,29 +67,39 @@ Create a new directory and place the [docker-compose file](https://raw.githubuse
# image: freqtradeorg/freqtrade:develop_pi # image: freqtradeorg/freqtrade:develop_pi
``` ```
=== "ARM64 (Mac M1)" === "ARM 64 Systenms (Mac M1, Raspberry Pi 4, Jetson Nano)"
Make sure that your docker installation is running in native mode In case of a Mac M1, make sure that your docker installation is running in native mode
Arm64 images are not yet provided via Docker Hub and need to be build locally first.
Depending on the device, this may take a few minutes (Apple M1) or multiple hours (Raspberry Pi)
``` bash ``` bash
mkdir ft_userdata # Clone Freqtrade repository
cd ft_userdata/ git clone https://github.com/freqtrade/freqtrade.git
# Download the docker-compose file from the repository cd freqtrade
curl https://raw.githubusercontent.com/freqtrade/freqtrade/stable/docker-compose.yml -o docker-compose.yml # Optionally switch to the stable version
git checkout stable
# Edit the compose file, uncomment the "build" step and use "./docker/Dockerfile.aarch64" # Modify your docker-compose file to enable building and change the image name
# Also, change the image name to something of your liking # (see the Note Box below for necessary changes)
# Build the freqtrade image (this may take a while) # Build image
docker-compose build docker-compose build
# Create user directory structure # Create user directory structure
docker-compose run --rm freqtrade create-userdir --userdir user_data docker-compose run --rm freqtrade create-userdir --userdir user_data
# Create configuration - Requires answering interactive questions # Create configuration - Requires answering interactive questions
docker-compose run --rm freqtrade new-config --config user_data/config.json docker-compose run --rm freqtrade new-config --config user_data/config.json
``` ```
!!! Warning
You should not use the default image name - this can result in conflicting names between local and dockerhub and should therefore be avoided. !!! Note "Change your docker Image"
You have to change the docker image in the docker-compose file for your arm64 build to work properly.
``` yml
image: freqtradeorg/freqtrade:custom_arm64
build:
context: .
dockerfile: "./docker/Dockerfile.aarch64"
```
The above snippet creates a new directory called `ft_userdata`, downloads the latest compose file and pulls the freqtrade image. The above snippet creates a new directory called `ft_userdata`, downloads the latest compose file and pulls the freqtrade image.
The last 2 steps in the snippet create the directory with `user_data`, as well as (interactively) the default configuration based on your selections. The last 2 steps in the snippet create the directory with `user_data`, as well as (interactively) the default configuration based on your selections.