Skip to content
Snippets Groups Projects
Commit 6d2380a0 authored by matthiak00's avatar matthiak00
Browse files

fixed pipeline trigger and prettier

parent 541c5e0b
No related branches found
No related tags found
No related merge requests found
......@@ -14,11 +14,6 @@ install_dependencies:
stage: build
script:
- npm ci --cache .npm --prefer-offline
only:
changes:
- package-lock.json
variables:
- $MANUAL_INSTALL_TRIGGER
artifacts:
paths:
- node_modules/
......
......@@ -5,13 +5,13 @@ import { AddressInfo } from 'node:net'
import logger from './logger'
import { Server } from 'node:http'
import swaggerJsDoc = require('swagger-jsdoc');
import * as swaggerUi from 'swagger-ui-express';
import swaggerJsDoc = require('swagger-jsdoc')
import * as swaggerUi from 'swagger-ui-express'
const swaggerOptions = {
swaggerDefinition : {
swaggerDefinition: {
info: {
version: "1.0.0",
version: '1.0.0',
title: 'Uni-Sport-O-Mat API',
description: 'API Information',
servers: ['http://localhost:5000']
......@@ -21,18 +21,15 @@ const swaggerOptions = {
apis: ['**/*.ts']
}
// Our Express APP config
const app = express()
app.set('port', 5000)
app.use(express.urlencoded({ extended: false })) // Parses urlencoded bodies
app.use(express.json()) // Send JSON responses
const swaggerDocs = swaggerJsDoc(swaggerOptions);
app.use('/api-docs', swaggerUi.serve, swaggerUi.setup(swaggerDocs));
const swaggerDocs = swaggerJsDoc(swaggerOptions)
app.use('/api-docs', swaggerUi.serve, swaggerUi.setup(swaggerDocs))
// logs all requests on http level => could later be saved into "access.log" for example
app.use((req, res, next) => {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment