Skip to content

Commit 524f48b

Browse files
authored
updates for v10 based on pixi (#49)
1 parent a011d47 commit 524f48b

File tree

8 files changed

+148
-124
lines changed

8 files changed

+148
-124
lines changed

docs/02_installation.md

Lines changed: 91 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -8,48 +8,105 @@ permalink: /install/
88
![image](https://img.shields.io/badge/Install%20with-conda-green.svg?style=flat-square)
99

1010

11-
## Install distributed version by conda
11+
## Install by pixi
1212

1313

14-
We are based on [miniforge](https://github.com/conda-forge/miniforge#download),
15-
which provides the minimal installers for Conda and Mamba specific to conda-forge. The packages of the base are from the conda-forge channel.
16-
conda-forge is the default and only channel configured.
17-
MSS is available as a conda package on the channel.
14+
The Mission Support System (MSS) including a Web Map Service (MSWMS), a Collaboration Server (MSColab)
15+
and a Graphical User Interface (MSUI) is available as a [conda-forge](https://anaconda.org/conda-forge/mss) package.
1816

19-
[conda-forge/mss](https://anaconda.org/conda-forge/mss)
17+
This channel conda-forge has builds for linux-64, osx-64, win-64, osx-arm64
2018

21-
The conda-forge channel has builds for osx-64, linux-64 and win-64.
19+
The conda-forge [github organization](https://conda-forge.github.io/) uses various automated
20+
continuous integration build processes.
2221

23-
The conda-forge [github organization](https://conda-forge.github.io/)
24-
uses various automated continuous integration build processes.
22+
In 2024, the workflow that has packages co-installed from Anaconda's channel and conda-forge is no longer supported.
23+
We recommend since version 10.0.0 of MSS to use [pixi](https://pixi.sh/latest/) for an installation.
24+
Get **pixi** from https://pixi.sh/latest/ for your operation system.
2525

26+
You can now decide if you want to install **mss** as global or a project.
2627

27-
You must install mss into a new environment to ensure the most recent
28-
versions for dependencies:
28+
### Global Installation
2929

30-
$ mamba create -n mssenv mss
31-
$ mamba activate mssenv
32-
(mssenv) $ mss -h
30+
You can install **mss** globally without defining a project first.
31+
This method is practical when you are interested in starting the client and don't need server configurations.
3332

34-
Afterwards reactivate the environment, this sets all env variables needed.
33+
```sh
34+
pixi global install mss
35+
```
3536

36-
(mssenv) $ mamba deactivate
37-
$ mamba activate mssenv
37+
#### Usage
3838

39-
For updating an existing MSS installation to the current version, it is
40-
best to install it into a new environment. If an existing environment
41-
shall be updated, it is important to update all packages in this
42-
environment.
39+
```sh
40+
msui
41+
mswms -h
42+
mscolab -h
43+
mssautoplot -h
44+
```
45+
46+
#### Updating
47+
48+
```sh
49+
pixi global update mss
50+
```
51+
52+
### Project Installation
53+
54+
Initialize a new project and navigate to the project directory:
55+
56+
```sh
57+
pixi init MSS
58+
cd MSS
59+
```
60+
61+
Use the shell command to activate the environment and start a new shell in there.
62+
63+
```sh
64+
pixi shell
65+
```
66+
67+
Add the **mss** dependencies from conda-forge.
68+
69+
```sh
70+
(MSS) pixi add mss
71+
```
72+
73+
#### Usage
74+
75+
Always, when you want to start **mss** programs after its installation,
76+
you have to activate the environment by `pixi shell` in the project dir.
77+
On the very first start of **msui**, it takes a bit longer because it setup fonts.
78+
79+
```sh
80+
cd MSS
81+
pixi shell
82+
```
83+
84+
```sh
85+
(MSS) msui
86+
(MSS) mswms -h
87+
(MSS) mscolab -h
88+
(MSS) mssautoplot -h
89+
```
90+
91+
#### Upgrading
92+
93+
```sh
94+
cd MSS
95+
pixi shell
96+
(MSS) pixi upgrade mss
97+
```
4398

44-
$ mamba activate mssenv
45-
(mssenv) $ mamba update mss
46-
(mssenv) $ mamba update --all
4799

48100
## Usage
101+
102+
We describe the global installation.
103+
49104
### GUI
50-
To start the MSS UI you can lookup for "mss" on your desktop program manager or use a terminal
105+
To start the MSS UI you have to use a terminal.
51106

52-
(mssenv) $ mss
107+
```sh
108+
$ msui
109+
```
53110

54111
> ![image](/assets/msui.png)
55112
@@ -59,8 +116,10 @@ The configuration is described in the section
59116
### mswms server
60117
To try out the setup you can use demo data. Read about a [server based installation](https://mss.readthedocs.io/en/stable/deployment.html).
61118

62-
(mssenv) $ mswms_demodata --seed
63-
(mssenv) $ mswms
119+
```sh
120+
$ mswms_demodata --seed
121+
$ mswms
122+
```
64123

65124
This data is then available on localhost:8081.
66125
The capabilities can be read on a [web browser](http://localhost:8081/?service=WMS&request=GetCapabilities&version=1.1.1) too.
@@ -70,9 +129,10 @@ The capabilities can be read on a [web browser](http://localhost:8081/?service=W
70129
### mscolab server
71130
To tryout the setup you can use demo data. Read about a [server based installation](https://mss.readthedocs.io/en/stable/mscolab.html).
72131

73-
(mssenv) $ mscolab db --init
74-
(mssenv) $ mscolab db --seed
75-
(mssenv) $ mscolab start
132+
```sh
133+
$ mscolab db --seed
134+
$ mscolab start
135+
```
76136

77137
The service is than availale on localhost:8083 and can be verified by the [server status](http://127.0.0.1:8083/status)
78138

docs/03_contributing.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ MSS is completely written in Python. The GUI is built using [PyQT5](https://www.
1616

1717
## Setup Instructions
1818

19-
You can quickly setup MSS on your machine by following the steps given in our [setup instructions](/develop/Setup-Instructions). If you want to use Docker you can follow the steps in our [docker setup guide](/develop/docker_images). For more details, you can read [Mission Support System’s Documentation](https://mss.readthedocs.io/en/stable)
19+
You can quickly setup MSS on your machine by following the steps given in our [setup instructions](/develop/Setup-Instructions).
2020

2121
## Finding Issues
2222

docs/04_gsoc.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ If you have any question please feel free to ask any of the mentors on our #gsoc
2323
We have labled small sized issues as "good first issue" on <https://github.com/Open-MSS/MSS/issues>.
2424

2525
# Getting Started
26-
- You can quickly setup MSS on your machine by following the steps given in our [setup instructions](/develop/Setup-Instructions). If you want to use Docker you can follow the steps in our [docker setup guide](/develop/docker_images). For more details, you can read [Mission Support System’s Documentation](https://mss.readthedocs.io/en/stable)
26+
- You can quickly setup MSS on your machine by following the steps given in our [setup instructions](/develop/Setup-Instructions). For more details, you can read [Mission Support System’s Documentation](https://mss.readthedocs.io/en/stable)
2727
- You can go through the issues labelled as [good first issue](https://github.com/Open-MSS/MSS/issues?q=is%3Aissue+is%3Aopen+label%3A%22good+first+issue%22) on our github repository and pick an issue you feel you can take up. Please write a comment on the issue you're taking up so multiple people don't work on the same issue. If you have any doubts related to the issue feel free to ask us on the Slack channel. You can also report any new issue you find on the Slack channel itself.
2828
- Once you've found the issue you want to work on you need to create a new branch on your local clone of the project and start working on it. As a general rule of thumb, bug fixes go to the `stable` branch while enhancements and other new features go to the `develop` branch. Generally it is mentioned in the issue itself which branch the fix needs to go. Otherwise you can always ask us on Slack.
2929
- To start working, create a new git branch, write your code, commit it and push this branch to your fork. Now create a pull request to the Master Repo's `develop` or `stable` branch. All pull requests must pass the test pipeline before they are merged.

docs/assets/msui.png

106 KB
Loading

docs/assets/run_mss_docker.png

-251 KB
Binary file not shown.

docs/develop/Docker.md

Lines changed: 0 additions & 41 deletions
This file was deleted.

docs/develop/Getting-Started.md

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -17,21 +17,19 @@ exclude: true
1717
- Are there any unusual libraries/applications that need to be
1818
installed first?
1919

20-
We are based on [miniforge](https://github.com/conda-forge/miniforge#download) and [conda-forge](https://conda-forge.org/).
20+
We are based on [pixi](https://pixi.sh/latest/) and [conda-forge](https://conda-forge.org/).
2121
All development is done with python 3.
2222

23-
On linux install `xvfb` and the conda package `pyvirtualdisplay`. This is used to run tests on a virtual display.
24-
2523

2624
- How do I have to setup my environment?
2725

2826
Dependent on the IDE there are differences, we try to describe this for anycase.
2927

3028
* Verify by `pytest` in your MSS directory that tests are executed
31-
* `python workspace/MSS/mslib/mswms/demodata.py -h` (see output on screen)
32-
* `python workspace/MSS/mslib/mswms/mswms.py -h`
33-
* `python workspace/MSS/mslib/msui/msui.py -h`
34-
* `python workspace/MSS/mslib/mscolab/server.py -h`
29+
* `mswms_demodata -h` (see output on screen)
30+
* `mswms -h`
31+
* `msui -h`
32+
* `mscolab -h`
3533

3634

3735
- What type of source control do you use?

docs/develop/Setup-Instructions.md

Lines changed: 50 additions & 43 deletions
Original file line numberDiff line numberDiff line change
@@ -5,86 +5,93 @@ permalink: /develop/Setup-Instructions
55
exclude: true
66
---
77

8-
## Environment Setup
8+
## Setup for development
99

10-
### Install distributed version by mamba
10+
Pixi is a package management tool for developers. It allows the developer to install libraries and
11+
applications in a reproducible way. Use pixi cross-platform, on Windows, Mac and Linux.
1112

12-
Install miniforge on your system.
13+
Install pixi on your system.
1314

14-
[Miniforge](https://github.com/conda-forge/miniforge#download) provides the minimal installers
15-
for Conda and Mamba specific to conda-forge. The packages of the base are from the conda-forge channel.
16-
conda-forge is the default and only channel configured.
15+
[Pixi](https://pixi.sh) provides the minimal installers
16+
specific to conda-forge. conda-forge is the default channel configured.
1717

1818
MSS is available as a package on the channel conda-forge.
1919

2020
[conda-forge/mss](https://anaconda.org/conda-forge/mss)
2121

22-
The conda-forge channel has builds for osx-64, linux-64 and win-64.
22+
The conda-forge channel has builds for osx-64, osx-arm64, linux-64 and win-64.
2323

24-
You must install mss into a new environment to ensure the most recent
25-
versions for dependencies. :
2624

27-
$ mamba create -n mssdev mss --only-deps
28-
$ mamba activate mssdev
29-
(mssdev) $
25+
#### Setup an environment for development
3026

31-
Afterwards reactivate the environment, this sets all env variables needed.
27+
The dependencies necessary to get a working development environment for MSS are specified in pixi.toml and pixi.lock inside the repository.
28+
This means you can get a shell with all required packages installed using
3229

33-
(mssdev) $ mamba deactivate
34-
$ mamba activate mssdev
30+
```sh
31+
pixi shell -e dev
32+
```
3533

36-
### Installing development specific packages
34+
Afterwards, a call to e.g.
3735

38-
Between the released and the develop version we have differences in used packages:
36+
```sh
37+
msui
38+
```
3939

40-
git diff stable develop -- localbuild/meta.yaml
41-
42-
Update accordingly of the output.
40+
will run the development version of msui.
4341

44-
For testing and building docs you need to install the these packages by running the following command:
42+
You can also use pixi's "run" subcommand to directly run a command in the development environment, like so::
43+
44+
```sh
45+
pixi run -e dev msui
46+
```
4547

46-
(mssdev) $ mamba install --file MSS/requirements.d/development.txt
4748

4849
## Running The Application
4950

5051
MSS has 3 main components. These are MSUI (GUI), MSWMS (web map server) and MSCOLAB (collaboration server). You can run all 3 components individually on your system.
5152
(Before running any of the commands make sure you have activated your environment.)
5253

53-
You need to first add the main mss folder which will be created in your home directory to your python path. Go into the cloned repo and update your python path:
54+
You need to first add the mss folder where additional configurations can become provided.
55+
There the mswms_demodata adds the mswms demo server configuration.
5456

57+
```sh
5558
$ cd MSS
56-
$ export PYTHONPATH="`pwd`:$HOME/mss"
59+
$ pixi shell -e dev
60+
$ (MSS) export PYTHONPATH=$HOME/mss"
61+
```
5762
5863
To start the MSS PyQT application:
59-
60-
(mssdev) $ python mslib/msui/msui.py
61-
64+
```sh
65+
(MSS) $ msui
66+
```
6267
When running MSWMS for the first time. Use the following command to create some dummy data:
63-
64-
(mssdev) $ python mslib/mswms/demodata.py --seed
65-
68+
```sh
69+
(MSS) $ mswms_demodata --seed
70+
```
6671
To start MSWMS:
67-
68-
(mssdev) $ python mslib/mswms/mswms.py
69-
72+
```sh
73+
(MSS) $ mswms
74+
```
7075
When running MSCOLAB for the first time you need to initialize your database (SQLite by default):
7176
72-
(mssdev) $ python mslib/mscolab/mscolab.py db --init
73-
77+
```sh
78+
(MSS) $ mscolab db --init
79+
```
7480
If you want to seed your MSCOLAB database you can run:
7581
76-
(mssdev) $ python mslib/mscolab/mscolab.py db --seed
82+
```sh
83+
(MSS) $ mscolab db --seed
84+
```
7785
7886
To start MSCOLAB server:
7987
80-
(mssdev) $ python mslib/mscolab/mscolab.py start
81-
88+
```sh
89+
(MSS) $ mscolab start
90+
```
8291
## Running Tests
8392
84-
On linux install the conda package pyvirtualdisplay and xvfb from your linux package manager. This is used to run tests on a virtual display. If you don’t want tests redirected to the xvfb display just setup an environment variable:
85-
86-
$ export TESTS_VISIBLE=TRUE
87-
8893
To run the tests:
8994
90-
(mssdev) $ pytest --cov mslib
95+
```sh
96+
(MSS) $ pytest --cov mslib
97+
```

0 commit comments

Comments
 (0)