No description
  • Ruby 75%
  • Haml 16.9%
  • HTML 6.4%
  • JavaScript 1%
  • SCSS 0.4%
  • Other 0.3%
Find a file
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jonathan Arnett 5e419a8fab Merge pull request #32 from J3RN/ruby-upgrade
Upgrade to Ruby 2.4.2
2017-10-21 23:38:22 -04:00
app Add autofocus 2017-10-19 19:57:23 -04:00
bin Removed the last traces of Redis 2015-11-05 16:29:02 -05:00
config Upgrade to Ruby 2.4.2 2017-10-21 23:33:22 -04:00
db Allow the user to configure the droplet size 2017-10-06 21:27:16 -04:00
lib Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
log Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
public Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
spec Allow the user to configure the droplet size 2017-10-06 21:27:16 -04:00
vendor/assets Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
.gitignore Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
.rspec Huge overhaul to ActiveRecord 2015-11-05 16:17:35 -05:00
.ruby-version Upgrade to Ruby 2.4.2 2017-10-21 23:33:22 -04:00
.travis.yml Upgrade to Ruby 2.4.2 2017-10-21 23:33:22 -04:00
Capfile Move from Mina to Capistrano 2017-10-05 23:14:32 -04:00
config.ru Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
Gemfile Upgrade to Ruby 2.4.2 2017-10-21 23:33:22 -04:00
Gemfile.lock Upgrade to Ruby 2.4.2 2017-10-21 23:33:22 -04:00
LICENSE Added MIT license 2015-11-05 19:39:29 -05:00
Rakefile Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00
README.md Merge pull request #17 from J3RN/readme-update 2017-09-27 21:16:51 -04:00
README.rdoc Moved to Rails from Sinatra 2015-11-04 11:34:26 -05:00

Minecraft Manager Travis CI Build Status

Rationale

I host my Minecraft server on DigitalOcean, who provides me with reasonable rates. Unfortunately, though, $20/month for a Minecraft server I'm in only every several days seems a bit excessive.

Solution

Enter Minecraft Manager! What does it do?

When you move the switch to "on"

  • Provisions a new droplet
    • in NYC3 (soon to be configurable)
    • with 2 GB of RAM (soon to be configurable)
    • using a snapshot from the last time your server was active, or an image of your choosing
    • with a configured ssh key (optionally)
    • with a "floating ip" (optionally)

When you move the switch to "off"

  • Powers off the droplet.
  • Takes a snapshot of that droplet.
  • Destroys the droplet so it stops charging you money.

As you can probably tell, this is very much a work in progress. Much more to come soon.

Stretch goals

  • JavaScript polling of an API to live-update the shutdown/startup process.
    • Show details of the "off" and "on" processes such as "powering off the droplet," and "taking a snapshot of the droplet," etc.

Setup

Before you do anything else, now would be a good time to generate an access token on DigitalOcean.

To get the app set up, simply run:

$ ./bin/setup

This will create two new users with emails "test@example.com" and "test@example.org" and password "testtest" for both. I recommend that you create a new account, as neither of these accounts will have an associated access token.

Running the server

You'll need to run both the Rails server and Sidekiq simultaneously to get the app to work in it's full capacity.

Start the Rails server:

bundle exec rails server

Start Sidekiq:

bundle exec sidekiq

You should now be able to visit the running application at http://localhost:3000 and create an account with your access token.

Happy Hacking!

Contributing

  • Fork the repository.
  • Clone your fork.
  • Create a feature branch (e.g. feature-add-new-thing, bugfix-fix-broken-thing, etc).
  • Push your changes up to your fork.
  • Send me a pull request.

Please and thank you!