"Initial" commit to reset history #1
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: ship-package | |
on: | |
push: | |
branches: [ main ] | |
# Allows you to run this workflow manually from the Actions tab | |
workflow_dispatch: | |
jobs: | |
build-and-upload: | |
runs-on: self-hosted | |
permissions: | |
contents: read | |
steps: | |
- uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Check for Changed Files | |
id: changed-files | |
uses: tj-actions/changed-files@635f118699dd888d737c15018cd30aff2e0274f8 | |
with: | |
files: | | |
annotated_logger | |
Dockerfile | |
pyproject.toml | |
requirements.txt | |
- name: Log into registry | |
if: steps.changed-files.outputs.any_changed == 'true' | |
uses: docker/login-action@0d4c9c5ea7693da7b068278f7b52bda2a190a446 | |
with: | |
registry: ghcr.io | |
username: ${{ secrets.GHCR_USER }} | |
password: ${{ secrets.GHCR_PW }} | |
- name: Build Package | |
uses: ./ # Action defined in action.yaml in the root | |
if: steps.changed-files.outputs.any_changed == 'true' | |
- name: Setup Octofactory config | |
uses: jfrog/setup-jfrog-cli@7c95feb32008765e1b4e626b078dfd897c4340ad | |
if: steps.changed-files.outputs.any_changed == 'true' | |
env: | |
JF_ENV_1: ${{ secrets.OCTOFACTORY_SERVER_CONFIG }} | |
- name: Upload to Octofactory | |
if: steps.changed-files.outputs.any_changed == 'true' | |
run: | | |
jfrog rt u dist/ logger-decorator-pypi |