-
Notifications
You must be signed in to change notification settings - Fork 13
installation
Roadmap is a Ruby on Rails application that requires the following:
-
Ruby >=
2.6.3
-
Rails >=
5.2
-
PostgreSQL
>= 9.2
or MySQL>= 5.5
-
Yarn
1.22.4
-
Node.js
10.x
for management of assets (DMPRoadmap is using the Rails asset pipeline with Webpacker) - ImageMagick used by the Dragonfly gem to manage logos
Further details on how to install Ruby on Rails applications are available from the Ruby on Rails site:
Further details on how to install the database server and create your first user and database. Be sure to follow the instructions for your particular environment.
-
PostgreSQL documentation:
-
MySQL documentation:
- Install: http://dev.mysql.com/downloads/mysql/
- Create a user: http://dev.mysql.com/doc/refman/5.7/en/create-user.html
- Create the database: http://dev.mysql.com/doc/refman/5.7/en/creating-database.html
You may also find the following resources useful:
- The Getting Started Guide: http://guides.rubyonrails.org/getting_started.html
- Ruby on Rails Tutorial Book: http://www.railstutorial.org/
- For MySQL: Select UTF-8 Unicode (
utf8mb4
) encoding.
We advise that you create a fork of this repository to store your local customization and branding. Then clone that fork.
Navigate to the cloned repository and run the following from the project root to install all of the dependencies (assuming you have Ruby and Node installed):
gem install bundler
bundle install
yarn install
- Run
EDITOR=vim bin/rails credentials:edit
(use you favorite editor here if you don't like vim - see the Rails docs for more info) - Copy / paste the contents of config/credentials.yml.example into the editor
- Modify the values (the DB credentials, secret_key_base and devise secret/pepper are the most important at this point). You can always run the above command again to make additional modifications
- This will generate a config/master.key and config/credentials.yml.enc file
- Manually edit the new
.env
andconfig/dmproadmap.yml
files created by the setup process - Run
cp ./dotenv.sample ./.env
unless you already have your own version of this file in place - Run
cp ./config/dmproadmap.yml.example ./config/dmproadmap.yml
unless your own version of this file in place - Run
bin/rails db:setup
- Run
rails s
to start the application - Visit http://localhost:3000 in a browser to verify that the site is working
- Log in as the default super admin account: using the email+password option (default is: '[email protected]'+'password123')
- Go to the 'Edit Profile' page and change your email and password to something more secure
If you will be enabling any of the maDMP / Networked DMP features in the config/dmproadmap.yml
file, you may also want to run the following Rake tasks depending on which features you enable:
- To allow users to specify their research domain run
bin/rails external_api:add_field_of_science_to_research_domains
. Which will populate theresearch_domains
table with the Field of Science categories defined by DataCite. - To allow users to specify their license for a research output run
bin/rails external_api:load_spdx_licenses
. Which will populate thelicenses
table with data from SPDX Database. - To allow users to specify their metadata standards for a research output run
bin/rails external_api:load_rdamsc_standards
. Which will populate themetadata_standards
table with data from RDA Metadata Standards Catalog. - To allow users to specify their intended repositories for a research output run
bin/rails external_api:load_re3data_repos
. Which will populate therepositories
table with data from Re3data.
You should perform the following tasks prior to deploying the system on a server that is accessible to the web:
-
Delete any other default users included in the
seeds.rb
file or at least change their passwords. -
Update the site's Branding.
- Please replace the
app/views/branded
files with your own copies. The DMPTool, UC3, CDL, DCC and DMPRoadmap logos and the DMPTool, DMPRoadmap names are for use by those organizations / applications.
- Designate/create a default template. If a user creates a plan and specifies no research organization and no funder (or a combination that results in no published templates) then their plan is created using a default template. You must define your default template in the DB by setting
templates.is_default
equal to true.