Clean up build process

This commit is contained in:
2021-08-04 23:18:55 -04:00
parent 2e300a9964
commit 3c5e3324a7
9 changed files with 31 additions and 13 deletions

View File

@@ -1,5 +1,9 @@
FROM node
RUN mkdir /app
RUN cd /app
WORKDIR /app
COPY package.json package.json
COPY package-lock.json package-lock.json
@@ -7,6 +11,7 @@ RUN npm install
COPY . .
RUN npm run build
RUN npm run ng build api --configuration production
RUN npm run ng build client
CMD [ "npm", "run", "prod" ]

View File

@@ -1,6 +1,6 @@
import { Controller, Get } from '@nestjs/common';
import { Message } from '@vidgrab2/api-interfaces';
import { Message } from '@vidgrab/api-interfaces';
import { AppService } from './app.service';

View File

@@ -1,5 +1,5 @@
import { Injectable } from '@nestjs/common';
import { Message } from '@vidgrab2/api-interfaces';
import { Message } from '@vidgrab/api-interfaces';
@Injectable()
export class AppService {

View File

@@ -9,7 +9,7 @@ import {
import { pick } from 'lodash';
import { Server, Socket } from 'socket.io';
import { JobEvent } from '@vidgrab2/api-interfaces';
import { JobEvent } from '@vidgrab/api-interfaces';
@WebSocketGateway()
export class JobGateway implements OnGatewayConnection, OnGatewayDisconnect {

View File

@@ -18,7 +18,7 @@ import { ConfigService } from '@nestjs/config';
import { Queue } from 'bull';
import { pick, trimEnd } from 'lodash';
import { QueueDto, UploadDto } from '@vidgrab2/api-interfaces';
import { QueueDto, UploadDto } from '@vidgrab/api-interfaces';
import { YtdlService } from '../ytdl/ytdl.service';
@Controller()

View File

@@ -13,7 +13,7 @@ import { EventEmitter2 } from '@nestjs/event-emitter';
import { Job } from 'bull';
import { throttle } from 'lodash';
import * as split from 'split2';
import { QueueDto } from '@vidgrab2/api-interfaces';
import { QueueDto } from '@vidgrab/api-interfaces';
import { raw } from 'youtube-dl-exec';
@Processor('vidgrab')

View File

@@ -1,5 +1,5 @@
{
"npmScope": "vidgrab2",
"npmScope": "vidgrab",
"affected": {
"defaultBase": "master"
},
@@ -14,7 +14,12 @@
"default": {
"runner": "@nrwl/workspace/tasks-runners/default",
"options": {
"cacheableOperations": ["build", "lint", "test", "e2e"]
"cacheableOperations": [
"build",
"lint",
"test",
"e2e"
]
}
}
},

View File

@@ -1,5 +1,5 @@
{
"name": "vidgrab2",
"name": "vidgrab",
"version": "0.0.0",
"license": "MIT",
"scripts": {
@@ -10,7 +10,7 @@
"start:fe:prod": "sleep 10 && ng serve client --prod",
"start:be": "ng serve api",
"start:be:prod": "node dist/apps/api/main.js",
"build": "ng build api --prod && ng build client",
"build": "ng build api --configuration production && ng build client",
"test": "ng test",
"lint": "nx workspace-lint && ng lint",
"dev": "concurrently -p=\"{name}\" -n=\"Next,NestJS\" -c=\"green,blue\" \"npm run start:fe\" \"npm run start:be\"",

View File

@@ -10,13 +10,21 @@
"importHelpers": true,
"target": "es2015",
"module": "esnext",
"lib": ["es2017", "dom"],
"lib": [
"es2017",
"dom"
],
"skipLibCheck": true,
"skipDefaultLibCheck": true,
"baseUrl": ".",
"paths": {
"@vidgrab2/api-interfaces": ["libs/api-interfaces/src/index.ts"]
"@vidgrab/api-interfaces": [
"libs/api-interfaces/src/index.ts"
]
}
},
"exclude": ["node_modules", "tmp"]
"exclude": [
"node_modules",
"tmp"
]
}