overseer/Gruntfile.js
Gregory Ballantine 21b48b1f3c
All checks were successful
ci/woodpecker/push/woodpecker Pipeline was successful
Added debian packaging process
2022-11-04 09:07:31 -04:00

85 lines
1.9 KiB
JavaScript

module.exports = function(grunt) {
// Project configuration.
grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
deb_package: {
options: {
maintainer: 'Gregory Ballantine <gballantine@bitgoblin.tech>',
long_description: 'A simple web app to track inventory records.',
output: './dist/',
},
build: {
files: [
{
cwd: './',
src: 'index.js',
dest: '/opt/overseer'
},
{
cwd: './',
src: 'src/**/*',
dest: '/opt/overseer/'
},
{
cwd: './',
src: 'views/**/*',
dest: '/opt/overseer/'
},
{
cwd: './',
src: 'config/**/*',
dest: '/opt/overseer/'
},
{
cwd: './',
src: 'public/**/*',
dest: '/opt/overseer/'
},
{
cwd: './build/etc/',
src: 'production.json',
dest: '/etc/overseer/'
},
{
cwd: './build/etc/',
src: 'overseer.service',
dest: '/etc/systemd/system/'
},
{
cwd: './',
src: 'bin/**/*',
dest: '/opt/overseer/'
},
{
cwd: './',
src: 'node_modules/**/*',
dest: '/opt/overseer/'
},
{
cwd: './',
src: 'LICENSE',
dest: '/opt/overseer/',
},
],
links: {
'/usr/bin/overseer': '/opt/overseer/bin/start.sh'
},
scripts: {
postinst: {
src: './build/scripts/postinst.sh'
},
},
},
}
});
// Load the plugin that provides the "uglify" task.
grunt.loadNpmTasks('grunt-deb');
// Default task(s).
grunt.registerTask('package', ['deb_package']);
};