Add start script to launch domod and sprinklerd
This commit is contained in:
@@ -44,7 +44,7 @@ extern "C" {
|
||||
|
||||
/*--------------------------------- GLOBALS ---------------------------------*/
|
||||
|
||||
|
||||
#define kConfigPath "/usr/local/share/domo/"
|
||||
|
||||
/*! ----------------------------------------------------------------------------
|
||||
* @fn setupUbus
|
||||
@@ -87,23 +87,15 @@ static struct ubus_context *setupUbus (void)
|
||||
int main (void)
|
||||
{
|
||||
int theRet = 0;
|
||||
char *theWritePath;
|
||||
std::string theDevicePath, theTimerPath;
|
||||
struct ubus_context *theCtx = NULL;
|
||||
|
||||
theWritePath = getenv ("DOMO_WRITE_PATH");
|
||||
if (theWritePath == NULL) {
|
||||
|
||||
fprintf (stderr, "you should export DOMO_WRITE_PATH. with the Path of data.\n");
|
||||
return -1;
|
||||
}
|
||||
|
||||
// Create Configs Paths...
|
||||
|
||||
theDevicePath = theWritePath;
|
||||
theDevicePath = kConfigPath;
|
||||
theDevicePath += "/Devices.json";
|
||||
|
||||
theTimerPath = theWritePath;
|
||||
theTimerPath = kConfigPath;
|
||||
theTimerPath += "/Timers.json";
|
||||
|
||||
//printf ("DOMO PATH: %s\n", thePath.c_str());
|
||||
|
||||
Reference in New Issue
Block a user