Project

General

Profile

Actions

Windows installation

Although OpenAtlas is developed and tested to install on Linux (Debian to be precise) there are cases one might install it on a Windows system e.g. to try it out or for developing.
We don't recommend to use a Windows installation for a productive use but want to give some instruction how to go about nevertheless.

Keep in mind that these instructions are not maintained as regularly as the ones for the main environment Linux and might therefore not be entirely up to date.

Software Installation

Required software

You find a package list at requirements.txt the root of the OpenAtlas application which can be used, e.g. to install software with pip

Further you will need:
  • NodeJs
  • npm (usually installed with NodeJs)
  • Python

Install Microsoft Visual C++ 14.0 or greater

To be able to install all required packages MV C++ 14.00 or greater is needed. You can get it via https://visualstudio.microsoft.com/visual-cpp-build-tools/ the name of the required package in the build tools is "MSVC... Buildtools" we tested it with "MSVC v143 - VS 2022 C++-x64/x86-Buildtools" but it might work with older versions as well.

Install PostgreSQL and PostGIS

The download link for the newest PostgreSQL Version Windows installer can be found on [[https://www.postgresql.org/download/windows/]] in the first line under "Download the installer".
Choose the appropriate version and use the installer to get PostgreSQL, during the process you can choose to use the stack builder tool to install additional extensions. Through this you can also easily obtain and install PostGIS, though there are other ways as well should you want to.
Change locale to en_US UTF-8.

Step by Step:
  • Run the PostGres installer
    • Install Path: Choose to your liking
    • Install all Components
    • Password: Choose one you'll remember
    • Port: Can be left on default or changed to fit preference
    • Locale: Choose English - United States
    • In the last step you will be able to disable the StackBuilder. Make sure you leave it enabled, then finish the installation.
  • Stack Builder:
    • Choose the PostGres Version
    • Spatial Extensions: Choose PostGis 3.3 (Though the other PostGis Versions should work as well)
    • Install Path: Choose to your liking
    • Run through the rest of the installation process, answering yes on all the questions

Install ImageMagick

Download the newest version from [[https://imagemagick.org/script/download.php#windows]] and install it (https://docs.wand-py.org/en/0.6.10/guide/install.html#install-imagemagick-on-windows use this guide).
Important: Install the dll version, not the static one!

Restart your PC to make sure all PATH variables are successfully registered.

Project SetUp

SetUp with PgAdmin4

  • Login with the password you set during the PostGres SetUp
  • In the next screen you should already have/see a server
  • Set DB Password
  • Create a new User
    • Right Click Login/Group, Roles
    • Create -> Login/Group, Roles
    • Name: openatlas
    • Go to Tab "Definition"
    • Set the Password to: openatlas
    • Choose Privileges: All of them
    • Save

Database Setup
  • Creation:
    • Right click on Databases then choose Create > Database
    • Set name (openatlas)
    • Set owner to openatlas
    • Check in the Tab "Definition" that the encoding is UTF8
    • Save
  • Add extensions:
    • Right click on created DB > Create > Extension..
    • Select "postgis"
    • Repeat with "unaccent"
  • Set Up:
    • Right click the openatlas DB -> Choose query tool
    • Than either:
      • Copy the commands from OpenAtlas/Install/1_structure
      • or
      • Load File with commands from OpenAtlas/Install/1_structure
    • Repeat these steps for all the files in the Install folder
  • (optional) Import existing Dataset

Setting up "production.py" & "testing.py"

This is used to set variables for the project configuration. You will find an example in the instance folder.

  • Copy example_production.py in the same folder and rename it to production.py
  • Change DATABASE_PASS to the password you have set, or want, for the OpenAtlas Database.
  • Repeat the same for testing.py
  • Through these to files you can also set other variables, but this will not be covered here.

Install the Requirements

In the project root directory run the following command:
- pip install -r requirements.txt

Install the Frontend Libraries

Run the following commands (from the project root directory):
  • pip3 install calmjs
  • cd openatlas/static
  • pip3 install -e ./
  • npm --install openatlas

Setup process for the tests (WIP, not yet functional)

Installing the required packages:

Uncomment the lines following "# Used for testing" in "requirements.txt" then execute the following command:
- pip install -r requirements.txt

Setting up the Test Database with PgAdmin 4

  • Follow the steps outlined in Database Setup, but choose the name openatlas_test instead.

Running the tests

For testing run:
nose2 --with-coverage --coverage tests/ --coverage openatlas/ --coverage-report html --pretty-assert --verbose

Install with scoop.sh (no administration rights)

Use PowerShell
Get scoop: https://scoop.sh/

OpenAtlas

scoop install git 
scoop bucket add versions
scoop bucket add extras
scoop install python39 imagemagick nodejs

Collaboration

scoop install pycharm mattermost

Testing

Add a new tmp path to the testing.py where the user can write if /tmp not available, e.g.:

from pathlib import Path
TMP_DIR = Path('C:\\Users\\USERNAME')

Updated by Moritz Großfurtner about 1 month ago · 26 revisions

Also available in: PDF HTML TXT