Skip to content

Commit

Permalink
Update recommended approach for local deployment to use aiidalab-laun…
Browse files Browse the repository at this point in the history
…ch (#236)

* Update README.md

* Remove files related to manage.py.
  • Loading branch information
csadorf authored Jan 7, 2022
1 parent 831ec84 commit 4dba17f
Show file tree
Hide file tree
Showing 6 changed files with 13 additions and 347 deletions.
1 change: 0 additions & 1 deletion .env.demo

This file was deleted.

50 changes: 13 additions & 37 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,54 +8,30 @@ Docker images are automatically built and pushed to Docker Hub at https://hub.do
- `<version>` – a specific tagged release, example: `21.12.0`.
- `master`/`develop` – the latest commit on the corresponding branches with the same name.

# Documentation
# Get started

## Local deployment

To launch a local instance of AiiDAlab, first clone this repository, e.g., with
```console
git clone https://github.com/aiidalab/aiidalab-docker-stack.git
cd aiidalab-docker-stack
```
and then install the Python requirements needed to run the manage script:
```
pip install -r requirements-manage.txt
```

Before starting AiiDAlab, it is recommended to configure it for your needs.
For example, to mount the AiiDAlab home directory on your local host at `~/aiidalab` instead of using a Docker volume, execute:
```console
./manage.py configure --home-dir=~/aiidalab
```
This creates a `.env` file in the local directory that stores the provided settings.
To run AiiDAlab on your own workstation or laptop you can either
- run the image directly with: `docker run aiidalab-docker-stack -p 8888:8888`, or
- _(recommended)_ use the `aiidalab-launch` tool which is a thin docker wrapper.

You can then launch your local AiiDAlab deployment with:
The `aiidalab-launch` tool provides a convenient and robust method of both launching and managing one or multiple AiiDAlab instances on your computer.
To use it, simply install it via pip
```console
$ ./manage.py up
pip install aiidalab-launch
```
You should see output similar to this:
```
Starting AiiDAlab (this can take multiple minutes) ...
Open this link in the browser to enter AiiDAlab:
http://localhost:8888/?token=be20d9872d...
```

Note: AiiDAlab will keep running until you shutdown or restart the host computer, in which case, you will have to run the `up` command again to restart AiiDAlab.

Please see `./manage.py --help` for a full list of available commands.

## Development deployment

For a local development deployment, run
and then start AiiDAlab with
```console
./manage.py --develop up
aiidalab-launch start
```
Note: AiiDAlab will keep running until you explicitly stop it or shutdown/restart your computer.
In that case, you will have to run the `aiidalab-launch start` command again to restart AiiDAlab.

This will build and start an image where the `aiidalab` package, the `aiidalab-widgets-base` library, and the `aiidalab-home` app are installed with their latest development versions instead of their latest release versions.
Please see `aiidalab-launch --help` for a full list of available commands and options.

## Other deployments
## Cloud and other deployments

The `manage.py` script uses docker-compose to manage the local AiiDAlab deployment.
Please see the [AiiDAlab documentation](https://aiidalab.readthedocs.io/) for information on how to use and deploy AiiDAlab docker images in alternative ways.

## Citation
Expand Down
12 changes: 0 additions & 12 deletions docker-compose.develop.yml

This file was deleted.

17 changes: 0 additions & 17 deletions docker-compose.yml

This file was deleted.

277 changes: 0 additions & 277 deletions manage.py

This file was deleted.

3 changes: 0 additions & 3 deletions requirements-manage.txt

This file was deleted.

0 comments on commit 4dba17f

Please sign in to comment.