This repository IS NO LONGER MAINTAINED. The resilience web app has been moved and it's maintained in the link: https://github.com/ConservationInternational/resilienceatlas/tree/develop/frontend.
This is the web app powering resilienceatlas.org
- NodeJs 11.9.0+ How to install
- npm 6.9.0+
- yarn 1.13.0+ (you can use npm instead)
Start here if your machine already has Requirements Installed, If you need help with installation, scroll to bottom
Install project dependencies:
yarn
Before running the application, you need to configure it by copying .env.example
to .env
and setting the appropriate values where needed.
To start the application, run:
yarn start
To compile production build, run:
yarn build
and then you can use your production build locally:
npm i -g serve
serve -s build
You need ruby 2.5.3, then you have to install gems using bundle install
. To deploy to staging you have to run:
gem install bundler -v 1.17.3
bundle install
bundle exec cap staging deploy
As the deploy task takes a lot of memory we have to run the compilation separately, go to the current
folder and run the next command:
cd ~/resilience-react/current
npm run --max_old_space_size=4000 build
- Navigate to 'Apps and Features"
- Select Programs and Features on the right under related settings
- Select Turn Windows Features on and Off
- Select Hyper-V and click ok
- Download Ubuntu Desktop
- Navigate to Hyper-V Manager (If you have Admin Priveleges, you can use Hyper-V Quick Create)
- In Hyper-V Manager click Action dropdown on top navigation bar and select Virtual Switch Manager
- Accept External Switch Defaults and Name it Something Personal eg. (YourName-VirtualSwitch)
- Click Action dropdown on top navigation bar and select New/VirtualMachine
- This Creation Wizard is Pretty Intuitive. A few settings to remember, in the order that you'll need them:
- SpecifyNameAndLocation: Name the virtual machine something memorable. I recommend a combination of project name and ubuntu20.04.1
- SpecifyGeneration: Generation 1
- AssignMemory: Ubuntu Requires a Minimum of 2000 MB of Starter Memory to Run Effectively.
- ConfigureNetworking: Select your custom Switch here
- InstallationOptions: Install Operating System from Bootable CD/DVD, Navigate to .iso file downloaded in Step 1
- Finish
- Start Virtual Machine
In this section we will be installing the dependencies from the Requirements Section Above onto your Virtual Machine
-
Open Terminal by navigating through applications in the grid dot logo at the bottom of your screen.
-
Run the following commands:
- apt sudo install git
- apt sudo install ruby
- apt sudo install npm
- apt sudo install nodejs
- curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add - -echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.list.d/yarn.list
-
Clone resilience-react repo to this machine using git clone https://github.com/ConservationInternational/resilienceatlas-react.git
I recommend installing git and using git Bash for installation. Although Using whatever command line tool you're most comfortable in will probably work as well.
- Install Ruby
- Install node
- Install yarn
- git clone https://github.com/ConservationInternational/resilienceatlas-react.git
- Fork it!
- Create your feature branch:
git checkout -b feature/my-new-feature
- Commit your changes:
git commit -am '[Feature] Add some feature'
- Push to the branch:
git push origin feature/my-new-feature
- Submit a pull request :D