fix: resolve TS error in seed.ts + use compose.deploy for CI
This commit is contained in:
@@ -33,8 +33,8 @@ jobs:
|
|||||||
steps:
|
steps:
|
||||||
- name: Deploy to Dokploy
|
- name: Deploy to Dokploy
|
||||||
run: |
|
run: |
|
||||||
curl -fsSL -X POST "${{ secrets.DOKPLOY_URL }}/api/application.deploy" \
|
curl -fsSL -X POST "${{ secrets.DOKPLOY_URL }}/api/compose.deploy" \
|
||||||
-H "Content-Type: application/json" \
|
-H "Content-Type: application/json" \
|
||||||
-H "x-api-key: ${{ secrets.DOKPLOY_API_TOKEN }}" \
|
-H "x-api-key: ${{ secrets.DOKPLOY_API_TOKEN }}" \
|
||||||
-d '{"applicationId": "${{ secrets.DOKPLOY_APP_ID }}"}'
|
-d '{"composeId": "${{ secrets.DOKPLOY_COMPOSE_ID }}"}'
|
||||||
echo "Deploy triggered on Dokploy"
|
echo "Deploy triggered on Dokploy"
|
||||||
|
|||||||
@@ -12,7 +12,7 @@ async function seed() {
|
|||||||
SELECT tablename FROM pg_tables WHERE schemaname = 'public'
|
SELECT tablename FROM pg_tables WHERE schemaname = 'public'
|
||||||
`);
|
`);
|
||||||
|
|
||||||
for (const row of tables.rows) {
|
for (const row of tables as any) {
|
||||||
const table = (row as any).tablename;
|
const table = (row as any).tablename;
|
||||||
if (table.startsWith('__drizzle') || table.startsWith('pgboss')) continue;
|
if (table.startsWith('__drizzle') || table.startsWith('pgboss')) continue;
|
||||||
console.log(` Truncating ${table}...`);
|
console.log(` Truncating ${table}...`);
|
||||||
|
|||||||
Reference in New Issue
Block a user