Skip to content

Commit

Permalink
ci: Added missing license and docker files. Updated documentation ins…
Browse files Browse the repository at this point in the history
…tallation steps
  • Loading branch information
Carsopre committed Sep 9, 2024
1 parent e3621b2 commit 02efcf0
Show file tree
Hide file tree
Showing 3 changed files with 45 additions and 2 deletions.
20 changes: 20 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# To build this docker run:
# `docker build -t koswat`

FROM python:3.10

RUN apt-get update

# Copy the directories with the local koswat.
WORKDIR /koswat_src
COPY README.md LICENSE pyproject.toml poetry.lock /koswat_src/
COPY koswat /koswat_src/koswat

# Install the required packages
RUN pip install poetry
RUN poetry config virtualenvs.create false
RUN poetry install --without dev,docs
RUN apt-get clean autoclean

# Define the endpoint
CMD ["python3"]
18 changes: 18 additions & 0 deletions LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
GNU GENERAL PUBLIC LICENSE
Version 3, 29 June 2007

KOSWAT
Copyright (C) 2024 Stichting Deltares

This program is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program. If not, see <http://www.gnu.org/licenses/>.
9 changes: 7 additions & 2 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,12 @@ pip install git+https://github.com/Deltares/[email protected]
```
| You can also do the above with a commit-hash for development branches (e.g.:`@0504c06`)


3. Using [docker](https://www.docker.com/) (requires checking the repository in a directory):
```bash
cd <your koswat checked out directory>
docker build -t koswat:latest -f Dockerimage .
docker run -it koswat bash
```

## For developers
1. Checkout the code from github in a directory of your choice. You can either do this by downloading the source zip or (better) using git, for instance:
Expand All @@ -29,7 +34,7 @@ pip install git+https://github.com/Deltares/[email protected]

2. Navigate to your Koswat repository and then install the koswat package with your preferred step:

1. With [Anaconda](https://www.anaconda.com/) (our recommendation):
1. With [Miniforge](https://conda-forge.org/miniforge/) (our recommendation):
```bash
cd C:\repos\koswat
conda env create -f .conf\environment.yml
Expand Down

0 comments on commit 02efcf0

Please sign in to comment.