-
Notifications
You must be signed in to change notification settings - Fork 29
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
merge origin main, 0.12.2 registry1 published
- Loading branch information
1 parent
36d9854
commit 2893f7c
Showing
1 changed file
with
42 additions
and
9 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -57,7 +57,7 @@ jobs: | |
- name: Create UDS Cluster | ||
shell: bash | ||
run: | | ||
make create-uds-cpu-cluster | ||
UDS_CONFIG=.github/config/uds-config.yaml make create-uds-cpu-cluster | ||
- name: Setup Playwright | ||
run: | | ||
|
@@ -81,7 +81,7 @@ jobs: | |
run: | | ||
cd bundles/latest/cpu | ||
uds create . --confirm && \ | ||
uds deploy --set DISABLE_KEYCLOAK=true uds-bundle-leapfrogai-amd64-registry1.tar.zst --confirm --no-progress && \ | ||
uds deploy uds-bundle-leapfrogai-amd64-registry1.tar.zst --confirm --no-progress && \ | ||
rm -rf uds-bundle-leapfrogai-amd64-registry1.tar.zst && \ | ||
docker system prune -af | ||
|
@@ -91,29 +91,62 @@ jobs: | |
ANON_KEY=$(uds zarf tools kubectl get secret supabase-bootstrap-jwt -n leapfrogai -o jsonpath='{.data.anon-key}' | base64 -d) | ||
echo "::add-mask::$ANON_KEY" | ||
echo "ANON_KEY=$ANON_KEY" >> $GITHUB_OUTPUT | ||
FAKE_PASSWORD=$(cat <(openssl rand -base64 32 | tr -dc 'a-zA-Z0-9!@#$%^&*()_+-=[]{}|;:,.<>?' | head -c 20) <(echo '!@1Aa') | fold -w1 | shuf | tr -d '\n') | ||
echo "::add-mask::$FAKE_PASSWORD" | ||
echo "FAKE_PASSWORD=$FAKE_PASSWORD" >> $GITHUB_OUTPUT | ||
SERVICE_KEY=$(uds zarf tools kubectl get secret -n leapfrogai supabase-bootstrap-jwt -o jsonpath={.data.service-key} | base64 -d) | ||
echo "::add-mask::$SERVICE_KEY" | ||
echo "SERVICE_KEY=$SERVICE_KEY" >> $GITHUB_OUTPUT | ||
- name: Verify Secrets | ||
run: | | ||
echo "FAKE_PASSWORD is set: ${{ steps.generate_secrets.outputs.FAKE_PASSWORD != '' }}" | ||
echo "ANON_KEY is set: ${{ steps.generate_secrets.outputs.ANON_KEY != '' }}" | ||
echo "SERVICE_KEY is set: ${{ steps.generate_secrets.outputs.SERVICE_KEY != '' }}" | ||
# TODO: enable for post-0.12.2 release of LeapfrogAI | ||
# - name: Run Integration Tests | ||
# if: github.sha == 'YOUR_SPECIFIC_COMMIT_SHA' | ||
# env: | ||
# SUPABASE_ANON_KEY: ${{ steps.generate_secrets.outputs.ANON_KEY }} | ||
# SUPABASE_PASS: ${{ steps.generate_secrets.outputs.FAKE_PASSWORD }} | ||
# SUPABASE_EMAIL: [email protected] | ||
# SUPABASE_URL: https://supabase-kong.uds.dev | ||
# # Turn off NIAH tests that are not applicable for integration testing using the Repeater model | ||
# LFAI_RUN_NIAH_TESTS: "false" | ||
# run: | | ||
# uds zarf connect --name=llama-cpp-python-model --namespace=leapfrogai --local-port=50051 --remote-port=50051 & | ||
# while ! nc -z localhost 50051; do sleep 1; done | ||
|
||
# make test-user-pipeline | ||
# env $(cat .env | xargs) python -m pytest -v -s tests/integration/api | ||
|
||
# Backends | ||
- name: Run Backend Tests | ||
- name: Run Backend E2E Tests | ||
env: | ||
ANON_KEY: ${{ steps.generate_secrets.outputs.ANON_KEY }} | ||
SERVICE_KEY: ${{ steps.generate_secrets.outputs.SERVICE_KEY }} | ||
run: | | ||
python -m pytest ./tests/e2e/test_llama.py -v | ||
python -m pytest ./tests/e2e/test_text_embeddings.py -v | ||
python -m pytest ./tests/e2e/test_whisper.py -v | ||
python -m pytest ./tests/e2e/test_supabase.py -v | ||
python -m pytest ./tests/e2e/test_api.py -v | ||
python -m pytest ./tests/e2e/test_llama.py -vv | ||
python -m pytest ./tests/e2e/test_text_embeddings.py -vv | ||
python -m pytest ./tests/e2e/test_whisper.py -vv | ||
python -m pytest ./tests/e2e/test_supabase.py -vv | ||
python -m pytest ./tests/e2e/test_api.py -vv | ||
- name: Run Playwright E2E Tests | ||
env: | ||
SERVICE_ROLE_KEY: ${{ steps.generate_secrets.outputs.SERVICE_KEY }} | ||
FAKE_E2E_USER_PASSWORD: ${{ steps.generate_secrets.outputs.FAKE_PASSWORD }} | ||
ANON_KEY: ${{ steps.generate_secrets.outputs.ANON_KEY }} | ||
run: | | ||
chmod +x ./.github/scripts/createUser.sh | ||
./.github/scripts/createUser.sh | ||
cp src/leapfrogai_ui/.env.example src/leapfrogai_ui/.env | ||
mkdir -p playwright/auth | ||
touch playwright/auth.user.json | ||
TEST_ENV=CI PUBLIC_DISABLE_KEYCLOAK=true PUBLIC_SUPABASE_ANON_KEY=$ANON_KEY npm --prefix src/leapfrogai_ui run test:integration:ci | ||
SERVICE_ROLE_KEY=$SERVICE_ROLE_KEY TEST_ENV=CI USERNAME=doug PASSWORD=$FAKE_E2E_USER_PASSWORD PUBLIC_SUPABASE_ANON_KEY=$ANON_KEY npm --prefix src/leapfrogai_ui run test:integration:ci | ||
- name: Archive Playwright Report | ||
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4.3.6 | ||
|