Version 0.3.1 - Fix of Services
All checks were successful
Neutral/pipeline/head This commit looks good
All checks were successful
Neutral/pipeline/head This commit looks good
This commit is contained in:
parent
1685ec3712
commit
cf59827059
@ -119,7 +119,7 @@ module.exports.serverIO = function(server) {
|
||||
|
||||
socket.on("disconnect", () => {
|
||||
|
||||
plog.log("Déconnexion au panel par '" + user.username + "' avec le socket : " + socket.id)
|
||||
plog.log("Déconnexion du panel par '" + user.username + "' avec le socket : " + socket.id)
|
||||
})
|
||||
|
||||
function GetRequest(GQname, GQcallback) {
|
||||
|
@ -43,23 +43,23 @@ module.exports.stopService = function(service) {
|
||||
|
||||
const child_process = require('child_process');
|
||||
if(service == "https://subsonics.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 stop 'Subsonics'")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 stop 'Subsonics'")
|
||||
resolve("OK")
|
||||
} else if(service == "https://git.raphix.fr" ) {
|
||||
let req = child_process.exec("ssh raphix@omega.raphix.fr sudo -S systemctl stop gitea")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl stop gitea")
|
||||
resolve("OK")
|
||||
} else if(service == "https://jenkins.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@omega.raphix.fr sudo -S systemctl stop jenkins ")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl stop jenkins ")
|
||||
resolve("OK")
|
||||
|
||||
} else if(service == 'https://raphix.fr') {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 stop 'Website - Raphix'")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 stop 'Website - Raphix'")
|
||||
resolve("OK")
|
||||
} else if(service == "https://cv.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 stop 'CV - Raphael'")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 stop 'CV - Raphael'")
|
||||
resolve("OK")
|
||||
} else if(service == "http://omega.raphix.fr:2333") {
|
||||
let req = child_process.exec(" ssh raphix@omega.raphix.fr sudo -S systemctl stop lavalink ")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl stop lavalink ")
|
||||
resolve("OK")
|
||||
} else {
|
||||
resolve(false)
|
||||
@ -76,23 +76,24 @@ module.exports.startService = function(service) {
|
||||
|
||||
const child_process = require('child_process');
|
||||
if(service == "https://subsonics.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 start /home/gitlab-ci/subsonic.config.js")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 start /home/gitlab-ci/subsonic.config.js")
|
||||
resolve("OK")
|
||||
|
||||
} else if(service == "https://git.raphix.fr" ) {
|
||||
let req = child_process.exec("ssh raphix@omega.raphix.fr sudo -S systemctl start gitea")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl start gitea")
|
||||
resolve("OK")
|
||||
} else if(service == "https://jenkins.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@omega.raphix.fr sudo -S systemctl start jenkins ")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl start jenkins ")
|
||||
resolve("OK")
|
||||
|
||||
} else if(service == 'https://raphix.fr') {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 start /home/gitlab-ci/website.config.js")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 start /home/gitlab-ci/website.config.js")
|
||||
resolve("OK")
|
||||
} else if(service == "https://cv.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 start /home/gitlab-ci/cv.config.js")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 start /home/gitlab-ci/cv.config.js")
|
||||
resolve("OK")
|
||||
} else if(service == "http://omega.raphix.fr:2333") {
|
||||
let req = child_process.exec(" ssh raphix@omega.raphix.fr sudo -S systemctl start lavalink ")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl start lavalink ")
|
||||
resolve("OK")
|
||||
} else {
|
||||
resolve(false)
|
||||
@ -109,23 +110,23 @@ module.exports.restartService = function(service) {
|
||||
|
||||
const child_process = require('child_process');
|
||||
if(service == "https://subsonics.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 restart 'Subsonics'")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 restart 'Subsonics'")
|
||||
resolve("OK")
|
||||
} else if(service == "https://git.raphix.fr" ) {
|
||||
let req = child_process.exec("ssh raphix@omega.raphix.fr sudo -S systemctl restart gitea")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl restart gitea")
|
||||
resolve("OK")
|
||||
} else if(service == "https://jenkins.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@omega.raphix.fr sudo -S systemctl restart jenkins ")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl restart jenkins ")
|
||||
resolve("OK")
|
||||
|
||||
} else if(service == 'https://raphix.fr') {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 restart 'Website - Raphix'")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 restart 'Website - Raphix'")
|
||||
resolve("OK")
|
||||
} else if(service == "https://cv.raphix.fr") {
|
||||
let req = child_process.exec("ssh raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 restart 'CV - Raphael'")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@alpha.raphix.fr sudo -S -u gitlab-ci pm2 restart 'CV - Raphael'")
|
||||
resolve("OK")
|
||||
} else if(service == "http://omega.raphix.fr:2333") {
|
||||
let req = child_process.exec(" ssh raphix@omega.raphix.fr sudo -S systemctl restart lavalink ")
|
||||
let req = child_process.exec("ssh -o StrictHostKeyChecking=no raphix@omega.raphix.fr sudo -S systemctl restart lavalink ")
|
||||
resolve("OK")
|
||||
} else {
|
||||
resolve(false)
|
||||
|
@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "neutral",
|
||||
"version": "0.2.2",
|
||||
"version": "0.3.1",
|
||||
"description": "Panel d'administration de Raphix",
|
||||
"main": "index.js",
|
||||
"scripts": {
|
||||
|
Loading…
Reference in New Issue
Block a user