Closed
Bug 1287593
Opened 8 years ago
Closed 8 years ago
add create-db command to run.sh
Categories
(Release Engineering Graveyard :: Applications: Balrog (backend), defect)
Release Engineering Graveyard
Applications: Balrog (backend)
Tracking
(Not tracked)
RESOLVED
FIXED
People
(Reporter: bhearsum, Assigned: nhuang, Mentored)
References
Details
(Whiteboard: [lang=python])
Attachments
(1 file)
651 bytes,
patch
|
bhearsum
:
review+
|
Details | Diff | Splinter Review |
We rebuilt stage this morning, and it would've been very helpful to have a target in run.sh that creates a db and optionally populates it with some data. Having this would avoid the need to override the entrypoint.
Reporter | ||
Updated•8 years ago
|
Assignee: bhearsum → nobody
Mentor: bhearsum
Whiteboard: [lang=python][good first bug]
Comment 1•8 years ago
|
||
I would like to work on this bug.I am very new to open source(this is my very first bug) so can you guide me how to go about it.
Reporter | ||
Comment 2•8 years ago
|
||
(In reply to harsh shah from comment #1) > I would like to work on this bug.I am very new to open source(this is my > very first bug) so can you guide me how to go about it. Hi Harsh, thanks for your interest here! The first thing you'll want to do is fork the Balrog repo (https://github.com/mozilla/balrog), clone it locally, and make sure you can run all the tests succesfully. Once you have your local repo, try running "run-test.sh" and make sure it passes. If you have any trouble getting set-up feel free to e-mail me, or ask in irc://irc.mozilla.org/#balrog.
Comment 3•8 years ago
|
||
I would like to work on this bug, I've cloned the balrog repo, and the tests passed, what next has to be done? First-timer at bug fixing and also first-timer at mozilla.
Flags: needinfo?(bhearsum)
Reporter | ||
Comment 4•8 years ago
|
||
(In reply to meet123mangukiya from comment #3) > I would like to work on this bug, I've cloned the balrog repo, and the tests > passed, what next has to be done? First-timer at bug fixing and also > first-timer at mozilla. I'd like to give Harsh a few more days to respon before reassigning this. If you'd like to look at something in the meantime, https://bugzilla.mozilla.org/show_bug.cgi?id=1281459 or https://bugzilla.mozilla.org/show_bug.cgi?id=1270827 would be good choices.
Flags: needinfo?(bhearsum)
Comment 5•8 years ago
|
||
I'd like to work on this bug. I am decent at shell scripting and I'm ready to learn. :) Any pointers?
Reporter | ||
Comment 6•8 years ago
|
||
(In reply to deep.red.rosie.999 from comment #5) > I'd like to work on this bug. I am decent at shell scripting and I'm ready > to learn. :) > > Any pointers? https://github.com/mozilla/balrog/blob/master/uwsgi/run.sh is the file referenced by the bug title. What we need is a section similar to "upgrade-db" that initializes an empty db instead. This will probably be a matter of calling out to https://github.com/mozilla/balrog/blob/master/scripts/manage-db.py, which already knows how to create the database. This is a bit trickier to test than some things. First of all, you'll need a virtualenv with Balrog installed, eg: git clone https://github.com/mozilla/balrog cd balrog virtualenv -p /usr/bin/python2.7 venv source venv/bin/activate python setup.py develop When this is fixed correctly, we should be able to run commands such as: DBURI=sqlite:///tmp/foo.db bash uwsgi/run.sh upgrade-db ...and end up with a fully initialized database in /tmp/foo.db. -- I know this may be a lot to take in, so feel free to e-mail me or ask in irc://irc.mozilla.org/#balrog if you have any questions.
Assignee: nobody → deep.red.rosie.999
Reporter | ||
Comment 8•8 years ago
|
||
(In reply to Ben Hearsum (:bhearsum) from comment #7) > Did you make an progress? It looks like you're not working on this. I'm going to unassign it for now. Please let me know if you still want to give it a try.
Flags: needinfo?(deep.red.rosie.999)
Whiteboard: [lang=python][good first bug] → [lang=python]
Reporter | ||
Updated•8 years ago
|
Assignee: deep.red.rosie.999 → nobody
Comment 9•8 years ago
|
||
Is this still open?
Assignee | ||
Comment 10•8 years ago
|
||
Hi, I created a patch to add create-db to run.sh. Tested out with `DBURI=sqlite:///foo.db bash scripts/run.sh create-db` and verified that foo.db is created, and checked that run-tests.sh passes for all tests
Attachment #8812093 -
Flags: review?(bhearsum)
Reporter | ||
Comment 11•8 years ago
|
||
(In reply to nhuang from comment #10) > Created attachment 8812093 [details] [diff] [review] > Patch to add create-db in run.sh > > Hi, I created a patch to add create-db to run.sh. Tested out with > `DBURI=sqlite:///foo.db bash scripts/run.sh create-db` and verified that > foo.db is created, and checked that run-tests.sh passes for all tests This looks good - if you have a Github account, could you send it as a Pull Request to https://github.com/mozilla/balrog?
Assignee: nobody → nhuang
Flags: needinfo?(nhuang)
Reporter | ||
Updated•8 years ago
|
Attachment #8812093 -
Flags: review?(bhearsum) → review+
Assignee | ||
Comment 12•8 years ago
|
||
(In reply to Ben Hearsum (:bhearsum) from comment #11) > (In reply to nhuang from comment #10) > > Created attachment 8812093 [details] [diff] [review] > > Patch to add create-db in run.sh > > > > Hi, I created a patch to add create-db to run.sh. Tested out with > > `DBURI=sqlite:///foo.db bash scripts/run.sh create-db` and verified that > > foo.db is created, and checked that run-tests.sh passes for all tests > > This looks good - if you have a Github account, could you send it as a Pull > Request to https://github.com/mozilla/balrog? Sure, will do this tonight
Assignee | ||
Comment 13•8 years ago
|
||
(In reply to nhuang from comment #12) > (In reply to Ben Hearsum (:bhearsum) from comment #11) > > (In reply to nhuang from comment #10) > > > Created attachment 8812093 [details] [diff] [review] > > > Patch to add create-db in run.sh > > > > > > Hi, I created a patch to add create-db to run.sh. Tested out with > > > `DBURI=sqlite:///foo.db bash scripts/run.sh create-db` and verified that > > > foo.db is created, and checked that run-tests.sh passes for all tests > > > > This looks good - if you have a Github account, could you send it as a Pull > > Request to https://github.com/mozilla/balrog? > > Sure, will do this tonight Pull request sent
Comment 14•8 years ago
|
||
Commit pushed to master at https://github.com/mozilla/balrog https://github.com/mozilla/balrog/commit/6ad44d54f1fd07b266d3024113ab607be4b7af0a bug 1287593: Add create-db command to run.sh (#180). r=bhearsum
Reporter | ||
Updated•8 years ago
|
Flags: needinfo?(nhuang)
Status: NEW → RESOLVED
Closed: 8 years ago
Resolution: --- → WORKSFORME
Reporter | ||
Comment 15•8 years ago
|
||
Normally we wait until things are in production to close the bugs, but this is fine :) - just correcting the resolution.
Resolution: WORKSFORME → FIXED
Assignee | ||
Comment 16•8 years ago
|
||
(In reply to Ben Hearsum (:bhearsum) from comment #15) > Normally we wait until things are in production to close the bugs, but this > is fine :) - just correcting the resolution. Oh oops thought it was in prod sorry :(
Comment 17•8 years ago
|
||
This change will be deployed in bug 1320966 sometime between 11am and 1pm pacific on 2016-11-30. IT will be deployed to stage today. Can you verify your fixes once stage is deployed please?
Flags: needinfo?(nhuang)
Reporter | ||
Comment 18•8 years ago
|
||
There's nothing here that can be verified in stage.
Flags: needinfo?(nhuang)
Updated•4 years ago
|
Product: Release Engineering → Release Engineering Graveyard
You need to log in
before you can comment on or make changes to this bug.
Description
•