Skip to content

Commit

Permalink
Merge pull request #497 from bcgov-nr/feat/newServerList
Browse files Browse the repository at this point in the history
Server list script
  • Loading branch information
andrwils authored Oct 13, 2023
2 parents dc3efef + dcb8a72 commit 3e5da57
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 15 deletions.
13 changes: 0 additions & 13 deletions scripts/server-list-jenkinsfile-parameters.js

This file was deleted.

7 changes: 5 additions & 2 deletions scripts/server-list.js
Original file line number Diff line number Diff line change
@@ -1,13 +1,16 @@
// Prints a list of fluent bit servers, formatted for Jenkins fluent bit job parameters
const fs = require('fs');

const testFolder = __dirname + '/../config/server/';

fs.readdir(testFolder, (err, files) => {
let servers = '';
files
.filter(file => file !== 'localhost.json')
.filter(file => file.endsWith('.json'))
.map(file => file.slice(0, -5))
.forEach(file => {
console.log(file);
});
servers += `'${file}', `;
});
console.log(servers.slice(0, -2));
});

0 comments on commit 3e5da57

Please sign in to comment.