mirror of
https://staging.allspice.dev/AllSpice-Demos/Actions-demo.git
synced 2025-04-24 09:13:21 +00:00
Remove debug workflow
This commit is contained in:
parent
a7b0ac0db5
commit
3d5caedd0e
@ -1,93 +0,0 @@
|
||||
# Python-py-allspice demo repository
|
||||
# This workflow demonstrates how to use Python and py-allspice to interact with the AllSpice API
|
||||
# AllSpice Actions documentation: https://learn.allspice.io/docs/actions-cicd
|
||||
name: Debugging workflows
|
||||
on:
|
||||
push:
|
||||
issues:
|
||||
types: [opened, closed, reopened]
|
||||
|
||||
jobs:
|
||||
py-allspice test:
|
||||
runs-on: ubuntu-latest
|
||||
steps:
|
||||
|
||||
# Check out repository code
|
||||
- name: "[📚->🖥️] Check out repository code"
|
||||
uses: actions/checkout@v3
|
||||
|
||||
# Run some basic debugging steps
|
||||
- name: "Print container info 🔎"
|
||||
run: |
|
||||
{
|
||||
echo "OS Version: $(lsb_release -a)"
|
||||
echo "Container IP: $(hostname -I)"
|
||||
echo "Container Hostname: $(hostname)"
|
||||
echo "Container OS: $(uname -a)"
|
||||
echo "Container CPU: $(lscpu)"
|
||||
echo "Container Memory: $(free -h)"
|
||||
echo "Container Disk: $(df -h)"
|
||||
echo "Container Network: $(ifconfig)"
|
||||
echo "Current user: $(whoami)"
|
||||
echo "Container Users: $(who)"
|
||||
echo "Container Processes: $(ps -aux)"
|
||||
echo "Container Environment: $(env)"
|
||||
echo "Container Path: $(echo $PATH)"
|
||||
echo "Container Python: $(python --version)"
|
||||
} | tee -a debug.log
|
||||
|
||||
- name: "Network test 🔎"
|
||||
run: |
|
||||
{
|
||||
echo "curl -I http://example.com"
|
||||
curl -I http://example.com
|
||||
} | tee -a debug.log
|
||||
|
||||
- name: "Print current workflow user 🔎"
|
||||
run: |
|
||||
{
|
||||
echo "Workflow AllSpice user: ${{ github.actor }}"
|
||||
} | tee -a debug.log
|
||||
|
||||
- name: "[🔎->📂] List files in repo 🔎"
|
||||
run: |
|
||||
{
|
||||
ls -la .
|
||||
ls -la ${{ github.workspace }}
|
||||
} | tee -a debug.log
|
||||
|
||||
- name: List all environment variables 🔎
|
||||
run: |
|
||||
{
|
||||
echo "Listing all environment variables..."
|
||||
printenv | sort
|
||||
} | tee -a debug.log
|
||||
|
||||
# Installs python requirements from the requirements.txt file
|
||||
- name: "[🤼->🖥️] Install python requirements"
|
||||
run: |
|
||||
{
|
||||
pip install -r .allspice/utils/requirements.txt
|
||||
} | tee -a debug.log
|
||||
|
||||
# Call a python script from the .allspice/utils directory
|
||||
- name: "[🏃->🐍] Run .allspice/utils/hello-world.py 🔎"
|
||||
run: |
|
||||
{
|
||||
python .allspice/utils/hello-world.py
|
||||
} | tee -a debug.log
|
||||
|
||||
# Run the py-allspice self-test script, this will ping the server and verify the API is working
|
||||
# Parameters: ${github.server_url} and ${github.token} are automatic Workflow variables and are used to authenticate the AllSpice API
|
||||
- name: "[🔑->🕸️] Test AllSpice API with py-allspice 🔎"
|
||||
run: |
|
||||
{
|
||||
python .allspice/utils/py-allspice-BIST.py --allspice_hub_url ${{ github.server_url }} --allspice_token ${{ github.token }}
|
||||
} | tee -a debug.log
|
||||
|
||||
# Upload log file as an artifact
|
||||
- name: Upload debug log file as artifact
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: debug.log
|
||||
path: debug.log
|
Loading…
Reference in New Issue
Block a user