Skip to content
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

Add ability to run this project in Docker #9

Open
wants to merge 26 commits into
base: master
Choose a base branch
from

Conversation

uzakov
Copy link

@uzakov uzakov commented Jul 31, 2020

Summary
This PR makes it easier to run this project, by running it in Docker and not having to install all the Python requirements. As you see from Reddit WSB comments many people can't run this project easily.

Note
This doesn't address PIP8 issues

@RKosow
Copy link

RKosow commented Jul 31, 2020

I was just considering doing the same thing!
If you want to make this even more idiot-proof, you could clone the repo in the container and also wrap all your commands with a shell script or make.
Give them two targets, make scan and make graph.

README.md Outdated
## How to run
Build docker image by running
<pre>
docker build docker build --tag NAME:VERSION . ie docker build --tag wsb:1.0 .

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
docker build docker build --tag NAME:VERSION . ie docker build --tag wsb:1.0 .
docker build --tag NAME:VERSION . ie docker build --tag wsb:1.0 .

@adeiva
Copy link

adeiva commented Jul 31, 2020 via email

README.md Outdated
3) Open project in your IDE and install all required dependancies by typing pip install -r requirements.txt into the IDE's terminal. You can get to the the terminal on VSC by pressing CMD and ` at the same time.

## How to run
Build docker image by running

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you may want to explain how to install docker, or even link to the install page here:
https://docs.docker.com/get-docker/

Copy link

@RKosow RKosow Jul 31, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's already noted in the requirements section, line #7 of the readme.
Though it's probably worth being explicit that you need to run these docker commands in the same directory as the Dockerfile.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@BeauBouchard See line 7 and @RKosow it's very obvious but also a good idea, adding that now

NihilistPenguin and others added 22 commits July 31, 2020 01:51
Change time output to minutes instead of seconds
Add ability to print all results together an the end
Output anomalous tickers to a results.txt file
opens anomalous tickers in Robinhood in a new browser window
Creates graphs for all tickers in results.txt 
Allows option for single ticker or tickers of your choice
Example results.txt file
change line numbers for controlling the script
Add/update descriptions grapher.py and openRobinhood.py
Fix formatting error
Provides option to save graphs to the figures directory or to print them to screen
Create figures dir if it doesn't exist
remove previous addition of printing anomalous results together at the end
@uzakov
Copy link
Author

uzakov commented Jul 31, 2020

@adeiva Can you please provide more information what exactly is not working for you.
Just tested, all works
image

@adeiva
Copy link

adeiva commented Jul 31, 2020 via email

@uzakov
Copy link
Author

uzakov commented Jul 31, 2020

@adeiva I just checked again and it all works, have you waited when running the script? It does take a while
image

@uzakov
Copy link
Author

uzakov commented Jul 31, 2020

@SamPom100 I believe its ready for review

@adeiva
Copy link

adeiva commented Jul 31, 2020 via email

@@ -0,0 +1,17 @@
FROM python:3
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Consider using smaller image, there's no need to have all of python to run this.

python:3-slim-buster is around 48MB compressed.
python:3 is around 320MB compressed.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

7 participants