Skip to content

Commit

Permalink
Merge pull request #1270 from andrew-bierman/development
Browse files Browse the repository at this point in the history
Development
  • Loading branch information
taronaleksanian authored Oct 8, 2024
2 parents 8d15fb6 + ac97cd9 commit 3801370
Show file tree
Hide file tree
Showing 219 changed files with 10,469 additions and 2,846 deletions.
8 changes: 4 additions & 4 deletions .github/actions/deploy-cloudflare-worker/action.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'Print Wrangler Logs'
description: 'Prints Wrangler logs files if exist'
name: 'Deploy worker'
description: 'Deploys worker'
inputs:
WORKERS_AI_API_KEY:
description: 'The Workers AI API Key'
Expand All @@ -12,7 +12,7 @@ inputs:
required: true
BUCKET_SECRET_KEY:
description: 'The Bucket Secret Key'
requuired: true
required: true
GOOGLE_CLIENT_SECRET:
description: 'The Google client secret'
required: true
Expand Down Expand Up @@ -59,7 +59,7 @@ inputs:
runs:
using: 'composite'
steps:
- name: Deploy database
- name: Deploy worker
uses: cloudflare/[email protected]
with:
wranglerVersion: '3.75.0'
Expand Down
4 changes: 2 additions & 2 deletions .github/actions/migrate-d1-database/action.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
name: 'Print Wrangler Logs'
description: 'Prints Wrangler logs files if exist'
name: 'Migrate DB'
description: 'Applies DB migrations'
inputs:
CLOUDFLARE_API_TOKEN:
description: 'Cloudflare API Token'
Expand Down
Original file line number Diff line number Diff line change
@@ -1,52 +1,53 @@
name: "Generate Wrangler TOML"
description: "Generates the wrangler.toml file for Cloudflare Workers"
name: 'Generate Wrangler TOML and Dotenv File'
description: 'Generates wrangler.toml and .env files for Cloudflare Workers'
inputs:
APP_URL:
description: "The Application URL"
description: 'The Application URL'
required: true
AWS_SIGN_ALGORITHM:
description: "The AWS sign algorithm"
description: 'The AWS sign algorithm'
required: true
BUCKET_ENDPOINT:
description: "The bucket endpoint"
description: 'The bucket endpoint'
required: true
BUCKET_NAME:
description: "The bucket name"
description: 'The bucket name'
required: true
BUCKET_REGION:
description: "The bucket region"
description: 'The bucket region'
required: true
BUCKET_SERVICE:
description: "The bucket service"
description: 'The bucket service'
required: true
BUCKET_SESSION_TOKEN:
description: "The bucket session token"
description: 'The bucket session token'
required: true
environment:
description: "The current environment"
description: 'The current environment'
required: true
CLOUDFLARE_ACCOUNT_ID:
description: "Cloudflare Account ID"
description: 'Cloudflare Account ID'
required: true
DB_ID:
description: "The database ID"
description: 'The database ID'
required: true
GOOGLE_CLIENT_ID:
description: "Google Client ID"
description: 'Google Client ID'
required: true
STMP_EMAIL:
description: "SMTP Email"
description: 'SMTP Email'
required: true
VECTOR_INDEX_NAME:
description: "The vector index"
description: 'The vector index'
required: true
runs:
using: "composite"
using: 'composite'
steps:
- name: Generate wrangler.toml
- name: Generate wrangler.toml and .env
shell: bash
working-directory: ${{ github.workspace }}/server
run: |
echo 'NODE_ENV=development' > .env
echo 'name = "packrat-api"' > wrangler.toml
echo 'main = "src/index.ts"' >> wrangler.toml
echo 'compatibility_date = "2024-03-14"' >> wrangler.toml
Expand All @@ -56,11 +57,12 @@ runs:
echo 'binding = "DB"' >> wrangler.toml
echo 'database_name = "${{ inputs.environment }}"' >> wrangler.toml
echo 'database_id = "${{ inputs.DB_ID }}"' >> wrangler.toml
echo 'migrations_dir = "${{ inputs.MIGRATIONS_PATH }}"' >> wrangler.toml
echo '[[env.${{ inputs.environment }}.r2_buckets]]' >> wrangler.toml
echo 'binding = "GEOJSON_BUCKET"' >> wrangler.toml
echo 'bucket_name = "packrat-geojson-bucket-${{ inputs.environment }}"' >> wrangler.toml
echo '[env.${{ inputs.environment }}.ai]' >> wrangler.toml
echo 'binding = "AI"' >> wrangler.toml
echo '[[env.${{ inputs.environment }}.vectorize]]' >> wrangler.toml
echo 'binding = "VECTOR_INDEX"' >> wrangler.toml
echo 'index_name = "${{ inputs.VECTOR_INDEX_NAME }}"' >> wrangler.toml
echo '[env.${{ inputs.environment }}.vars]' >> wrangler.toml
echo 'APP_URL = "${{ inputs.APP_URL }}"' >> wrangler.toml
echo 'AWS_SIGN_ALGORITHM = "${{ inputs.AWS_SIGN_ALGORITHM }}"' >> wrangler.toml
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/backend-preview.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ on:
paths:
- '.github/workflows/backend-preview.yml'
- 'packages/validations/**'
- 'packages/shared-types/**'
- 'server/**'
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
Expand All @@ -29,8 +28,8 @@ jobs:
- name: Setup JS Runtime environment
uses: ./.github/actions/setup-js-runtime

