Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions action.yml
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,10 @@ inputs:
description: 'Secrets to use'
required: false
default: ''
config_file_path:
description: 'Path to config file'
required: false
default: null
runs:
using: 'docker'
image: 'Dockerfile'
Expand All @@ -58,3 +62,4 @@ runs:
- ${{ inputs.token }}
- ${{ inputs.session_id }}
- ${{ inputs.secrets }}
- ${{ inputs.config_file_path }}
22 changes: 13 additions & 9 deletions entrypoint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,16 +22,20 @@ for secret in $secrets; do
secrets_flags="$secrets_flags --secret $secret"
done

if [ -n "$2" ]; then
if [ -n "$7" ]; then
tensorkube deploy --gpus $1 --gpu-type $2 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --env $7 --github-actions $secrets_flags
else
tensorkube deploy --gpus $1 --gpu-type $2 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --github-actions $secrets_flags
fi
if [ -n "${12}" ]; then
tensorkube deploy --config-file ${12}
else
if [ -n "$7" ]; then
tensorkube deploy --gpus $1 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --env $7 --github-actions $secrets_flags
if [ -n "$2" ]; then
if [ -n "$7" ]; then
tensorkube deploy --gpus $1 --gpu-type $2 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --env $7 --github-actions $secrets_flags
else
tensorkube deploy --gpus $1 --gpu-type $2 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --github-actions $secrets_flags
fi
else
tensorkube deploy --gpus $1 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --github-actions $secrets_flags
if [ -n "$7" ]; then
tensorkube deploy --gpus $1 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --env $7 --github-actions $secrets_flags
else
tensorkube deploy --gpus $1 --cpu $3 --memory $4 --min-scale $5 --max-scale $6 --github-actions $secrets_flags
fi
fi
fi