Scheduling with CS Tools
Archiver is a powerful tool in your arsenal as a ThoughtSpot administrator and in order to take full advantage of it, you'll want to schedule it to run regularly.
It can be helpful to keep close tabs on the amount of stale content that exists in your platform. Let's schedule our Archiver identification report to export from the platform once every week.
CS Tools
Since CS Tools lives on your PATH
, even though the code exists in an isolated environment, the entrypoint can
be reached anywhere on your system.
Schedule it
Now that we've decided how to track our content, we're ready to schedule our command to run weekly.
Need help?
A helpful online utility for writing your cron schedule expressions.
Find the copy button to the right of the code block.
Here are some examples. It's still recommended to test CS Tools locally first.
actions-workflow.yaml
name:
Extract data with CS Tools.
on:
schedule:
# Runs every day at 3:15 AM UTC
- cron: "15 3 * * *"
jobs:
extract_data_from_thoughtspot:
# Configure Environment Variables for CS Tools configuration
env:
CS_TOOLS_THOUGHTSPOT__URL: ${{ secrets.THOUGHTSPOT_URL }}
CS_TOOLS_THOUGHTSPOT__USERNAME: ${{ secrets.THOUGHTSPOT_USERNAME }}
CS_TOOLS_THOUGHTSPOT__SECRET_KEY: ${{ secrets.THOUGHTSPOT_SECRET_KEY }}
# CS_TOOLS_TEMP_DIR: ...
runs-on: ubuntu-latest
steps:
- name: Set up Python 3.12
uses: actions/setup-python@v4
with:
python-version: 3.12
- name: Install a specific version of CS Tools
run: python -m pip install https://github.com/thoughtspot/cs_tools/archive/v1.5.0.zip[cli]
# --config ENV: tells CS Tools to pull the information from environment variables.
- name: Run your CS Tools Command
run: "cs_tools config check --config ENV:"
Closing Thoughts
And that's it! Now you have all the tools (pun fully intended ) you need to be able to get up and running with the CS Tools project. Be sure to check out the rest of the documentation, and also find us on ThoughtSpot Community.