mirror of
https://github.com/AmruthPillai/Reactive-Resume.git
synced 2025-11-18 18:51:32 +10:00
refactor(server): use proxy mechanisms to remove server_url config
This commit is contained in:
@ -5,6 +5,5 @@ export default registerAs('app', () => ({
|
||||
environment: process.env.NODE_ENV,
|
||||
secretKey: process.env.SECRET_KEY,
|
||||
port: parseInt(process.env.PORT, 10) || 3100,
|
||||
url: process.env.PUBLIC_APP_URL || 'http://localhost:3000',
|
||||
serverUrl: process.env.PUBLIC_SERVER_URL || 'http://localhost:3100',
|
||||
url: process.env.PUBLIC_URL || 'http://localhost:3000',
|
||||
}));
|
||||
|
||||
@ -16,8 +16,7 @@ const validationSchema = Joi.object({
|
||||
NODE_ENV: Joi.string().valid('development', 'production').default('development'),
|
||||
|
||||
// URLs
|
||||
PUBLIC_APP_URL: Joi.string().default('http://localhost:3000'),
|
||||
PUBLIC_SERVER_URL: Joi.string().default('http://localhost:3100'),
|
||||
PUBLIC_URL: Joi.string().default('http://localhost:3000'),
|
||||
|
||||
// Database
|
||||
POSTGRES_HOST: Joi.string().required(),
|
||||
@ -38,6 +37,9 @@ const validationSchema = Joi.object({
|
||||
|
||||
// SendGrid
|
||||
SENDGRID_API_KEY: Joi.string().allow(''),
|
||||
SENDGRID_FORGOT_PASSWORD_TEMPLATE_ID: Joi.string().allow(''),
|
||||
SENDGRID_FROM_NAME: Joi.string().allow(''),
|
||||
SENDGRID_FROM_EMAIL: Joi.string().allow(''),
|
||||
});
|
||||
|
||||
@Module({
|
||||
|
||||
Reference in New Issue
Block a user