heirloom Posted July 26, 2020 Posted July 26, 2020 (edited) I just want to check a script I want to run to make sure it's ok. I want to cd to the flask folder and then run 'python3 dev.py build' so the script that I've made is:`cronjob1.sh` in `$HOME/cronjobs` folder with execute permissions. #!/bin/bash cd "$HOME/public_html/flask/" /usr/bin/python3.7 dev.py build And then the cronjob would be: $HOME/cronjobs/cronjob1.sh > $HOME/logs/`date +\%Y\%m\%d\%H\%M\%S`-cron.log 2>&1dev.py will install pip requirements and npm modules for the project that I've uploaded to work. You think it's ok like that? Edited July 27, 2020 by heirloom
Sn1F3rt Posted July 27, 2020 Posted July 27, 2020 You can't install Python dependencies (or modules) yourself. Just follow the links given in https://wiki.helionet.org/tutorials/python and take a look at the ones already installed. If you still need something, post back here with the requisites, an Admin will install them for you. Also, Flask functions a bit differently here than on your local PC or a Linux VM, largely because SSH access isn't provided on shared hosting. However, we've a complete tutorial for deploying Flask applications on HelioHost, that should sort your issues. https://wiki.helionet.org/tutorials/flask If you've any other queries, let us know.
Krydos Posted July 27, 2020 Posted July 27, 2020 If you decide you need ssh access to run commands like that you can get a vps https://www.heliohost.org/vps/
heirloom Posted July 27, 2020 Author Posted July 27, 2020 It did install the python packages but it failed to install the node modules. Is npm installed in Tommy? Here is the output:20200727124103-cron.log
heirloom Posted July 27, 2020 Author Posted July 27, 2020 (edited) Nevermind I see that I already imported the modules when I imported the code. Terminal access is not available on HelioHost, however, an admin can install the required Node.js modules for you. Make a separate post requesting the installation of the modules.That's not the case with Node.js. @filmegoo: You need to download the modules locally using NPM and then compress the node_modules folder to a zip file and upload it to your Node.js folder. After that, extract the file. Edited July 27, 2020 by heirloom
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now