feat: tunnel and proxy use dev mode always (#388) #839
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
name: E2E Tests | |
on: | |
workflow_dispatch: | |
pull_request: | |
push: | |
branches: | |
- main | |
- master | |
jobs: | |
test-tunnel: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-go@v2 | |
with: | |
go-version: "1.22" | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: "16" | |
- run: | | |
go build -o ory . | |
./ory tunnel http://localhost:4001 --quiet & | |
env: | |
ORY_PROJECT_API_KEY: ${{ secrets.ORY_PROJECT_API_KEY }} | |
- name: Install dependencies | |
working-directory: cmd/cloudx/e2e | |
run: | | |
npm ci | |
- name: Run tests | |
working-directory: cmd/cloudx/e2e | |
run: | | |
npm run server & | |
docker run \ | |
-e HYDRA_ADMIN_URL=https://admiring-tu-swczqlujc0.projects.oryapis.com \ | |
-e ORY_API_KEY="${{ secrets.ORY_PROJECT_API_KEY }}" \ | |
-p 4445:3000 -d \ | |
--name hydra-ui \ | |
docker.io/oryd/hydra-login-consent-node:v2.0.0-alpha.0.pre.2 | |
npm run test | |
env: | |
CYPRESS_RECORD_KEY: e8bf86fe-6605-4112-af1d-c3a2f052d4f8 | |
CYPRESS_IS_TUNNEL: 1 | |
- if: ${{ failure() }} | |
run: | | |
docker ps -a | |
docker logs hydra-ui | |
curl -v http://localhost:4445 | |
test-proxy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: actions/setup-go@v2 | |
with: | |
go-version: "1.22" | |
- uses: actions/setup-node@v2 | |
with: | |
node-version: "16" | |
- run: | | |
go build -o ory . | |
./ory proxy https://ory-network-httpbin-ijakee5waq-ez.a.run.app/anything --rewrite-host --quiet & | |
env: | |
ORY_PROJECT_API_KEY: ${{ secrets.ORY_PROJECT_API_KEY }} | |
- name: Install Node | |
working-directory: cmd/cloudx/e2e | |
run: | | |
npm ci | |
- working-directory: cmd/cloudx/e2e | |
run: | | |
docker run \ | |
-e HYDRA_ADMIN_URL=https://admiring-tu-swczqlujc0.projects.oryapis.com \ | |
-e ORY_API_KEY="${{ secrets.ORY_PROJECT_API_KEY }}" \ | |
-p 4445:3000 -d \ | |
--name hydra-ui \ | |
docker.io/oryd/hydra-login-consent-node:v2.0.0-alpha.0.pre.2 | |
npm run test | |
env: | |
CYPRESS_RECORD_KEY: e8bf86fe-6605-4112-af1d-c3a2f052d4f8 | |
- if: ${{ failure() }} | |
run: | | |
docker ps -a | |
docker logs hydra-ui | |
curl -v http://localhost:4445 |