-
Notifications
You must be signed in to change notification settings - Fork 19
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
Added Docker configuration + HTTPS #1
base: master
Are you sure you want to change the base?
Conversation
Thanks! Will have a proper look/test with this tonight. Didn't expect PRs to come in, but always open to improving to bringing in improvements :) edit: might add a js file for docker to run that will test the database state and try to run db-migrate up, etc as a setup process |
That's actually a good idea. Right now everything's pretty hacky (esp. the callbacks in |
…at for MariaDB / strict MySQL
Based on your recommendation I've added a preflight check to verify the database state. This is always executed when running the container. Note:
Let me know if you (or anyone else reading this, for that matter) have any further questions :) (P.S.: The preflight script really won't win any prizes, I couldn't write three lines of proper JS for my life and I really don't care to learn it - I'm familiar with other languages though :) Another edit: this also means that if I want to fix any stuff or build new features, I'd probably port it to another language that I'm more comfortable with. But for now it's a really great tool and I'm very grateful that you chose to open-source it. I've used it a lot in Harbinger and was really sad when you took your server offline. I'm now hosting it on a private server for my guildmates. Not sure if I can bring back a completely public version in the future as it's a really low-end one. Bla bla ... enough chit-chat, bottom line is: thank you very much for your initial efforts in building a great tool <3 ) |
Hi, I basically got no clue what all this means, but I want to get this running. If I download this, how do I run it? Basically explain it like I'm 5. -Jay |
ELI5:
This is pretty much the simplest explanation I can give. If you shouldn't be able to get it running, feel free to shoot me an email (can be found on my GitHub profile) and I'm happy to provide further support and / or give you the URL to my installation (can't guarantee 100% uptime for that one though, as the machine which is running all that stuff is currently undergoing a lot of maintenance work). |
I can't seem to find half the files you are talking about... |
This might very well be the case because you asked for introductions in a PR which specifically targets a docker setup, so naturally I assumed you would have downloaded my fork. If you're using @Exgaves master branch then his directions in the readme are correct. Only thing I stumbled upon was that Since I don't really have the time to walk you through it I've deployed the current version on one of my servers: https://strongbox.exxe.space. Note that this is a very low power / high bandwidth machine, so response times can get quite high. |
I was not aware until now that I could download another branch, so I deleted everything and started over. Now all your instructions from the first post worked like a charm, with the exception of
Went to docker root and tried npm install bridge, but that got me an error message. I really appreciate you trying to help me out. Will ask for help on reddit and see if that gets me there :) |
@wackerl91 Is the program still hosted on your server? It is asking me for a username and a password. Is there any way to gain access or perhaps an alternate way? Thank you so much. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
i thought that private leagues broke strongbox... i couldn't get them to work when i tried this league. i will give your request a try myself.
"host": "<live db host>", | ||
"user": "root", | ||
"password": "root", | ||
"host": "192.168.2.101", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If you can put these details back to placeholders so the source doesn't contain forms of credentials I'm happy to merge this in
(sorry about the huge delay I just got quite burnt out from work and didn't feel like working on this for a while)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No worries about the delay. Hope you're feeling better now!
I'd prefer to just delete the entire file and instead add a file containing the placeholders as 'database.json.dist' (similar to how I've handled the config.json file) and add the one without .dist to gitignore. This prevents commits containing credentials in the first place, while also making sure to never replace edited config / DB credentials when pulling the latest master from your repo.
If you're ok with this approach I am more than happy to do the necessary changes plus adjust the readme accordingly and get back to you once it's done (currently not at home, so might take a few days).
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The best practice for handling stuff like this is generally environmental variables. Making that change to poestrongbox does seem out of scope for this PR though. If @Exgaves doesn't want to change how configuration is passed in, a common approach when dockerizing services that need config files is to have a startup script generate the config file with envsubst
and a template file.
EDIT: let me know if you want me to submit a PR for either of these btw
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also hardcoding the IP doesn't work, when I try to use it it gets connection timeout errors. Replacing the IP with poe-db
fixes this.
Hey, is this good to go for Blight League? And can I trivially enable more currencies for scanning? |
I've tried running this and my poe-strongbox container keeps restarting. Ran with completely default settings besides the local IP address (in production). EDIT: found a bug. Port 3000 is hardcoded into the poe-strongbox container. got around it with a workaround of port-forwarding on it. |
I've added a simple Docker configuration for easier setup (or for those who prefer running stuff in docker) and somewhat functional HTTPS (need this for my own reverse proxy setups as port 80 is blocked in my firewall).
bin/www
is still somewhat hacked and it still requires you to rundb-migrate up
from outside the container, though. Rest should be functional enough.Happy to fix any remaining issues with this :) (E: this also depends on if you have any interest in looking at PRs at all ;) )