Skip to content

Commit

Permalink
fix: script to re-add all dkim entries
Browse files Browse the repository at this point in the history
  • Loading branch information
javiersuweijie committed Oct 16, 2024
1 parent 9b79095 commit d51a1f4
Showing 1 changed file with 15 additions and 6 deletions.
21 changes: 15 additions & 6 deletions packages/app/src/scripts/write_dkim_entry.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,19 @@
import { addDkimEntry } from "@/lib/contract-deploy"
import { addDkimEntry } from "@/lib/contract-deploy";
import { prisma } from "@/lib/prisma";

(async () => {
await addDkimEntry({
parameters: {
senderDomain: 'github.com',
dkimSelector: 'pf2023'
const entries = await prisma.entry.findMany({
where: {
status: "COMPLETED",
withModal: true,
}
} as any)
});
for (const entry of entries) {
console.log("Adding DKIM entry for entry: ", entry.slug)
try {
await addDkimEntry(entry)
} catch {
console.log("Error adding DKIM entry for: ", entry.slug);
}
}
})()

0 comments on commit d51a1f4

Please sign in to comment.