Skip to main content

Manage uploads to osstrack.io.

Project description

osstrack-action

GitHub action to upload your project dependencies to osstrack.io.

Overview

This action allows you to upload your project dependencies to osstrack.io. It is a simple way to keep track of the dependencies of your project and to have various metrics about them like freshness, security, and licensing.

Enabling the action

Declare dependencies

To declare the dependencies of your project, you need to create a file named .osstrack.conf in the root of your repository. This file is managed by the osstrack utility and should not be modified manually.

$ cd <workspace>
$ pip install osstrack
$ osstrack add poetry.lock
$ # add a virtualenv where to capture the dependencies with pip freeze
$ osstrack add .tox/functional
$ # remove a dependency
$ osstrack del .tox/functional

Sample Configuration

Defining Github Actions requires creating a directory .github/workflows inside your repository. Inside this directory, you create files processed when various events occur.

The simplest example of using this action would be to create the file .github/workflows/push.yml with the following contents:

---
name: Push
on:
  push:
    branches:
      - main
jobs:
  osstrack:
    runs-on: ubuntu-latest
    steps:

      - name: Checkout code
        uses: actions/checkout@v4
      
      - name: Set up Python
        uses: actions/setup-python@v5
        with:
          python-version: '3.12'

      - name: Create the virtualenv
        run: |
          sudo pip install tox
          tox -e functional --notest

      - name: Upload dependencies to osstrack.io
        uses: osstrack/osstrack-action@0.1
        with:
          token: ${{ secrets.OSSTRACK_TOKEN }}
...

You need to store the OSSTRACK_TOKEN in the repository secrets. You can create a token in the osstrack.io website.

Usage outside of a GitHub action

If you want to use the same dependency management in other CI pipelines or in a local test, you can install the python package:

$ pip install osstrack

Then you can use the osstrack command to upload the dependencies of a change:

$ cd <workspace>
$ export OSSTRACK_TOKEN=<your token>
$ # extract the dependencies of the current branch using tox
$ # or whatever you use to create the virtualenv
$ tox -e functional --notest
$ # Upload the dependencies of the current branch
$ osstrack upload

Roadmap

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

osstrack-0.1.1.dev0.tar.gz (15.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

osstrack-0.1.1.dev0-py3-none-any.whl (14.9 kB view details)

Uploaded Python 3

File details

Details for the file osstrack-0.1.1.dev0.tar.gz.

File metadata

  • Download URL: osstrack-0.1.1.dev0.tar.gz
  • Upload date:
  • Size: 15.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for osstrack-0.1.1.dev0.tar.gz
Algorithm Hash digest
SHA256 b1b6e3e845b211bed09928b829ac6656610c2123e7e7390c2c8dc788d33e9d6f
MD5 4c44d6beb3c5162af67165b8d89a5d78
BLAKE2b-256 58d88328497bd7798d2d8146056c91de7728da035b2a06e6225ddc4a521da9e5

See more details on using hashes here.

File details

Details for the file osstrack-0.1.1.dev0-py3-none-any.whl.

File metadata

  • Download URL: osstrack-0.1.1.dev0-py3-none-any.whl
  • Upload date:
  • Size: 14.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for osstrack-0.1.1.dev0-py3-none-any.whl
Algorithm Hash digest
SHA256 a10e3ca89771ae56aed43db555d52f8bb92f1fac75944031b42a21592ff27521
MD5 104ae27a6e651f48f129ca17e6d3b317
BLAKE2b-256 b8230fa55256f47f1a696b4ea8feccc44c0aa50d08674391103fc8370fa5c52e

See more details on using hashes here.

Supported by

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