Try the LW study hall and/or find a pomodoro-esque technique that works for you. The trick is to work with your desire to check reddit rather than against it - if you have a 5 minute block where goofing off is a Totally Okay Thing That You Don't Feel Guilty About, you'll be able to get back into the flow of work once your goof-off time is up.
Use the various different browser extensions to curtail your access to time-sink websites.
If it's worth saying, but not worth its own post (even in Discussion), then it goes here.