/warehouse-beacon

Primary LanguageGoApache License 2.0Apache-2.0

beacon-go

AppEngine implementation of the Beacon API from the Global Alliance for Genomics and Health written in Go.

Here is an example query that is running against a private copy (for demonstration purposes) of the Illumina Platinum Genomes data:

http://goapp-beacon.appspot.com/?chromosome=chr17&coordinate=41196407&allele=A.

Prerequisites

In order to setup and deploy this application, you will need:

Setup

  • Prepare Genomics data.
    • Follow this guide to upload genomics data to a Google Cloud Project.
  • Clone this repo.
    • git clone git@github.com:googlegenomics/beacon-go.git
  • Edit the configuration.
    • In app.yaml, edit the values of GOOGLE_CLOUD_PROJECT and GOOGLE_BIGQUERY_TABLE to reference your data.
  • Deploy.
    • gcloud app deploy app.yaml --project <project name>
  • Query your new Beacon.
    • e.g. http://<your project>.appspot.com/?chromosome=chr17&coordinate=41196407&allele=A
    • Note that the chromosome parameter might look like chr17 or just plain 17 depending on the reference used.

Disable

If you'd like to disable the Beacon, follow these steps:

  • Go to https://appengine.google.com/.
  • Select your project.
  • Go to "Application Settings".
  • Find and click the "Disable Application" button.
  • You can visit the same settings page to re-enable the application.

Authentication

This application uses the Application Default Credentials. That means that, by default, it will have access to all data within the project in which it is deployed.

Remember that you have cloned the application to your project. You have your own instance of the application, which means:

  • Only this instance of the application has access to the data in your project (other people's instances will not have access).
  • The only access exposed is the Beacon API (people can't use this application to explore your data deeper than the Beacon API allows).
  • This instance only has access to data in your project (not other people's projects).

It is also possible to grant the application access to data within other projects. To accomplish this, add the "App Engine Service Account" of the project in which the application is deployed (found under the "Permissions" section in the Google Developers Console) as a member of the project that contains the data.

Cmds

kubectl apply --namespace bfx -f dply.yml
kubectl get service app-eng-hello-world-svc --namespace bfx
kubectl -n bfx get pods
kubectl delete pod app-eng-hello-world-84dbcbc59d-mxpvb --namespace bfx
kubectl delete service app-eng-hello-world-svc --namespace bfx