Skip to main content

RCSB File Access Service Application

Project description

RCSB File Access API Application

A FastAPI File Access Service Application

Build Status

Installation

Download the library source software from the project repository:


git clone --recurse-submodules https://github.com/rcsb/py-rcsb_app_file.git

Optionally, run test suite (Python 3.9) using setuptools or tox:

python setup.py test

or simply run

tox

Installation is via the program pip.

pip install rcsb.app.file

or from the local repository directory:

pip install .

Deployment on Local Server

Testing without docker

From base repository directory (in py-rcsb_app_file/), start app with:

./deploy/LAUNCH_GUNICORN.sh

Then, in a separate shell (also from the base repository directory), run individual tests, e.g.:

python3 ./rcsb/app/tests-file/testClientUtils.py

Build Docker Container

In directory that contains Dockerfile.stage:


docker build --build-arg USER_ID=<user_id> --build-arg GROUP_ID=<group_id> -t fileapp -f Dockerfile.stage .

Run docker container


docker run --rm --name fileapp -p 80:8000 fileapp

-d runs container in the background, allowing user to

–-rm removes the container after it is stopped

–-name allows user to choose a name for the container

-p allows user to choose a port, 80:8000 is used in this case, as the port 8000 is exposed in the current dockerfile

Test upload and download using testClientScript.py

Edit url variables to match server url in testClientScript.py


python3 testClientScript.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

rcsb.app.file-0.20.tar.gz (27.7 kB view details)

Uploaded Source

File details

Details for the file rcsb.app.file-0.20.tar.gz.

File metadata

  • Download URL: rcsb.app.file-0.20.tar.gz
  • Upload date:
  • Size: 27.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/4.0.1 CPython/3.9.15

File hashes

Hashes for rcsb.app.file-0.20.tar.gz
Algorithm Hash digest
SHA256 15d438dab9dda9b4ad581188986fa35176f25d72da48e9e21c6ad931aa04769a
MD5 d1a6540107188b1271f21bd213337518
BLAKE2b-256 1e882c9033b9b10d0bb172121f8ec57bb69ee427df86ff4e6fab152135ea08bf

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page