mirror of
https://github.com/hex248/sprint.git
synced 2026-02-07 18:23:03 +00:00
emailVerified for seeded data
This commit is contained in:
@@ -10,7 +10,7 @@ S3_PUBLIC_URL=https://images.sprintpm.org
|
|||||||
S3_ENDPOINT=https://account_id.r2.cloudflarestorage.com/sprint
|
S3_ENDPOINT=https://account_id.r2.cloudflarestorage.com/sprint
|
||||||
S3_ACCESS_KEY_ID=your_access_key_id
|
S3_ACCESS_KEY_ID=your_access_key_id
|
||||||
S3_SECRET_ACCESS_KEY=your_secret_access_key
|
S3_SECRET_ACCESS_KEY=your_secret_access_key
|
||||||
S3_BUCKET_NAME=issue
|
S3_BUCKET_NAME=sprint
|
||||||
|
|
||||||
STRIPE_PUBLISHABLE_KEY=your_stripe_publishable_key
|
STRIPE_PUBLISHABLE_KEY=your_stripe_publishable_key
|
||||||
STRIPE_SECRET_KEY=your_stripe_secret_key
|
STRIPE_SECRET_KEY=your_stripe_secret_key
|
||||||
|
|||||||
@@ -103,16 +103,81 @@ if (!SEED_PASSWORD) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const passwordHash = await hashPassword(SEED_PASSWORD);
|
const passwordHash = await hashPassword(SEED_PASSWORD);
|
||||||
|
const now = new Date();
|
||||||
const users = [
|
const users = [
|
||||||
{ name: "demo user 1", username: "demo1", email: "demo1@example.com", passwordHash, avatarURL: null },
|
{
|
||||||
{ name: "demo user 2", username: "demo2", email: "demo2@example.com", passwordHash, avatarURL: null },
|
name: "demo user 1",
|
||||||
|
username: "demo1",
|
||||||
|
email: "demo1@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "demo user 2",
|
||||||
|
username: "demo2",
|
||||||
|
email: "demo2@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
// anything past here is just to have more users to assign issues to
|
// anything past here is just to have more users to assign issues to
|
||||||
{ name: "demo user 3", username: "demo3", email: "demo3@example.com", passwordHash, avatarURL: null },
|
{
|
||||||
{ name: "demo user 4", username: "demo4", email: "demo4@example.com", passwordHash, avatarURL: null },
|
name: "demo user 3",
|
||||||
{ name: "demo user 5", username: "demo5", email: "demo5@example.com", passwordHash, avatarURL: null },
|
username: "demo3",
|
||||||
{ name: "demo user 6", username: "demo6", email: "demo6@example.com", passwordHash, avatarURL: null },
|
email: "demo3@example.com",
|
||||||
{ name: "demo user 7", username: "demo7", email: "demo7@example.com", passwordHash, avatarURL: null },
|
passwordHash,
|
||||||
{ name: "demo user 8", username: "demo8", email: "demo8@example.com", passwordHash, avatarURL: null },
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "demo user 4",
|
||||||
|
username: "demo4",
|
||||||
|
email: "demo4@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "demo user 5",
|
||||||
|
username: "demo5",
|
||||||
|
email: "demo5@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "demo user 6",
|
||||||
|
username: "demo6",
|
||||||
|
email: "demo6@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "demo user 7",
|
||||||
|
username: "demo7",
|
||||||
|
email: "demo7@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
|
{
|
||||||
|
name: "demo user 8",
|
||||||
|
username: "demo8",
|
||||||
|
email: "demo8@example.com",
|
||||||
|
passwordHash,
|
||||||
|
avatarURL: null,
|
||||||
|
emailVerified: true,
|
||||||
|
emailVerifiedAt: now,
|
||||||
|
},
|
||||||
];
|
];
|
||||||
|
|
||||||
async function seed() {
|
async function seed() {
|
||||||
|
|||||||
Reference in New Issue
Block a user