mirror of
https://github.com/dadosfera/maestro.git
synced 2026-12-05 18:20:04 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
28ab892208 | ||
|
|
7af261d56c | ||
|
|
8fa924fdfb | ||
|
|
d1064c852b | ||
|
|
63338f5250 | ||
|
|
5e1fb41930 | ||
|
|
a807da2414 | ||
|
|
85f14fcf4b | ||
|
|
d95898ce55 | ||
|
|
33075b0f85 | ||
|
|
ca75f8f6e7 | ||
|
|
af12a39959 | ||
|
|
f77476b9ae | ||
|
|
fb0c659cd1 | ||
|
|
aea6815de7 | ||
|
|
0103f100f5 | ||
|
|
66b6be43b7 | ||
|
|
c029e286b5 |
@@ -26,9 +26,9 @@ jobs:
|
|||||||
- name: Extract Environment
|
- name: Extract Environment
|
||||||
run: |
|
run: |
|
||||||
if [ ${EVENT} == "workflow_dispatch" ]; then
|
if [ ${EVENT} == "workflow_dispatch" ]; then
|
||||||
echo "##[set-output name=environment;]$(echo ${DEPLOY_ENV})"
|
echo "environment=${DEPLOY_ENV}" >> $GITHUB_OUTPUT
|
||||||
elif [ ${GITHUB_REF} == "refs/heads/main" ]; then
|
elif [ ${GITHUB_REF} == "refs/heads/main" ]; then
|
||||||
echo "##[set-output name=environment;]$(echo "prd")"
|
echo "environment=prd" >> $GITHUB_OUTPUT
|
||||||
fi
|
fi
|
||||||
id: extract_environment
|
id: extract_environment
|
||||||
|
|
||||||
@@ -56,6 +56,19 @@ jobs:
|
|||||||
env:
|
env:
|
||||||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
||||||
|
|
||||||
|
deploy-info:
|
||||||
|
if: ${{ github.event_name == 'workflow_dispatch'}}
|
||||||
|
needs: [extract_environment, semantic_release]
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- name: Create summary
|
||||||
|
env:
|
||||||
|
EVENT: ${{ github.event_name }}
|
||||||
|
IMAGE_TAG: ${{ needs.semantic_release.outputs.new_release_version }}
|
||||||
|
ENV: ${{ needs.extract_environment.outputs.environment }}
|
||||||
|
run: echo "### Deploy da branch \`$GITHUB_REF_NAME\` no ambiente **$ENV** :rocket:" >> $GITHUB_STEP_SUMMARY
|
||||||
|
|
||||||
deploy:
|
deploy:
|
||||||
if: ${{ github.event_name == 'workflow_dispatch' || needs.semantic_release.outputs.new_release_published == 'true' }}
|
if: ${{ github.event_name == 'workflow_dispatch' || needs.semantic_release.outputs.new_release_published == 'true' }}
|
||||||
needs: [extract_environment, semantic_release]
|
needs: [extract_environment, semantic_release]
|
||||||
@@ -63,13 +76,6 @@ jobs:
|
|||||||
[self-hosted, '${{ needs.extract_environment.outputs.environment }}']
|
[self-hosted, '${{ needs.extract_environment.outputs.environment }}']
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
- name: Printing stats
|
|
||||||
env:
|
|
||||||
EVENT: ${{ github.event_name }}
|
|
||||||
IMAGE_TAG: ${{ needs.semantic_release.outputs.new_release_version }}
|
|
||||||
ENV: ${{ needs.extract_environment.outputs.environment }}
|
|
||||||
run: echo ${GITHUB_REF#refs/heads/}
|
|
||||||
|
|
||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
@@ -90,7 +96,7 @@ jobs:
|
|||||||
python3 -m pip install awsebcli --upgrade
|
python3 -m pip install awsebcli --upgrade
|
||||||
|
|
||||||
- name: Configure AWS Region
|
- name: Configure AWS Region
|
||||||
uses: aws-actions/configure-aws-credentials@v1
|
uses: aws-actions/configure-aws-credentials@v1-node16
|
||||||
id: aws
|
id: aws
|
||||||
with:
|
with:
|
||||||
aws-region: us-east-1
|
aws-region: us-east-1
|
||||||
@@ -113,10 +119,12 @@ jobs:
|
|||||||
ENV: ${{ needs.extract_environment.outputs.environment }}
|
ENV: ${{ needs.extract_environment.outputs.environment }}
|
||||||
IMAGE_TAG: ${{ needs.semantic_release.outputs.new_release_version }}
|
IMAGE_TAG: ${{ needs.semantic_release.outputs.new_release_version }}
|
||||||
ACCOUNT_ID: ${{ steps.aws.outputs.aws-account-id }}
|
ACCOUNT_ID: ${{ steps.aws.outputs.aws-account-id }}
|
||||||
|
NODE_EXPORTER_URL: ${{needs.extract_environment.outputs.environment == 'prd' && '611330257153.dkr.ecr.us-east-1.amazonaws.com\/monitoring\/node_exporter:latest' || '468720548566.dkr.ecr.us-east-1.amazonaws.com\/monitoring\/node_exporter:latest'}}
|
||||||
run: |
|
run: |
|
||||||
sed -i -e "s/\${ENV}/$ENV/g" docker-compose.yml
|
sed -i -e "s/\${ENV}/$ENV/g" docker-compose.yml
|
||||||
sed -i -e "s/\${IMAGE_TAG}/$IMAGE_TAG/g" docker-compose.yml
|
sed -i -e "s/\${IMAGE_TAG}/$IMAGE_TAG/g" docker-compose.yml
|
||||||
sed -i -e "s/\${ACCOUNT_ID}/$ACCOUNT_ID/g" docker-compose.yml
|
sed -i -e "s/\${ACCOUNT_ID}/$ACCOUNT_ID/g" docker-compose.yml
|
||||||
|
sed -i -e "s/\${NODE_EXPORTER_URL}/$NODE_EXPORTER_URL/g" docker-compose.yml
|
||||||
zip deploy.zip docker-compose.yml -r .ebextensions
|
zip deploy.zip docker-compose.yml -r .ebextensions
|
||||||
|
|
||||||
- name: Deploy AWS Beanstalk
|
- name: Deploy AWS Beanstalk
|
||||||
@@ -142,48 +150,36 @@ jobs:
|
|||||||
- name: Checkout
|
- name: Checkout
|
||||||
uses: actions/checkout@v2
|
uses: actions/checkout@v2
|
||||||
|
|
||||||
- name: Extract Docs PageId
|
- name: Extract Docs BlockId and PageId
|
||||||
env:
|
env:
|
||||||
ENV: ${{ needs.extract_environment.outputs.environment }}
|
ENV: ${{ needs.extract_environment.outputs.environment }}
|
||||||
|
DEV_DOCS_BLOCK_ID: ${{ secrets.DEV_DOCS_BLOCK_ID }}
|
||||||
DEV_DOCS_PAGE_ID: ${{ secrets.DEV_DOCS_PAGE_ID }}
|
DEV_DOCS_PAGE_ID: ${{ secrets.DEV_DOCS_PAGE_ID }}
|
||||||
|
STG_DOCS_BLOCK_ID: ${{ secrets.STG_DOCS_BLOCK_ID }}
|
||||||
STG_DOCS_PAGE_ID: ${{ secrets.STG_DOCS_PAGE_ID }}
|
STG_DOCS_PAGE_ID: ${{ secrets.STG_DOCS_PAGE_ID }}
|
||||||
|
PRD_DOCS_BLOCK_ID: ${{ secrets.PRD_DOCS_BLOCK_ID }}
|
||||||
PRD_DOCS_PAGE_ID: ${{ secrets.PRD_DOCS_PAGE_ID }}
|
PRD_DOCS_PAGE_ID: ${{ secrets.PRD_DOCS_PAGE_ID }}
|
||||||
shell: bash
|
shell: bash
|
||||||
run: |
|
run: |
|
||||||
if [ $ENV == "dev" ]; then
|
if [ $ENV == "dev" ]; then
|
||||||
echo "##[set-output name=result;]$(echo $DEV_DOCS_PAGE_ID)"
|
echo "block_id=$DEV_DOCS_BLOCK_ID" >> $GITHUB_OUTPUT
|
||||||
|
echo "page_id=$DEV_DOCS_PAGE_ID" >> $GITHUB_OUTPUT
|
||||||
elif [ $ENV == "stg" ]; then
|
elif [ $ENV == "stg" ]; then
|
||||||
echo "##[set-output name=result;]$(echo $STG_DOCS_PAGE_ID)"
|
echo "block_id=$STG_DOCS_BLOCK_ID" >> $GITHUB_OUTPUT
|
||||||
|
echo "page_id=$STG_DOCS_PAGE_ID" >> $GITHUB_OUTPUT
|
||||||
elif [ $ENV == "prd" ]; then
|
elif [ $ENV == "prd" ]; then
|
||||||
echo "##[set-output name=result;]$(echo $PRD_DOCS_PAGE_ID)"
|
echo "block_id=$PRD_DOCS_BLOCK_ID" >> $GITHUB_OUTPUT
|
||||||
|
echo "page_id=$PRD_DOCS_PAGE_ID" >> $GITHUB_OUTPUT
|
||||||
fi
|
fi
|
||||||
id: extract_docs_page_id
|
id: extract_docs_info
|
||||||
|
|
||||||
- name: Extract Docs BlockId
|
|
||||||
env:
|
|
||||||
ENV: ${{ needs.extract_environment.outputs.environment }}
|
|
||||||
DEV_DOCS_BLOCK_ID: ${{ secrets.DEV_DOCS_BLOCK_ID }}
|
|
||||||
STG_DOCS_BLOCK_ID: ${{ secrets.STG_DOCS_BLOCK_ID }}
|
|
||||||
PRD_DOCS_BLOCK_ID: ${{ secrets.PRD_DOCS_BLOCK_ID }}
|
|
||||||
shell: bash
|
|
||||||
run: |
|
|
||||||
if [ $ENV == "dev" ]; then
|
|
||||||
echo "##[set-output name=result;]$(echo $DEV_DOCS_BLOCK_ID)"
|
|
||||||
elif [ $ENV == "stg" ]; then
|
|
||||||
echo "##[set-output name=result;]$(echo $STG_DOCS_BLOCK_ID)"
|
|
||||||
elif [ $ENV == "prd" ]; then
|
|
||||||
echo "##[set-output name=result;]$(echo $PRD_DOCS_BLOCK_ID)"
|
|
||||||
fi
|
|
||||||
id: extract_docs_block_id
|
|
||||||
|
|
||||||
- name: Generate API docs
|
- name: Generate API docs
|
||||||
env:
|
env:
|
||||||
ENV: ${{ needs.extract_environment.outputs.environment }}
|
ENV: ${{ needs.extract_environment.outputs.environment }}
|
||||||
DOCS_URL: ${{ secrets.DOCS_URL }}
|
DOCS_URL: ${{ secrets.DOCS_URL }}
|
||||||
DOCS_API_TOKEN: ${{ secrets.DOCS_API_TOKEN }}
|
DOCS_API_TOKEN: ${{ secrets.DOCS_API_TOKEN }}
|
||||||
DOCS_PAGE_ID: ${{ steps.extract_docs_page_id.outputs.result }}
|
DOCS_PAGE_ID: ${{ steps.extract_docs_info.outputs.page_id }}
|
||||||
DOCS_BLOCK_ID: ${{ steps.extract_docs_block_id.outputs.result }}
|
DOCS_BLOCK_ID: ${{ steps.extract_docs_info.outputs.block_id }}
|
||||||
continue-on-error: true
|
|
||||||
run: |
|
run: |
|
||||||
SWAGGER=`cat swagger.txt`
|
SWAGGER=`cat swagger.txt`
|
||||||
curl --request POST \
|
curl --request POST \
|
||||||
@@ -198,9 +194,3 @@ jobs:
|
|||||||
}
|
}
|
||||||
EOF
|
EOF
|
||||||
)
|
)
|
||||||
- name: Cleanup Docker's Leftovers
|
|
||||||
if: always()
|
|
||||||
continue-on-error: true
|
|
||||||
run: |
|
|
||||||
docker system prune
|
|
||||||
docker rmi -f $(docker images -aq)
|
|
||||||
|
|||||||
+1
-1
@@ -10,7 +10,7 @@ services:
|
|||||||
- .env
|
- .env
|
||||||
|
|
||||||
node_exporter:
|
node_exporter:
|
||||||
image: prom/node-exporter:v1.3.1
|
image: ${NODE_EXPORTER_URL}
|
||||||
container_name: node_exporter
|
container_name: node_exporter
|
||||||
restart: always
|
restart: always
|
||||||
volumes:
|
volumes:
|
||||||
|
|||||||
@@ -290,15 +290,15 @@ export const PERMISSIONS_GROUPS = {
|
|||||||
claim: 'GET /catalog',
|
claim: 'GET /catalog',
|
||||||
usage: PermissionUsages.PUBLIC,
|
usage: PermissionUsages.PUBLIC,
|
||||||
name: {
|
name: {
|
||||||
'pt-br': 'Buscar data assets',
|
'pt-br': 'Acessar lista de Ativos e visualizar atributos',
|
||||||
'en-us': 'Search for data assets',
|
'en-us': 'Access Assets list and its attributes',
|
||||||
'es-es': 'Buscar data assets',
|
'es-es': 'Acceda a la lista de Activos y vea los atributos',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
CREATE: {
|
CREATE: {
|
||||||
seqid: 19,
|
seqid: 19,
|
||||||
claim: 'POST /catalog',
|
claim: 'POST /catalog',
|
||||||
usage: PermissionUsages.PUBLIC,
|
usage: PermissionUsages.INTERNAL,
|
||||||
name: {
|
name: {
|
||||||
'pt-br': 'Criar atributos no catálogo',
|
'pt-br': 'Criar atributos no catálogo',
|
||||||
'en-us': 'Create attributes',
|
'en-us': 'Create attributes',
|
||||||
@@ -307,32 +307,33 @@ export const PERMISSIONS_GROUPS = {
|
|||||||
},
|
},
|
||||||
UPDATE: {
|
UPDATE: {
|
||||||
seqid: 25,
|
seqid: 25,
|
||||||
claim: 'PUT /catalog',
|
claim: 'catalog:edit',
|
||||||
usage: PermissionUsages.INTERNAL,
|
usage: PermissionUsages.PUBLIC,
|
||||||
name: {
|
name: {
|
||||||
'pt-br': 'Editar atributos no catálogo',
|
'pt-br': 'Criar e editar atributos no catálogo',
|
||||||
'en-us': 'Edit attributes',
|
'en-us': 'Create and edit attributes on the catalog',
|
||||||
'es-es': 'Editar atributos',
|
'es-es': 'Crear y editar atributos en el catálogo',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
DELETE: {
|
DELETE: {
|
||||||
seqid: 1,
|
seqid: 1,
|
||||||
claim: 'DELETE /catalog',
|
claim: 'catalog:delete',
|
||||||
usage: PermissionUsages.INTERNAL,
|
usage: PermissionUsages.PUBLIC,
|
||||||
name: {
|
name: {
|
||||||
'pt-br': 'Excluir atributos no catálogo',
|
'pt-br': 'Excluir Ativos do catálogo',
|
||||||
'en-us': 'Remove attributes',
|
'en-us': 'Remove Assets from the catalog',
|
||||||
'es-es': 'Eliminar atributos',
|
'es-es': 'Eliminar Activos del catálogo',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
DATA_MANAGER: {
|
DATA_MANAGER: {
|
||||||
seqid: 42,
|
seqid: 42,
|
||||||
claim: 'catalog:data_manager',
|
claim: 'catalog:data_manager',
|
||||||
usage: PermissionUsages.PUBLIC,
|
usage: PermissionUsages.INTERNAL,
|
||||||
name: {
|
name: {
|
||||||
'pt-br': 'Vizualizar todos os recursos do catálogo.',
|
'pt-br':
|
||||||
'en-us': 'View all data assets.',
|
'Gerente do catálogo. Consegue vizualizar e editar todos os ativos.',
|
||||||
'es-es': 'Ver todos los activos de datos',
|
'en-us': 'Catalog manager. Able to view and edit all assets.',
|
||||||
|
'es-es': 'Gestor de catálogos. Puede ver y editar todos los activos.',
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -33,24 +33,30 @@ import {
|
|||||||
IUpdateDataRequest,
|
IUpdateDataRequest,
|
||||||
} from './dtos';
|
} from './dtos';
|
||||||
|
|
||||||
|
const catalogPermissions = PERMISSIONS_GROUPS.CATALOG.permissions;
|
||||||
@ApiTags('Catalog')
|
@ApiTags('Catalog')
|
||||||
@Controller('catalog')
|
@Controller('catalog')
|
||||||
@Authenticated()
|
@Authenticated()
|
||||||
@AuthenticateCondition((req, user) => {
|
@AuthenticateCondition((req, user: RequestUser) => {
|
||||||
if (req.path.includes('/manage_permissions/')) return true;
|
if (user.permissions.includes(catalogPermissions.DATA_MANAGER.seqid))
|
||||||
let action;
|
return true;
|
||||||
|
|
||||||
|
if (req.path.includes('/manage-permissions')) return true;
|
||||||
|
let action: keyof typeof catalogPermissions;
|
||||||
|
|
||||||
switch (req.method) {
|
switch (req.method) {
|
||||||
case 'POST':
|
case 'POST':
|
||||||
action = 'CREATE';
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'PUT':
|
case 'PUT':
|
||||||
action = 'UPDATE';
|
action = 'UPDATE';
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
case 'DELETE':
|
||||||
|
if (req.path.includes('/comment')) action = 'UPDATE';
|
||||||
|
else action = req.method;
|
||||||
|
break;
|
||||||
|
|
||||||
default:
|
default:
|
||||||
action = req.method;
|
action = req.method as 'GET';
|
||||||
}
|
}
|
||||||
|
|
||||||
return user.permissions.includes(
|
return user.permissions.includes(
|
||||||
@@ -372,7 +378,7 @@ export class CatalogController {
|
|||||||
@Body('docs') docs: string,
|
@Body('docs') docs: string,
|
||||||
) {
|
) {
|
||||||
const { user_id, customer_name } = user;
|
const { user_id, customer_name } = user;
|
||||||
const [data_asset_type, id] = data_asset_id.split('-');
|
const [, id] = data_asset_id.split('-');
|
||||||
|
|
||||||
this.logger.info(`/catalog - ON GET DATA DOCS ROUTE`, {
|
this.logger.info(`/catalog - ON GET DATA DOCS ROUTE`, {
|
||||||
user_id,
|
user_id,
|
||||||
|
|||||||
@@ -155,7 +155,7 @@ export class PipelinesController {
|
|||||||
.then((res) => {
|
.then((res) => {
|
||||||
//{pipeline:{tables: {tables: [], input_id: ''}}}
|
//{pipeline:{tables: {tables: [], input_id: ''}}}
|
||||||
let tables = JSON.parse(res.pipeline.config.tables);
|
let tables = JSON.parse(res.pipeline.config.tables);
|
||||||
if (tables?.tables) tables = tables?.tables;
|
if (tables?.tables) tables = tables.tables;
|
||||||
Object.assign(res.pipeline, {
|
Object.assign(res.pipeline, {
|
||||||
transformations: res.pipeline.transformations
|
transformations: res.pipeline.transformations
|
||||||
? JSON.parse(res.pipeline.transformations)
|
? JSON.parse(res.pipeline.transformations)
|
||||||
|
|||||||
@@ -11,34 +11,19 @@ import {
|
|||||||
import { ApiTags } from '@nestjs/swagger';
|
import { ApiTags } from '@nestjs/swagger';
|
||||||
import { TransformationsClientService } from './client.service';
|
import { TransformationsClientService } from './client.service';
|
||||||
import { IIdRequest } from './interfaces';
|
import { IIdRequest } from './interfaces';
|
||||||
import { AuthenticateCondition } from 'src/authentication/authentication.decorator';
|
import {
|
||||||
|
AuthenticateCondition,
|
||||||
|
Authenticated,
|
||||||
|
RequireSomePermission,
|
||||||
|
} from 'src/authentication/authentication.decorator';
|
||||||
import { PERMISSIONS_GROUPS } from '../../authentication/permissions.enum';
|
import { PERMISSIONS_GROUPS } from '../../authentication/permissions.enum';
|
||||||
import { TransformationsService } from './transformations.service';
|
import { TransformationsService } from './transformations.service';
|
||||||
import { DadosferaLogger } from '@dadosfera/dadosfera-logs';
|
import { DadosferaLogger } from '@dadosfera/dadosfera-logs';
|
||||||
import { RequestUser, User } from 'src/authentication/user.decorator';
|
import { RequestUser, User } from 'src/authentication/user.decorator';
|
||||||
|
const pipelinePermissions = PERMISSIONS_GROUPS.PIPELINE.permissions;
|
||||||
@ApiTags('Transformations')
|
@ApiTags('Transformations')
|
||||||
@Controller('transformations')
|
@Controller('transformations')
|
||||||
@AuthenticateCondition((req, user) => {
|
@Authenticated()
|
||||||
let action;
|
|
||||||
|
|
||||||
switch (req.method) {
|
|
||||||
case 'POST':
|
|
||||||
action = 'CREATE';
|
|
||||||
break;
|
|
||||||
|
|
||||||
case 'PUT':
|
|
||||||
action = 'UPDATE';
|
|
||||||
break;
|
|
||||||
|
|
||||||
default:
|
|
||||||
action = req.method;
|
|
||||||
}
|
|
||||||
|
|
||||||
return user.permissions.includes(
|
|
||||||
PERMISSIONS_GROUPS.TRANSFORMATIONS.permissions[action].seqid,
|
|
||||||
);
|
|
||||||
})
|
|
||||||
export class TransformationsController {
|
export class TransformationsController {
|
||||||
logger: DadosferaLogger;
|
logger: DadosferaLogger;
|
||||||
constructor(
|
constructor(
|
||||||
@@ -50,6 +35,7 @@ export class TransformationsController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Post()
|
@Post()
|
||||||
|
@RequireSomePermission(pipelinePermissions.CREATE, pipelinePermissions.UPDATE)
|
||||||
async create(@Body() createTransformationDto) {
|
async create(@Body() createTransformationDto) {
|
||||||
this.logger.info(`/transformation - ON CREATE ROUTE`, {
|
this.logger.info(`/transformation - ON CREATE ROUTE`, {
|
||||||
user: createTransformationDto.info.user_id,
|
user: createTransformationDto.info.user_id,
|
||||||
@@ -67,6 +53,7 @@ export class TransformationsController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Get()
|
@Get()
|
||||||
|
@RequireSomePermission(pipelinePermissions.GET)
|
||||||
async findAll(@Body() data: IIdRequest) {
|
async findAll(@Body() data: IIdRequest) {
|
||||||
this.logger.info(`/transformation - ON Find All ROUTE`, {
|
this.logger.info(`/transformation - ON Find All ROUTE`, {
|
||||||
user: data.info.user_id,
|
user: data.info.user_id,
|
||||||
@@ -82,6 +69,7 @@ export class TransformationsController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Get('/:id')
|
@Get('/:id')
|
||||||
|
@RequireSomePermission(pipelinePermissions.GET)
|
||||||
async findOne(@Body() data, @Param() params) {
|
async findOne(@Body() data, @Param() params) {
|
||||||
const { id } = params;
|
const { id } = params;
|
||||||
this.logger.info(`/transformation/${id} - ON Find One ROUTE`, {
|
this.logger.info(`/transformation/${id} - ON Find One ROUTE`, {
|
||||||
@@ -98,6 +86,7 @@ export class TransformationsController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Put(':id')
|
@Put(':id')
|
||||||
|
@RequireSomePermission(pipelinePermissions.CREATE, pipelinePermissions.UPDATE)
|
||||||
async update(
|
async update(
|
||||||
@User() user: RequestUser,
|
@User() user: RequestUser,
|
||||||
@Body() updateTransformationDto,
|
@Body() updateTransformationDto,
|
||||||
@@ -120,6 +109,7 @@ export class TransformationsController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Delete(':id')
|
@Delete(':id')
|
||||||
|
@RequireSomePermission(pipelinePermissions.CREATE, pipelinePermissions.UPDATE)
|
||||||
async delete(@Body() data, @Param() params) {
|
async delete(@Body() data, @Param() params) {
|
||||||
const { id } = params;
|
const { id } = params;
|
||||||
this.logger.info(`/transformation/${id} - ON DELETE ROUTE`, {
|
this.logger.info(`/transformation/${id} - ON DELETE ROUTE`, {
|
||||||
|
|||||||
+1
-1
File diff suppressed because one or more lines are too long
Reference in New Issue
Block a user