-
Notifications
You must be signed in to change notification settings - Fork 269
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix nomulus tool when the environment is localhost (#2365)
Also only caches/resets the original TM when in unit tests (TBT I'm not so sure that even this is necessary as we don't seem to call the tool from tests that often. There is only ShellCommandTest that calls the run() function in RegistryCli and we could just put these tests in fragileTest and make them run sequentially and fork every time to get around issue with inference). The issue with caching is that it tries to first create the to-be-cached TM, and when the environment given is prod/sandbox/... It will try to retrieve SQL credentials from prod/sandbox/... secret manager. This works fine locally as we all have access to prod/sandbox/..., but fails in Cloud Build jobs such as sync-db-objects where it provides it own credential that has direct SQL access, but not access to prod/sandbox/... secret manager. TESTED=ran `./gradlew devTool --args="-e localhost generate_sql_er_diagram -o ../db/src/main/resources/sql/er_diagram"`
- Loading branch information
Showing
3 changed files
with
16 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters