Skip to content

Commit

Permalink
Feature/update apps to work with latest civic auth versions (#24)
Browse files Browse the repository at this point in the history
* update all apps to work with latest civic auth versions
  • Loading branch information
mitchcivic authored Feb 28, 2025
1 parent 47e74fd commit 34d24e8
Show file tree
Hide file tree
Showing 14 changed files with 56 additions and 3,240 deletions.
36 changes: 23 additions & 13 deletions .github/workflows/e2e-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ jobs:

- name: Install dependencies
shell: bash
run: yarn install --frozen-lockfile
run: yarn install

- name: Build
run: yarn build
Expand All @@ -96,7 +96,7 @@ jobs:
with:
run: yarn dev &
working-directory: packages/civic-auth/reactjs
wait-on: http://localhost:3006
wait-on: http://localhost:3001
wait-for: 60s
log-output-if: true

Expand All @@ -105,7 +105,7 @@ jobs:
with:
run: yarn dev &
working-directory: packages/civic-auth/server/express
wait-on: http://localhost:3007
wait-on: http://localhost:3002
wait-for: 60s
log-output-if: true

Expand All @@ -114,23 +114,32 @@ jobs:
with:
run: yarn dev &
working-directory: packages/civic-auth/server/fastify
wait-on: http://localhost:3008
wait-on: http://localhost:3003
wait-for: 60s
log-output-if: true

- name: Start the hono example app
working-directory: ./packages/civic-auth/server/hono
run: |
bun add @hono/node-server
yarn dev & npx wait-on http://localhost:3009
yarn dev & npx wait-on http://localhost:3004
timeout-minutes: 1

- name: Start the wagmi example app
uses: JarvusInnovations/[email protected]
with:
run: yarn dev &
working-directory: packages/civic-auth-web3/wagmi
wait-on: http://localhost:3010
wait-on: http://localhost:3005
wait-for: 60s
log-output-if: true

- name: Start the solana example app
uses: JarvusInnovations/[email protected]
with:
run: yarn dev &
working-directory: packages/civic-auth-web3/solana
wait-on: http://localhost:3006
wait-for: 60s
log-output-if: true

Expand All @@ -142,16 +151,17 @@ jobs:
command: yarn cypress run --browser chrome --record
browser: chrome
install: true
wait-on: 'http://localhost:3000,http://localhost:3006,http://localhost:3007,http://localhost:3008,http://localhost:3009'
wait-on: 'http://localhost:3000,http://localhost:3001,http://localhost:3002,http://localhost:3003,http://localhost:3004,http://localhost:3005,http://localhost:3006'
wait-on-timeout: 60
record: true
env:
NEXT_JS_BASE_URL: 'http://localhost:3000'
REACT_BASE_URL: 'http://localhost:3006'
EXPRESS_BASE_URL: 'http://localhost:3007'
FASTIFY_BASE_URL: 'http://localhost:3008'
HONO_BASE_URL: 'http://localhost:3009'
WAGMI_BASE_URL: 'http://localhost:3010'
REACT_BASE_URL: 'http://localhost:3001'
EXPRESS_BASE_URL: 'http://localhost:3002'
FASTIFY_BASE_URL: 'http://localhost:3003'
HONO_BASE_URL: 'http://localhost:3004'
WAGMI_BASE_URL: 'http://localhost:3005'
SOLANA_BASE_URL: 'http://localhost:3006'
CYPRESS_TEST_TAG: '@prod'
CYPRESS_RECORD_KEY: ${{ secrets.CYPRESS_RECORD_KEY }}

Expand All @@ -161,7 +171,7 @@ jobs:
with:
payload: |
{
"channel": "#dev",
"channel": "#build",
"text": "Example repo Cypress tests failed in civicteam/civic-auth-examples.\n\nThese tests are run after new beta and prod versions of civic/auth and civic/auth-web3, so there may be an issue with the new version(s). Check the recording of the test failure here https://cloud.cypress.io/projects/cmyigw/runs.\n\n Alternatively, see the full GitHub Actions run details here ${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }}.",
}
env:
Expand Down
2 changes: 1 addition & 1 deletion packages/civic-auth-web3/solana/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "0.0.1",
"type": "module",
"scripts": {
"dev": "vite --port 3011",
"dev": "vite --port 3006",
"lint": "biome check .",
"preview": "vite preview"
},
Expand Down
2 changes: 1 addition & 1 deletion packages/civic-auth-web3/wagmi/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"version": "0.0.1",
"type": "module",
"scripts": {
"dev": "vite --port 3010",
"dev": "vite --port 3005",
"lint": "biome check .",
"preview": "vite preview"
},
Expand Down
3 changes: 1 addition & 2 deletions packages/civic-auth/nextjs/next.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,7 @@ const nextConfig: NextConfig = {
/* config options here */
};
const withCivicAuth = createCivicAuthPlugin({
clientId: `${process.env.CLIENT_ID}`,
oauthServer: `${process.env.AUTH_SERVER}`,
clientId: `${process.env.CLIENT_ID}`
});

export default withCivicAuth(nextConfig);
Loading

0 comments on commit 34d24e8

Please sign in to comment.