Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

A little helm with running this #8

Open
koushikpr opened this issue Sep 5, 2023 · 12 comments
Open

A little helm with running this #8

koushikpr opened this issue Sep 5, 2023 · 12 comments

Comments

@koushikpr
Copy link

Hey Im a beginner to the topic of helm and have to make this program run on either AWS EKS or even an EC2 Instance is fine. My doubts are how to run the chart and how much CPU and RAM utilization does this consume.

@patoarvizu
Copy link
Owner

Hello! Your question is kind of broad, so let me try to answer what I can.

Helm is a Kubernetes-specific framework, so it's not something you can run directly on an EC2 instance. You can of course run freqtrade itself directly on EC2 instances, but you wouldn't do that with Helm.

If you have access to a running Kubernetes cluster, you can follow the instructions on the Helm website on how to install a Helm chart. This repo isn't published to a proper Helm chart repository yet, so you'd have to clone it and install from your local copy. One tool that can help you try this out if you want to experiment on a local Kubernetes cluster is k3s. With k3s you can quickly spin up and tear down fully working Kubernetes clusters on your machine and iterate that way.

Lastly, I don't have any data in terms of resource utilization, maybe that's something that you can ask on the freqtrade repo.

I hope that helps!

@koushikpr
Copy link
Author

Hey I was able to make it work on AWS EC2 Instance the only issue that I am facing is the strategy. So basically how did u transfer the Sample-strategy to /freqtrade/userdata/strategies ? somehow there seems to be a chown command occuring that changes all files to Read-Only mode which I didnt find anywhere in the code.
Screenshot 2023-09-06 151452

@patoarvizu
Copy link
Owner

Are you running this on a Kubernetes server running on an EC2 instance? Or are you running freqtrade directly on the EC2 instance, without Kubernetes/Helm?

If it's the latter, that would be outside of the scope of this project and more of a question for the freqtrade repo (in case it's not clear, I'm not the maintainer of freqtrade, I just created this Helm chart to deploy it on Kubernetes).

Can you clarify how you're running this to see if it's something I can help you with?

@koushikpr
Copy link
Author

I am running Kubernetes server on EC2 Instance. The following error that I am facing is in the strategy section. The logs that u are able to see are for the command kubectl logs -n freqtrade <pod_name>
I have made changes in the configurations based on the latest changes in freqtrade docker image.
Config contains the following data. StrategyCreator is my custom class I have prepared and saved in charts/strategies/ folder. Somehow that is not been transferred to freqtrade/user-data/strategies for utlization
backtesting:
enabled: false
download_data: true
timerange:
timeframes: 5m
fee:
strategy_list: StrategyCreator
pvc_size: 1Gi
results:
enable_export: true
reader_enabled: true
pvc_size: 1Gi

bot:
enabled: true
strategy_name: StrategyCreator
pvc_size: 1Gi

ingress:
enabled: true

create_config_configmap: true
create_strategies_configmap: true

strategies: {}

@patoarvizu
Copy link
Owner

Mmhh I have a suspicion of what the issue might be. Can you tell me what version of Kubernetes you're running, and also, can you show me what the freqtrade-strategies configmap looks like? E.g. run kubectl get configmap freqtrade-strategies -o yaml.

@koushikpr
Copy link
Author

{{- if .Values.create_strategies_configmap }}
apiVersion: v1
kind: ConfigMap
metadata:
name: freqtrade-strategies
data:

{{- if .Values.strategies }}
{{ .Values.strategies | toYaml | indent 2 }}
{{- else }}
{{ (.Files.Glob "strategies/*").AsConfig | indent 2 }}
{{- end }}
{{- end }}

@koushikpr
Copy link
Author

image

@patoarvizu
Copy link
Owner

And what version of Kubernetes are you running?

@koushikpr
Copy link
Author

The latest one

@patoarvizu
Copy link
Owner

Hi, sorry I hadn't been able to come back to this. Have you made any progress?

@koushikpr
Copy link
Author

koushikpr commented Sep 17, 2023 via email

@patoarvizu
Copy link
Owner

Mmhh ok. When I created this repo I didn't really expect to have any significant adoption and it hasn't been updated in a while, and also when I created it Kubernetes was at 1.17 or something so a lot of things may have changed that are no longer compatible. I'm going to try to spend a little bit of time on this and see if I can reproduce it.

You mentioned you're on the latest version of Kubernetes, but can you specify which one explicitly?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants