Skip to content

TACC/WMA-Tapis-Templates

Repository files navigation

WMA-Tapis-Templates

Requirements

Related Repositories

Provisioning a Tenant

  1. Create a client_secrets.py file with a CLIENT_USERNAME and CLIENT_PASSWORD (see client_secrets.example.py)
  2. Adjust the tenants, systems, and apps you wish to create in initialize_tenant.py
  3. Run python initialize_tenant.py to create/update the apps and systems in the tenants listed in TENANT_BASE_URLS

Creating a client

  1. Install Tapipy in a pyenv environment
    • With pyenv:
      1. pyenv install 3.11
      2. pyenv virtualenv 3.11 tapipy
      3. pyenv local tapipy
      4. pip install tapipy
      5. pip install ipython
    • With mise and poetry:
      1. Install mise and poetry
      2. mise use -g uv@latest
      3. poetry install
  2. Initiate an ipython session
    • ipython
  3. Create a client
from tapipy.tapis import Tapis
client = Tapis(base_url='https://portals.tapis.io', username='$USER', password='******')
client.get_tokens()

Creating a credential

  1. Create a keypair locally a. ssh-keygen -m PEM -t rsa -b 2048 -f ~/.ssh/$USER.frontera
  2. Copy the public key to your ~/.ssh/authorized_keys file on the frontera host
ssh [email protected]
PUBKEY="PASTE PUBLIC KEY HERE"
echo $PUBKEY >> ~/.ssh/authorized_keys`
  1. Copy the public and private key to the USER_CREDENTIAL_PRIVATE_KEY and USER_CREDENTIAL_PUBLIC_KEY values in client_secrets.py
  2. Adjust the systemId and base_url values for your desired tenant/system and run the create_client_credential.py script
  3. Test the keypair works by making a file listing on a system a. client.files.listFiles(systemId='frontera', path='/')

About

App Definitions for TAPIs Applications

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors