Skip to content

Commit

Permalink
Add
Browse files Browse the repository at this point in the history
  • Loading branch information
ishaansehgal99 committed Oct 16, 2023
1 parent 325b9fe commit 4017ead
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 7 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/preset-image-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,7 @@ jobs:
- name: 'Attach and Login to ACR'
id: acr_login
run: |
if [[ ${{ needs.setup.outputs.image_tag == 'latest'}} ]]; then
if [[ "${{ needs.setup.outputs.image_tag }}" == "latest" ]]; then
echo "ACR_NAME=aimodelsregistry" >> $GITHUB_OUTPUT
az aks update -n GitRunner -g llm-test --attach-acr aimodelsregistry
az acr login -n aimodelsregistry --expose-token
Expand Down Expand Up @@ -310,12 +310,15 @@ jobs:
POD_NAME=$(kubectl get pod -l app=docker -o=jsonpath='{.items[0].metadata.name}')
echo "POD_NAME=$POD_NAME" >> $GITHUB_OUTPUT
# - name: Place Dockerfile On Pod
# run: |
# DIRECTORY=$(dirname ${{ matrix.model.dockerfile }})
# kubectl exec ${{ steps.get_pod_name.outputs.POD_NAME }} -- mkdir -p /$DIRECTORY
# kubectl cp ${{ matrix.model.dockerfile }} ${{ steps.get_pod_name.outputs.POD_NAME }}:/${{ matrix.model.dockerfile }}

- name: Docker login
run: |
if [[ "${{ steps.acr_login.outputs.ACR_NAME }}" == "aimodelsregistry" ]]; then
kubectl exec ${{ steps.get_pod_name.outputs.POD_NAME }} -- \
docker login ${{ steps.acr_login.outputs.ACR_NAME }}.azurecr.io --username ${{ secrets.ACR_AMR_USERNAME }} --password ${{ secrets.ACR_AMR_PASSWORD }}
else
kubectl exec ${{ steps.get_pod_name.outputs.POD_NAME }} -- \
docker login ${{ steps.acr_login.outputs.ACR_NAME }}.azurecr.io --username ${{ secrets.ACR_AMRT_USERNAME }} --password ${{ secrets.ACR_AMRT_PASSWORD }}
fi
- name: Build model (with retries)
run: |
retries=3
Expand Down
6 changes: 6 additions & 0 deletions presets/k8s/docker.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -20,8 +20,14 @@ spec:
volumeMounts:
- name: host-volume
mountPath: /home
- name: llama-volume
mountPath: /home/llama
volumes:
- name: host-volume
hostPath:
path: /actions-runner/_work/kdm/kdm
type: Directory
- name: llama-volume
hostPath:
path: /llama
type: Directory

0 comments on commit 4017ead

Please sign in to comment.