• Stars
    star
    112
  • Rank 311,076 (Top 7 %)
  • Language
    JavaScript
  • Created almost 12 years ago
  • Updated about 9 years ago

Reviews

There are no reviews yet. Be the first to send feedback to the community and the maintainers!

Repository Details

A node.js package that makes syncing a MongoDB database to S3 simple.

Node MongoDB / S3 Backup

This is a package that makes backing up your mongo databases to S3 simple. The binary file is a node cronjob that runs at midnight every day and backs up the database specified in the config file.

Installation

npm install mongodb_s3_backup -g

Configuration

To configure the backup, you need to pass the binary a JSON configuration file. There is a sample configuration file supplied in the package (config.sample.json). The file should have the following format:

{
  "mongodb": {
    "host": "localhost",
    "port": 27017,
    "username": false,
    "password": false,
    "db": "database_to_backup"
  },
  "s3": {
    "key": "your_s3_key",
    "secret": "your_s3_secret",
    "bucket": "s3_bucket_to_upload_to",
    "destination": "/",
    "encrypt": true,
    "region": "s3_region_to_use"
  },
  "cron": {
    "time": "11:59",
  }
}

All options in the "s3" object, except for desination, will be directly passed to knox, therefore, you can include any of the options listed in the knox documentation.

Crontabs

You may optionally substitute the cron "time" field with an explicit "crontab" of the standard format 0 0 * * *.

  "cron": {
    "crontab": "0 0 * * *"
  }

Note: The version of cron that we run supports a sixth digit (which is in seconds) if you need it.

Timezones

The optional "timezone" allows you to specify timezone-relative time regardless of local timezone on the host machine.

  "cron": {
    "time": "00:00",
    "timezone": "America/New_York"
  }

You must first npm install time to use "timezone" specification.

Running

To start a long-running process with scheduled cron job:

mongodb_s3_backup <path to config file>

To execute a backup immediately and exit:

mongodb_s3_backup -n <path to config file>

More Repositories

1

BreakfastSerial

A Firmata based framework for interacting with Arduinos over serial.
Python
117
star
2

quill

Quill is a simple blog engine inspired by Jekyll. Quill runs on node and has an easy command line interface. Themeing is as simple as editing a single html page.
JavaScript
51
star
3

arduino-101-workshop

A basic arduino workshop with Node.js
Arduino
14
star
4

Direct-Mapped-Cache-Simulation

This is a C implementation of a direct mapped cache (simulation)
C
14
star
5

grooveshark

A node.js package for grooveshark
CoffeeScript
11
star
6

SendGrid-Markdown-Demo

This is a demo using Node.js and websockets to send markdown formatted emails powered by SendGrid
JavaScript
10
star
7

playlist.sendgriddemos.com

A social playlist that's entirely powered by email using SendGrid's parse API and Rdio
JavaScript
10
star
8

forgery

A simple library for creating mock API data for testing
CoffeeScript
8
star
9

heroku-unicorn-scheduler

An email scheduler that you can run for FREE on heroku using unicorn
Ruby
4
star
10

iFridge

Totally awesome RFID integrated, Arduino powered fridge. Nuff said.
JavaScript
4
star
11

testuino

A simple build status notifier powered by arduino. [WIP]
JavaScript
3
star
12

TwilioEstevez.com

An API for Emilio Estevez jokes [Comedy Hack Day]
JavaScript
3
star
13

declaration-of-twitter-independence

The Declaration of Independence for Twitter Developers
JavaScript
3
star
14

Colloqueasy

Social network for CS336 written in PHP
PHP
3
star
15

Basic-C-Desktop-Search

Basic desktop search implemented in C. Takes advantage of basic data structures and software cacheing.
C
2
star
16

node-drone-virus

JavaScript
2
star
17

Twaiku

Twilio / Twitter powered Haikus
CoffeeScript
2
star
18

hackshots.com

An HTTPS wrapper for PinkyUrl.com
JavaScript
2
star
19

theycallmeswift.github.com

My personal blog, portfolio, and resume.
HTML
2
star
20

DiffChat

Real time code review and collaboration
JavaScript
1
star
21

jobs.theycallmeswift.com

The theycallmeswift.com jobs site
CSS
1
star
22

ChartBuildr

A web interface for designing and saving beautiful charts
JavaScript
1
star
23

full-stack-testing-with-node

Slides and sample code from my Codemash 2013 session
JavaScript
1
star
24

Frontend-JS-Demo

JavaScript
1
star
25

Class-Notes

CoffeeScript
1
star
26

Spine-Boilerplate

A basic boilerplate for a spine app with jasmine for unit testing and cucumber for integrations
CoffeeScript
1
star
27

shin-ny-wrapper

A RESTful wrapper for the SHIN-NY API so you don't have to SOAP around all day
JavaScript
1
star
28

1-through-9

Using the numbers 1 through 9, without changing the order insert a "+", "*", or nothing between each number to get an expression that evaluates to 2002.
Ruby
1
star