Closed ethhhhh closed 3 years ago
Hi,
You probably run the script as a non root user. Since Flask binds it on port 80/443 root privileges are required.
Either you chose to run it as root; forward port 80 to something like 8080; or you run it behind Apache / Nginx. Easiest solution is the first one, but not recommended.
Hey so I have my public ip connected to the weebhook url in trading view. I have a webhook setup in my discord server. I have appended the discord we hook into config.py is this correct?
On Thu, Feb 4, 2021 at 11:56 AM Visionz notifications@github.com wrote:
Hi,
You probably run the script as a non root user. Since Flask binds it on port 80/443 root privileges are required.
Either you chose to run it as root; forward port 80 to something like 8080; or you run it behind Apache / Nginx. Easiest solution is the first one, but not recommended.
β You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773531455, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASXKERF7YTRFSPRF5NQBY3LS5LUUBANCNFSM4XDKWP4A .
It sounds correct however running it from your local machine can be a little struggle since you most likely have to open ports too.
Thanks for the reply. When I run python main.py i get:
Serving on http://0.0.0.0:80
When itβs running alerts are not sent to discord. Does this mean I need to change my port. I can send the config.py file if needed.
Thanks for your help.
On Thu, Feb 4, 2021 at 12:40 PM Visionz notifications@github.com wrote:
It sounds correct however running it from your local machine can be a little struggle since you most likely have to open ports too.
β You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773557129, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASXKERAAJT3HAQYZ746Q67DS5LZ4FANCNFSM4XDKWP4A .
Serving on 0.0.0.0 is just your local IP. You'd have to use your external IP in TV's Alerts message. You can find that out by typing ifconfig
in your terminal, if your on Linux.
Hey, I have copied and pasted my config.py file. I'm using university wifi, could this be causing the issues? What is the desired output after entering python -main.py. Thanks for the help. I'm new to programming.
"789842349670960670/BFeBBrCt-w2Z9RJ2wlH6TWUjM5bJuC29aJaJ5OQv9sE6zCKY_AlOxxFwRURkgEl852s3","msg":
"Long #{{ticker}} at {{close}}
"}
sec_key = "$$" # Can be anything. Has to match with "key" in your TradingView alert message
send_telegram_alerts = False
tg_token = '' # Bot token. Get it from @Botfather
channel = 0 # Channel ID (ex. -1001487568087)
send_discord_alerts = True
discord_webhook = ' https://discord.com/api/webhooks/806929289547218984/9cltAyX2DCw08ElIIZRyhIqg-48C7yeeqQpU2Fkef99Lyk5UKZNTVtzkz_01Q3kE0L1n '
https://support.discordapp.com/hc/de/articles/228383668-Webhooks-verwenden)
{"key": "$$", "disord": "not sure what to place here ", "msg": "Ticker
{{close}}
"}send_twitter_alerts = False
tw_ckey = ''
tw_csecret = ''
tw_atoken = ''
tw_asecret = ''
send_email_alerts = True
email_sender = '' # Your email address
email_receivers = ['', ''] # Receivers, can be multiple
email_subject = 'Trade Alert!'
email_port = 465 # SMTP SSL Port (ex. 465)
email_host = '' # SMTP host (ex. smtp.gmail.com)
email_user = '' # SMTP Login credentials
email_password = '' # SMTP Login credentials
On Thu, Feb 4, 2021 at 1:21 PM Visionz notifications@github.com wrote:
Serving on 0.0.0.0 is just your local IP. You'd have to use your external IP in TV's Alerts message. You can find that out by typing ifconfig in your terminal, if your on Linux.
β You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773580054, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASXKERDV7G7W7GLLKQBT5Y3S5L6T5ANCNFSM4XDKWP4A .
A desired output would be what you said, serving at 0.0.0.0:80
.
Config looks fine. As long as you use the same key ($$
) in your TV Alerts. However even if not the terminal will print the rejection. Hosting it from a home sever is always tricky and iffy. Would not advice to do it.
Alternatively I'm offering a service which also supports the attachment of Chart Screenshots. Maybe your interested. TV-Alerts.com.
Hey Im not sure were to find the key in my tradingview alerts
On Thu, Feb 4, 2021 at 2:59 PM Visionz notifications@github.com wrote:
A desired output would be what you said, serving at 0.0.0.0:80.
Config looks fine. As long as you use the same key ($$) in your TV Alerts. However even if not the terminal will print the rejection. Hosting it from a home sever is always tricky and iffy. Would not advice to do it.
Alternatively I'm offering a service which also supports the attachment of Chart Screenshots. Maybe your interested. TV-Alerts.com https://tv-alerts.com.
β You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773631087, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASXKERF6EJGGVFWE66ERMQ3S5MKFNANCNFSM4XDKWP4A .
Has been explained in the installation guide point 6.
what are my other options either then hosting on a home server?
On Thu, Feb 4, 2021 at 3:07 PM Visionz notifications@github.com wrote:
Has been explained in the installation guide https://github.com/vsnz/TradingView-Webhook-Bot#installation point 6.
β You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773634739, or unsubscribe https://github.com/notifications/unsubscribe-auth/ASXKERCVUT6UVGUWGK46CATS5MLCBANCNFSM4XDKWP4A .
Hosting it on a VPS as mentioned in the Readme. Will cost you ~$4/mo depending on the service you choose.
Yo man wich vps is that,sorry
On Thu, Feb 4, 2021, 5:16 PM Visionz notifications@github.com wrote:
Hosting it on a VPS as mentioned in the Readme. Will cost you ~$4/mo depending on the service you choose.
β You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773639269, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMIKZSNIMY3QWU7DJC76SN3S5MMFBANCNFSM4XDKWP4A .
Sure thank you!
On Fri, Feb 5, 2021, 12:09 AM Visionz notifications@github.com wrote:
I am using Hetzner https://vsnz.net/hetzner. (Use my ref link and get 20β¬ free credits)
β You are receiving this because you commented. Reply to this email directly, view it on GitHub https://github.com/vsnz/TradingView-Webhook-Bot/issues/33#issuecomment-773792120, or unsubscribe https://github.com/notifications/unsubscribe-auth/AMIKZSOPEAI6WKCCDYTUQDLS5N4RPANCNFSM4XDKWP4A .
Hi when i attempt to connect my ip to the webhook url i get the error of "the host is not allowed".