1
0
mirror of https://github.com/Ylianst/MeshAgent synced 2025-12-26 05:03:15 +00:00

Fixed typo in freebsd service path

This commit is contained in:
Bryan Roe
2020-04-14 01:20:54 -07:00
parent 7a1da84490
commit 5fd96b36c3
2 changed files with 16 additions and 16 deletions

View File

@@ -1697,9 +1697,9 @@ function serviceManager()
if (!require('fs').existsSync('/usr/local/mesh_services')) { require('fs').mkdirSync('/usr/local/mesh_services'); }
if (!require('fs').existsSync('/usr/local/mesh_services/' + options.name)) { require('fs').mkdirSync('/usr/local/mesh_services/' + options.name); }
require('fs').copyFileSync(options.servicePath, '/usr/local/mesh_services/' + options.name + '/' + options.target);
var bm = require('fs').statSync(options.servicePath, '/usr/local/mesh_services/' + options.name + '/' + options.target).mode;
var bm = require('fs').statSync('/usr/local/mesh_services/' + options.name + '/' + options.target).mode;
bm |= (require('fs').CHMOD_MODES.S_IXUSR | require('fs').CHMOD_MODES.S_IXGRP);
require('fs').chmodSync(options.servicePath, '/usr/local/mesh_services/' + options.name + '/' + options.target, bm);
require('fs').chmodSync('/usr/local/mesh_services/' + options.name + '/' + options.target, bm);
var rc = require('fs').createWriteStream('/usr/local/etc/rc.d/' + options.name, { flags: 'wb' });
rc.write('#!/bin/sh\n');