aws-samples / aws-samples/eb-node-express-sample

`AWS_REGION` vs `REGION` environment variables

Abierto
#9 0 comentarios 0 reacciones 0 asignados Ver en GitHub
Lenguaje dominante
EJS
Estrellas
279
Forks
247
Métricas de merge de PR
Sin PR fusionados en 30 d

Descripción

In `.ebextensions/options.config` it is the `AWS_REGION` environment variable that is set, but in `app.js`, the code refers to the `REGION` environment variable to set `AWS.config.region`. Inspection of running system on launched EB environment shows that indeed `REGION` is actually not set.

Although the code still appears to work, I believe that the intention was to say `AWS.config.region = process.env.AWS_REGION` instead (otherwise `AWS_REGION` is not used anywhere). I'm a bit puzzled as to why the code still works when `AWS.config.region` is set to undefined (especially after one switches to use `nodejs-tutorial` for table name). How does the running process know to use the correct region in this case?

Guía de contribución

Abrir la guía de contribución

Línea de trabajo

Compare the AWS_REGION setting in .ebextensions/options.config with the REGION lookup in app.js, then inspect how the running Elastic Beanstalk process obtains its region. Verify the intended variable is used consistently and confirm the sample still starts and accesses its configured table in the expected region.

Escrito por el modelo de indexación a partir del texto del issue.

Evaluación

Stack tecnológico
aws, express, node.js
Área
backend, cloud
Tipo de issue
Error
Dificultad
2/5
Tiempo estimado
1-3 horas
Estado de actividad
Estancado
Claridad
Bastante claro
Aptitud para principiantes
35/100

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.