-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
docs: updating README, adding terraform docs (#68)
- Loading branch information
Showing
5 changed files
with
104 additions
and
32 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,39 +4,35 @@ | |
|
||
# VarFish CLI | ||
|
||
Command line interface for [VarFishServer](https://github.com/bihealth/varfish-server). | ||
Command line interface for [bihealth/varfish-server](https://github.com/bihealth/varfish-server). | ||
|
||
## Getting Started | ||
> [!NOTE] | ||
> This repository focuses on the command line interface program `varfish-cli`. | ||
> If you are new to VarFish, you may want to start at the repository [bihealth/varfish-server](https://github.com/bihealth/varfish-server). | ||
- [VarFish Homepage](https://www.cubi.bihealth.org/software/varfish/) | ||
- [Manual](https://varfish-server.readthedocs.io/en/latest/) | ||
- [Installation Instructions](https://varfish-server.readthedocs.io/en/latest/admin_install.html) | ||
- [Docker Compose Installer](https://github.com/bihealth/varfish-docker-compose#run-varfish-server-using-docker-compose) | ||
## Installation | ||
|
||
## VarFish Repositories | ||
You can install `varfish-cli` from [bioconda](https://bioconda.github.io/): | ||
|
||
- [varfish-server](https://github.com/bihealth/varfish-server) -- | ||
The VarFish Server is the web frontend used by the end users / data analysts. | ||
- [varfish-annotator](https://github.com/bihealth/varfish-annotator) -- | ||
The VarFish Annotator is a command line utility used for annotating VCF files and converting them to files that can be imported into VarFish Server. | ||
- [varfish-cli](https://github.com/bihealth/varfish-cli) -- | ||
The VarFish Command Line Interface allows to import data through the VarFish REST API. | ||
- [varfish-db-downloader](https://github.com/bihealth/varfish-db-downloader) -- | ||
The VarFish DB Downloader is a command line tool for downloading the background database. | ||
- [varfish-docker-compose](https://github.com/bihealth/varfish-docker-compose) -- | ||
Quickly get started running a VarFish server by using Docker Compose. | ||
We provide a prebuilt data set with some already imported data. | ||
To create a new conda environment named `varfish-cli` with the package: | ||
|
||
## Installation | ||
``` | ||
mamba create -y -n varfish-cli -c bioconda varfish-cli | ||
conda activate varfish-cli | ||
varfish-cli --help | ||
``` | ||
|
||
### From Source | ||
To get help with individual sub commands: | ||
|
||
``` | ||
varfish-cli importer | ||
# OR | ||
varfish-cli importer --help | ||
``` | ||
|
||
```bash | ||
$ git clone [email protected]:bihealth/varfish-cli.git | ||
$ cd varfish-cli | ||
$ conda create -n varfish-cli python=3.7 | ||
$ conda activate varfish-cli | ||
$ pip install -e . | ||
You will also need to create a configuration file in your home folder with the server address: | ||
|
||
``` | ||
$ cat >~/.varfishrc.toml <<EOF | ||
[global] | ||
|
@@ -47,14 +43,34 @@ varfish_api_token = "XXX" | |
EOF | ||
``` | ||
|
||
### Using pip | ||
## Developer Information | ||
|
||
### Development Setup | ||
|
||
Preqrequisites: | ||
|
||
- Python >=3.10 | ||
|
||
Clone the repository: | ||
|
||
``` | ||
git clone [email protected]:bihealth/varfish-cli.git | ||
cd varfish-cli-ng | ||
``` | ||
|
||
Now, create a virtualenv and install the software and its development requirements: | ||
|
||
``` | ||
virtualenv venv | ||
source venv/bin/activate | ||
pip install -r requirements/develop.txt | ||
pip install -e . | ||
``` | ||
|
||
`varfish-cli` is also available as a pip-Package. | ||
Preferably install into a separate venv. | ||
Finally, create the configuration file: | ||
|
||
```bash | ||
$ pip install varfish-cli | ||
``` | ||
$ cat >~/.varfishrc.toml <<EOF | ||
[global] | ||
|
@@ -64,3 +80,18 @@ varfish_server_url = "https://varfish.example.com/" | |
varfish_api_token = "XXX" | ||
EOF | ||
``` | ||
|
||
### GitHub Project Management with Terraform | ||
|
||
``` | ||
export GITHUB_OWNER=bihealth | ||
export GITHUB_TOKEN=ghp_<thetoken> | ||
cd utils/terraform | ||
terraform init | ||
terraform import github_repository.varfish-cli varfish-cli | ||
terraform validate | ||
terraform fmt | ||
terraform plan | ||
terraform apply | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,2 @@ | ||
.terraform* | ||
terraform.tfstate* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# Mangement of the GitHub project. | ||
|
||
resource "github_repository" "varfish-cli" { | ||
name = "varfish-cli" | ||
description = "VarFish REST API client (CLI + Python package)" | ||
homepage_url = "https://github.com/bihealth/varfish-cli" | ||
visibility = "public" | ||
topics = [ | ||
"bioinformatics", | ||
"genetics", | ||
"varfish", | ||
"vcf", | ||
] | ||
|
||
has_issues = true | ||
has_downloads = true | ||
has_discussions = false | ||
has_projects = false | ||
|
||
allow_auto_merge = true | ||
allow_rebase_merge = false | ||
allow_merge_commit = false | ||
|
||
delete_branch_on_merge = true | ||
|
||
vulnerability_alerts = true | ||
|
||
squash_merge_commit_message = "BLANK" | ||
squash_merge_commit_title = "PR_TITLE" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
terraform { | ||
required_providers { | ||
github = { | ||
source = "integrations/github" | ||
} | ||
} | ||
} | ||
|
||
provider "github" {} |