Skip to content
This repository has been archived by the owner on Dec 11, 2021. It is now read-only.

Commit

Permalink
MongoDB 3.0.1 and Mongoose 4.0 Not Working
Browse files Browse the repository at this point in the history
Installed MongoDB 3.0.1 and Mongoose 4.0 re #504 .  Not currently working (failed mochaTest).  Also modified Vagrantfile and some ansible files
  • Loading branch information
martzmakes committed Mar 31, 2015
1 parent 06bd94f commit 26122ba
Show file tree
Hide file tree
Showing 7 changed files with 32 additions and 31 deletions.
2 changes: 1 addition & 1 deletion Gruntfile.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ module.exports = function (grunt) {
grunt.loadNpmTasks('grunt-jsbeautifier');

grunt.registerTask('default', ['jshint', 'express:dev', 'mochaTest']);
grunt.registerTask('dev', ['jshint', 'jsbeautifier']);
grunt.registerTask('dev', ['jshint', 'jsbeautifier', 'express:dev', 'watch']);

// Print a timestamp (useful for when watching)
grunt.registerTask('timestamp', function () {
Expand Down
40 changes: 20 additions & 20 deletions deploy/ansible/roles/dre/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,23 +7,23 @@
- name: Make node user
user: name=node group=node system=yes state=present

- name: Make DRE folder
command: mkdir -p "/var/www/dre"
#- name: Make DRE folder
# command: mkdir -p "/var/www/dre"

- name: Make source folder
command: mkdir -p "/var/www/dre/source"
#- name: Make source folder
# command: mkdir -p "/var/www/dre/source"

- name: Make shared folder
command: mkdir -p "/var/www/dre/shared"
#- name: Make shared folder
# command: mkdir -p "/var/www/dre/shared"

- name: Make current folder
command: mkdir -p "/var/www/dre/current"
#- name: Make current folder
# command: mkdir -p "/var/www/dre/current"

- name: Clone DRE repository
git: repo="https://github.com/amida-tech/DRE.git" dest="/var/www/dre/source" #version="v1.3.1"
#- name: Clone DRE repository
# git: repo="https://github.com/amida-tech/DRE.git" dest="/var/www/dre/source" #version="v1.3.1"

- name: Copy DRE source to current
command: cp -r /var/www/dre/source/. /var/www/dre/current
#- name: Copy DRE source to current
# command: cp -r /var/www/dre/source/. /var/www/dre/current

- name: Install grunt CLI tools
sudo: yes
Expand All @@ -45,7 +45,7 @@
# command: npm install chdir=/var/www/dre/current/client

- name: Install DRE client bower dependencies
command: bower install --allow-root chdir=/var/www/dre/current/client
command: bower install --allow-root chdir=/vagrant/dre/client


#- name: Install ruby
Expand All @@ -70,14 +70,14 @@


- name: Install DRE server dependencies
command: npm install --production chdir=/var/www/dre/current
command: npm install chdir=/vagrant/dre

- name: Install PM2
command: npm install -g pm2 --unsafe-perm
#- name: Install PM2
# command: npm install -g pm2 --unsafe-perm

- name: Launch DRE through PM2
command: pm2 start /var/www/dre/current/server.js
#- name: Launch DRE through PM2
# command: pm2 start /var/www/dre/current/server.js

- name: Configure PM2 for Auto-reload
command: pm2 startup centos -u node && pm2 save
#- name: Configure PM2 for Auto-reload
# command: pm2 startup centos -u node && pm2 save

5 changes: 0 additions & 5 deletions deploy/ansible/roles/mongodb/files/10gen.repo.j2

This file was deleted.

5 changes: 5 additions & 0 deletions deploy/ansible/roles/mongodb/files/mongodb-org-3.repo.j2
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
[mongodb-org-3]
name=MongoDB Repository
baseurl=http://repo.mongodb.org/yum/redhat/$releasever/mongodb-org/3.0/x86_64/
gpgcheck=0
enabled=1
6 changes: 3 additions & 3 deletions deploy/ansible/roles/mongodb/tasks/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,12 @@
user: name=mongod group=mongod comment="MongoD" append=yes
sudo: yes

- name: Install 10gen yum repo
copy: src=10gen.repo.j2 dest=/etc/yum.repos.d/10gen.repo
- name: Install mongodb-org-3 yum repo
copy: src=mongodb-org-3.repo.j2 dest=/etc/yum.repos.d/mongodb-org-3.repo
sudo: yes

- name: Install mongodb
yum: name={{item}} enablerepo="10gen" state="installed"
yum: name={{item}} enablerepo="mongodb-org-3" state="installed"
sudo: yes
with_items:
- mongodb-org
Expand Down
1 change: 1 addition & 0 deletions deploy/vagrant/Vagrantfile
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Vagrant.configure("2") do |config|

# Shared folders.
# You can only use NFS (second option below) once nfs-utils is installed.
config.vm.synced_folder "/Users/matthewmartz/Development/Amida/DRE", "/vagrant/dre"
# config.vm.synced_folder "/path/to/local/folder", "/path/to/remote"
# config.vm.synced_folder "/path/to/local/folder", "/path/to/remote",
# :nfs => !RUBY_PLATFORM.downcase.include?("w32"),
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,8 +48,8 @@
"method-override": "2.2.0",
"mllp-node": "~1.0.0",
"mocha": "1.18.x",
"mongodb": "1.4.x",
"mongoose": "3.8.8",
"mongodb": "^2.0.14",
"mongoose": "^4.0",
"morgan": "1.3.2",
"passport": "0.2.x",
"passport-local": "1.0.x",
Expand Down

1 comment on commit 26122ba

@jsachs
Copy link
Contributor

@jsachs jsachs commented on 26122ba Apr 1, 2015

Choose a reason for hiding this comment

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

I don't think we've said yea or nay to Mongo 3.0 yet. I would put this commit on another branch. The PR for the image fix looks good, so if you leave that on its own branch and PR it I'll merge it.

Please sign in to comment.