Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
M
mailer
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
web-et-numerique
web-et-numerique-internet
data.grandlyon.com
web-portal
components
services
mailer
Commits
867dc50d
There was a problem fetching the pipeline summary.
Commit
867dc50d
authored
6 years ago
by
FORESTIER Fabien
Browse files
Options
Downloads
Patches
Plain Diff
Leave only NODE_ENV var env in gitlab-ci, add endpoint description
parent
743b7d25
Branches
Branches containing commit
Tags
Tags containing commit
No related merge requests found
Pipeline
#
Changes
3
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
.gitlab-ci.yml
+0
-12
0 additions, 12 deletions
.gitlab-ci.yml
docker-compose.yml
+3
-3
3 additions, 3 deletions
docker-compose.yml
src/email/email.controller.ts
+2
-1
2 additions, 1 deletion
src/email/email.controller.ts
with
5 additions
and
16 deletions
.gitlab-ci.yml
+
0
−
12
View file @
867dc50d
...
...
@@ -8,9 +8,6 @@ build_development:
-
master
script
:
-
export NODE_ENV=DEV
-
export SERVICE_EMAIL_PORT=3001
-
export RABBITMQ_STANDARD_PORT=5672
-
export RABBITMQ_INTERFACE_PORT=15672
-
docker-compose --project-name service-email-dev build
deploy_development
:
...
...
@@ -19,9 +16,6 @@ deploy_development:
-
master
script
:
-
export NODE_ENV=DEV
-
export SERVICE_EMAIL_PORT=3001
-
export RABBITMQ_STANDARD_PORT=5672
-
export RABBITMQ_INTERFACE_PORT=15672
-
docker-compose --project-name service-email-dev up -d
build_staging
:
...
...
@@ -30,9 +24,6 @@ build_staging:
-
staging
script
:
-
export NODE_ENV=REC
-
export SERVICE_EMAIL_PORT=3101
-
export RABBITMQ_STANDARD_PORT=5673
-
export RABBITMQ_INTERFACE_PORT=15673
-
sed -i 's/DEV_/REC_/g' docker-compose.yml
-
docker-compose --project-name service-email-rec build
...
...
@@ -42,8 +33,5 @@ deploy_staging:
-
staging
script
:
-
export NODE_ENV=REC
-
export SERVICE_EMAIL_PORT=3101
-
export RABBITMQ_STANDARD_PORT=5673
-
export RABBITMQ_INTERFACE_PORT=15673
-
sed -i 's/DEV_/REC_/g' docker-compose.yml
-
docker-compose --project-name service-email-rec up -d
This diff is collapsed.
Click to expand it.
docker-compose.yml
+
3
−
3
View file @
867dc50d
...
...
@@ -5,7 +5,7 @@ services:
build
:
.
container_name
:
service-email-${NODE_ENV}
ports
:
-
${SERVICE_EMAIL_PORT}:3000
-
${
DEV_
SERVICE_EMAIL_PORT}:3000
environment
:
-
ADMIN_EMAILS=${DEV_ADMIN_EMAILS}
-
RABBITMQ_USER=${DEV_RABBITMQ_USER}
...
...
@@ -15,8 +15,8 @@ services:
image
:
'
rabbitmq:3-management-alpine'
container_name
:
rabbitmq-${NODE_ENV}
ports
:
-
${RABBITMQ_STANDARD_PORT}:5672
# standar port for communication
-
${RABBITMQ_INTERFACE_PORT}:15672
# graphique interface
-
${
DEV_
RABBITMQ_STANDARD_PORT}:5672
# standar port for communication
-
${
DEV_
RABBITMQ_INTERFACE_PORT}:15672
# graphique interface
environment
:
-
RABBITMQ_DEFAULT_USER=${DEV_RABBITMQ_USER}
-
RABBITMQ_DEFAULT_PASS=${DEV_RABBITMQ_PASSWORD}
...
...
This diff is collapsed.
Click to expand it.
src/email/email.controller.ts
+
2
−
1
View file @
867dc50d
import
{
Controller
,
Post
,
Body
,
Res
}
from
'
@nestjs/common
'
;
import
{
ContactForm
}
from
'
./email
'
;
import
{
EmailService
}
from
'
./email.service
'
;
import
{
ApiBadRequestResponse
,
ApiOkResponse
,
ApiUseTags
}
from
'
@nestjs/swagger
'
;
import
{
ApiBadRequestResponse
,
ApiOkResponse
,
ApiUseTags
,
ApiOperation
}
from
'
@nestjs/swagger
'
;
@
ApiUseTags
(
'
email
'
)
@
Controller
(
'
email
'
)
...
...
@@ -12,6 +12,7 @@ export class EmailController {
)
{}
@
Post
(
'
contact
'
)
@
ApiOperation
({
title
:
'
Send email to admin (emails defined as var env of the project, see docker-compose.yml file).
'
})
@
ApiOkResponse
({
description
:
'
OK
'
})
@
ApiBadRequestResponse
({
description
:
'
Missing fields
'
})
create
(@
Body
()
contactForm
:
ContactForm
,
@
Res
()
res
)
{
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment