Yedidyah Bar David has posted comments on this change.
Change subject: packaging: Allow restore to different db location
......................................................................
Patch Set 7:
(1 comment)
....................................................
File packaging/bin/engine-backup.sh
Line 342: ENGINE_DB_SECURED_VALIDATION=${MY_DB_SECURED_VALIDATION}
Line 343: ENGINE_DB_DRIVER=org.postgresql.Driver
Line 344:
ENGINE_DB_URL=jdbc:postgresql://\${ENGINE_DB_HOST}:\${ENGINE_DB_PORT}/\${ENGINE_DB_DATABASE}?${options}
Line 345: "
Line 346: eval "${MY_DB_CREDS}"
As I explained above, I do not want to write configuration before I know it
works.
I see 3 options:
1. Just set vars. In this one I have to duplicate the vars/values list - once
when setting, again when writing to real conf
2. Write to a temp file, source it, on success copy it to real conf. Better but
needs a temp file.
3. Use eval. I keep the temp settings in a var, eval it, on success write it to
file. I do not see a difference from "2." except for not needing a temporary
file. So I use this one.
Do you prefer something else?
Line 347: }
Line 348:
Line 349: changeDBConf() {
Line 350: local conf="${ENGINE_ETC}/engine.conf.d/10-setup-database.conf"
--
To view, visit http://gerrit.ovirt.org/20258
To unsubscribe, visit http://gerrit.ovirt.org/settings
Gerrit-MessageType: comment
Gerrit-Change-Id: Ie2c84111808c638a1c589cf3c14c271184a0a7c2
Gerrit-PatchSet: 7
Gerrit-Project: ovirt-engine
Gerrit-Branch: master
Gerrit-Owner: Yedidyah Bar David <[email protected]>
Gerrit-Reviewer: Alex Lourie <[email protected]>
Gerrit-Reviewer: Alon Bar-Lev <[email protected]>
Gerrit-Reviewer: Ofer Schreiber <[email protected]>
Gerrit-Reviewer: Sandro Bonazzola <[email protected]>
Gerrit-Reviewer: Yedidyah Bar David <[email protected]>
Gerrit-HasComments: Yes
_______________________________________________
Engine-patches mailing list
[email protected]
http://lists.ovirt.org/mailman/listinfo/engine-patches