mirror of
https://github.com/NginxProxyManager/nginx-proxy-manager.git
synced 2025-04-29 10:32:28 +00:00
execute pihole DNS setter
This commit is contained in:
parent
7c5ae8e4fb
commit
7e7e077ce1
@ -6,6 +6,7 @@ const internalHost = require('./host');
|
||||
const internalNginx = require('./nginx');
|
||||
const internalAuditLog = require('./audit-log');
|
||||
const internalCertificate = require('./certificate');
|
||||
const piHole = require('./PiHoleDNSPlugin');
|
||||
|
||||
function omissions () {
|
||||
return ['is_deleted'];
|
||||
@ -64,9 +65,21 @@ const internalProxyHost = {
|
||||
});
|
||||
})
|
||||
.then(() => {
|
||||
|
||||
// Update PiHole
|
||||
for (let i = 0; i < row.domain_names.length; i++) {
|
||||
piHole.updatePihole(row.domain_names[i], row.forward_host);
|
||||
}
|
||||
|
||||
return row;
|
||||
});
|
||||
} else {
|
||||
|
||||
// Update PiHole
|
||||
for (let i = 0; i < row.domain_names.length; i++) {
|
||||
piHole.updatePihole(row.domain_names[i], row.forward_host);
|
||||
}
|
||||
|
||||
return row;
|
||||
}
|
||||
})
|
||||
|
Loading…
x
Reference in New Issue
Block a user