Skip to content

Add CD workflow.

Add CD workflow. #1

# Copyright (C) 2024 Intel Corporation
# SPDX-License-Identifier: Apache-2.0
name: Comps CD workflow on manual event
on:
pull_request:
branches: [main]
types: [opened, reopened, ready_for_review, synchronize]
workflow_dispatch:
inputs:
# nodes:
# default: "gaudi"
# description: "Hardware to run test"
# required: true
# type: string
service:
default: "asr"
description: "List of services to test [agent,asr,chathistory,dataprep,embeddings,guardrails,knowledgegraphs,llms,lvms,prompt_registry,ragas,reranks,retrievers,tts,vectorstores,web_retrievers]"
required: true
type: string
name:
default: "comps"
description: "List of names to test [_faq-generation,_ls tefastrag,_haystack,_langchain,_langchain-mosec,_llama,_llava,_milvus,_mongo,_pgvector,_pii,_pinecone,_qdrant,_redis,_registry,_retrievers,_summarization,_tei,_text-generation,_tgi]"
required: true
type: string
tag:
default: "comps"
description: "Tag to apply to images"
required: true
type: string
# build:
# default: true
# description: 'Build test required images for Comps'
# required: false
# type: boolean
# scan:
# default: true
# description: 'Scan all images with Trivy'
# required: false
# type: boolean
# test_compose:
# default: true
# description: 'Test services with docker compose'
# required: false
# type: boolean
# GenAIComps_branch:
# default: "main"
# description: 'GenAIComps branch for image build'
# required: false
# type: string
permissions: read-all
jobs:
get-test-matrix:
runs-on: ubuntu-latest
outputs:
services: ${{ steps.get-matrix.outputs.services }}
# nodes: ${{ steps.get-matrix.outputs.nodes }}
names: ${{ steps.get-matrix.outputs.names }}
steps:
- name: Create Matrix
id: get-matrix
run: |
services=($(echo ${{ inputs.services }} | tr ',' ' '))
echo "services=$services_json" >> $GITHUB_OUTPUT
# nodes=($(echo ${{ inputs.nodes }} | tr ',' ' '))
# echo "nodes=$nodes_json" >> $GITHUB_OUTPUT
names=($(echo ${{ inputs.names }} | tr ',' ' '))
echo "names=$names_json" >> $GITHUB_OUTPUT
run-services:
needs: [get-test-matrix]
strategy:
matrix:
service: ${{ fromJson(needs.get-test-matrix.outputs.services) }}
# node: ${{ fromJson(needs.get-test-matrix.outputs.nodes) }}
name: ${{ fromJson(needs.get-test-matrix.outputs.names }}
fail-fast: false
uses: ./.github/workflows/_example-workflow.yml

Check failure on line 79 in .github/workflows/manual-comps-workflow.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/manual-comps-workflow.yml

Invalid workflow file

error parsing called workflow ".github/workflows/manual-comps-workflow.yml" -> "./.github/workflows/_example-workflow.yml" : failed to fetch workflow: workflow was not found.
with:
service: ${{ matrix.service }}
name: ${{ matrix.name }}
tag: ${{ inputs.tag }}
# build: ${{ fromJSON(inputs.build) }}
# scan: ${{ fromJSON(inputs.scan) }}
# test_compose: ${{ fromJSON(inputs.test_compose) }}
# GenAIComps_branch: ${{ inputs.GenAIComps_branch }}
secrets: inherit