diff --git a/.github/workflows/telepresence.yaml b/.github/workflows/telepresence.yaml new file mode 100644 index 00000000000..94c20e01a76 --- /dev/null +++ b/.github/workflows/telepresence.yaml @@ -0,0 +1,79 @@ +# +# Copyright (C) 2019-2023 vdaas.org vald team +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# You may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# https://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +name: "Telepresence test" +on: + push: + branches: + - main + paths: + - "go.mod" + - "go.sum" + - ".github/workflows/telepresence.yml" + - "internal/**" + - "pkg/**" + - "cmd/**" + pull_request: + paths: + - "go.mod" + - "go.sum" + - ".github/workflows/telepresence.yml" + - "internal/**" + - "pkg/**" + - "cmd/**" + +env: + DATASET: fashion-mnist-784-euclidean.hdf5 + +jobs: + telepresence: + name: "Try to deploy telepresence" + needs: [dump-contexts-to-log] + runs-on: ubuntu-latest + timeout-minutes: 60 + steps: + - uses: actions/checkout@v3 + + - name: Set Git config + run: | + git config --global --add safe.directory ${GITHUB_WORKSPACE} + + - name: Setup E2E environment + id: setup_e2e + uses: ./.github/actions/setup-e2e + + - name: Deploy Vald + id: deploy_vald + uses: ./.github/actions/e2e-deploy-vald + with: + helm_extra_options: ${{ steps.setup_e2e.outputs.HELM_EXTRA_OPTIONS }} + values: .github/helm/values/values-lb.yaml + wait_for_selector: app=vald-lb-gateway + + - name: Install telepresence + env: + TELEPRESENCE_VERSION: 2.15.1 + run: | + sudo curl -fL https://app.getambassador.io/download/tel2/linux/amd64/${TELEPRESENCE_VERSION}/telepresence -o /usr/local/bin/telepresence + sudo chmod a+x /usr/local/bin/telepresence + + - name: Deploy telepresence + run: telepresence helm install + + - name: Connect to telepresence + run: telepresence connect + + - name: Check if telepresence is working + run: curl vald-lb-gateway.default.svc.cluster.local:8081