-
Notifications
You must be signed in to change notification settings - Fork 1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
main.go
is making incorrect assumptions
#4
Comments
"uneet-dev" is just a local default. AWS config has numerous fallbacks and once deployed in the account it will just use what AWS credentials it finds under the role. We can't make it query the parameter store since it doesn't know which Parameter store to query. We can assume ${INSTALLATION_ID}-${STAGE} is setup in the local environment, but that's a big ask too, I prefer to keep it simple and hard code a sensible default. |
I agree with that statement What I disagree with is the assumption that
|
A different installation? Why did you fork everything then? https://github.com/Unee-T-INS/apienroll/blob/master/main.go#L48 When you want another environment like uneet-demo or uneet-prod, the idea is you deploy into the cloud with that AWS_PROFILE set and you run the code in that environment. But when you work locally, you work from the dev. your-aws-profile-for-this-envronment-of-this-unee-t-installation is not going to be in your |
Because there was a shit ton of hardcoded values that made it impossible to deploy the Unee-T INS codebase <--- we had edit each of these hardcoded values and I'm now trying to replace all these with variables so we can use the same repo for any Unee-T installation. |
Environment (DEV, DEMO, PROD) is NOT the same as Installation (Unee-T, Unee-T INS, etc...). |
what about |
Because there is no such AWS_PROFILE (and corresponding account) as uneet-local-dev ? |
I'm confused... This is the user's prerogative to setup his/her AWS profile on his local machine as he/she sees fit so why will this be an issue??? |
There is ${INSTALLATION_ID}-dev that should be in place already. Why can't that be used for local development? I am not sure what you are expecting a developer to do. Create another account just for local development? When I say local development, you generally (since these things are lambdas) are interfacing with AWS API endpoints. |
I see no issue with using ${INSTALLATION_ID}-dev for local development. |
Incorrect AWS profile:
In the file main.go
The code reads:
apienroll/main.go
Line 48 in 6cfcb24
This IS WRONG: we should NOT use
uneet-dev
here but the correct value based onINSTALLATION_ID
)STAGE
)The correct value for
uneet-dev
for a given environment is also declared in Travis Setting.It is then passed on as the variable
TRAVIS_PROFILE
.The text was updated successfully, but these errors were encountered: