backupy | simple backup program in python with an emphasis on data | Continuous Backup library
kandi X-RAY | backupy Summary
kandi X-RAY | backupy Summary
A simple backup program in python with an emphasis on data integrity and transparent behaviour
Support
Quality
Security
License
Reuse
Top functions reviewed by kandi - BETA
- Main function
- Get text from given text
- Abort run
- Read JSON file
- Append an entry to the log
- Run the simulation
- Start the main GUI
- Colorize a string
- Main function for the main application
- Runs the simulation
- Update the dictionary with the given file
- Get the version number
- Load the config
- Save config json
- Get string representation of given text
- Read a JSON file
- Run a backup
backupy Key Features
backupy Examples and Code Snippets
Community Discussions
Trending Discussions on backupy
QUESTION
I have written Python script which I want to execute everyday on my server (Cent OS). I need to execute some bash commands directly from my Python script. Everything works fine when I run the script directly from terminal, but bash commands are not executed when cron job executes the script, although the script does the rest of it is job (inserting to database etc).
My crontab looks as follows:
...ANSWER
Answered 2017-Dec-06 at 10:59This is a problem with cronjobs per se, but with the fact that your script uses relative path. Relative path are resolved against the "current working directory", which is not the same when you run the script manually from your home directory and when it's run by cron. The solution is, obviously, to only use absolute path in your script. You can harcode them in the python script itself if they are not supposed to change (which seems to be the case here) or use os.path.dirname(os.path.abspath(__file__))
in your python script to get the script's directory path.
Community Discussions, Code Snippets contain sources that include Stack Exchange Network
Vulnerabilities
No vulnerabilities reported
Install backupy
You can use backupy like any standard Python library. You will need to make sure that you have a development environment consisting of a Python distribution including header files, a compiler, pip, and git installed. Make sure that your pip, setuptools, and wheel are up to date. When using pip it is generally recommended to install packages in a virtual environment to avoid changes to the system.
Support
Reuse Trending Solutions
Find, review, and download reusable Libraries, Code Snippets, Cloud APIs from over 650 million Knowledge Items
Find more librariesStay Updated
Subscribe to our newsletter for trending solutions and developer bootcamps
Share this Page