- name: Generate wrangler.toml
uses: ./.github/actions/setup-wrangler-toml
- name: Generate wrangler.toml and .env
uses: ./.github/actions/setup-wrangler-toml-and-dotenv
with:
environment: preview
APP_URL: ${{ secrets.PREVIEW_APP_URL }}
Expand All @@ -42,6 +41,7 @@ jobs:
BUCKET_SESSION_TOKEN: ${{ secrets.PREVIEW_BUCKET_SESSION_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.PREVIEW_CLOUDFLARE_ACCOUNT_ID }}
DB_ID: ${{ secrets.PREVIEW_DB_ID }}
MIGRATIONS_PATH: migrations-preview
GOOGLE_CLIENT_ID: ${{ secrets.PREVIEW_GOOGLE_CLIENT_ID }}
STMP_EMAIL: ${{ secrets.PREVIEW_STMP_EMAIL }}
VECTOR_INDEX_NAME: ${{ secrets.PREVIEW_VECTOR_INDEX }}
Expand Down
7 changes: 3 additions & 4 deletions .github/workflows/backend.yml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ on:
paths:
- '.github/workflows/backend.yml'
- 'packages/validations/**'
- 'packages/shared-types/**'
- 'server/**'

concurrency:
Expand All @@ -31,8 +30,8 @@ jobs:
- name: Setup JS Runtime environment
uses: ./.github/actions/setup-js-runtime

- name: Generate wrangler.toml
uses: ./.github/actions/setup-wrangler-toml
- name: Generate wrangler.toml and .env
uses: ./.github/actions/setup-wrangler-toml-and-dotenv
with:
environment: production
APP_URL: ${{ secrets.APP_URL }}
Expand All @@ -44,6 +43,7 @@ jobs:
BUCKET_SESSION_TOKEN: ${{ secrets.BUCKET_SESSION_TOKEN }}
CLOUDFLARE_ACCOUNT_ID: ${{ secrets.CLOUDFLARE_ACCOUNT_ID }}
DB_ID: ${{ secrets.PRODUCTION_DB_ID }}
MIGRATIONS_PATH: migrations
GOOGLE_CLIENT_ID: ${{ secrets.GOOGLE_CLIENT_ID }}
STMP_EMAIL: ${{ secrets.STMP_EMAIL }}
VECTOR_INDEX_NAME: ${{ secrets.VECTOR_INDEX }}
Expand Down Expand Up @@ -75,4 +75,3 @@ jobs:
VECTORIZE_API_KEY: ${{ secrets.VECTORIZE_API_KEY }}
WORKERS_AI_API_KEY: ${{ secrets.WORKERS_AI_API_KEY }}
X_AMZ_SECURITY_TOKEN: ${{ secrets.X_AMZ_SECURITY_TOKEN }}

1 change: 0 additions & 1 deletion .github/workflows/eas-cloud.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ on:
- 'packages/app/**'
- 'apps/expo/**'
- 'packages/ui/**'
- 'packages/shared-types/**'
- 'packages/config/**'
- 'packages/crosspath/**'

Expand Down
2 changes: 0 additions & 2 deletions .github/workflows/eas-local.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ on:
- 'packages/app/**'
- 'apps/expo/**'
- 'packages/ui/**'
- 'packages/shared-types/**'
- 'packages/config/**'
- 'packages/crosspath/**'
pull_request:
Expand All @@ -17,7 +16,6 @@ on:
- 'packages/app/**'
- 'apps/expo/**'
- 'packages/ui/**'
- 'packages/shared-types/**'
- 'packages/config/**'
- 'packages/crosspath/**'

Expand Down
2 changes: 1 addition & 1 deletion apps/expo/app/(app)/(drawer)/(tabs)/(stack)/map/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ export default function FeedNav() {
// https://reactnavigation.org/docs/headers#replacing-the-title-with-a-custom-component
}}
/>
<Map />
<OfflineMapsScreen />

Check failure on line 24 in apps/expo/app/(app)/(drawer)/(tabs)/(stack)/map/index.tsx

View workflow job for this annotation

GitHub Actions / build (macos-latest, 20.x)

'OfflineMapsScreen' is not defined

Check failure on line 24 in apps/expo/app/(app)/(drawer)/(tabs)/(stack)/map/index.tsx

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 20.x)

'OfflineMapsScreen' is not defined

Check failure on line 24 in apps/expo/app/(app)/(drawer)/(tabs)/(stack)/map/index.tsx

View workflow job for this annotation

GitHub Actions / build (ubuntu-latest, 20.x)

'OfflineMapsScreen' is not defined

Check failure on line 24 in apps/expo/app/(app)/(drawer)/(tabs)/(stack)/map/index.tsx

View workflow job for this annotation

GitHub Actions / build (windows-latest, 20.x)

'OfflineMapsScreen' is not defined

Check failure on line 24 in apps/expo/app/(app)/(drawer)/(tabs)/(stack)/map/index.tsx

View workflow job for this annotation

GitHub Actions / build (windows-latest, 20.x)

'OfflineMapsScreen' is not defined
</>
);
}
4 changes: 2 additions & 2 deletions apps/expo/app/(app)/(drawer)/(tabs)/(stack)/maps/index.tsx
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
import React from 'react';
import Maps from 'app/screens/maps';
import { OfflineMapsScreen } from 'app/modules/map/screens/OfflineMapsScreen';
import { Platform } from 'react-native';
import { Stack } from 'expo-router';
import Head from 'expo-router/head';
Expand Down Expand Up @@ -36,7 +36,7 @@ export default function MapsScreen() {
// https://reactnavigation.org/docs/headers#replacing-the-title-with-a-custom-component
}}
/>
<Maps />
<OfflineMapsScreen />
</>
);
}
Loading

0 comments on commit 3801370

Please sign in to comment.