17#pragma warning disable 612, 618
19 .HasAnnotation(
"ProductVersion",
"7.0.7")
20 .HasAnnotation(
"Relational:MaxIdentifierLength", 64);
22 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
24 b.Property<
long?>(
"Id")
25 .ValueGeneratedOnAdd()
26 .HasColumnType(
"bigint");
28 b.Property<ushort?>(
"ChannelLimit")
30 .HasColumnType(
"smallint unsigned");
32 b.Property<
string>(
"ConnectionString")
35 .HasColumnType(
"longtext");
37 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"ConnectionString"),
"utf8mb4");
39 b.Property<
bool?>(
"Enabled")
40 .HasColumnType(
"tinyint(1)");
42 b.Property<
long>(
"InstanceId")
43 .HasColumnType(
"bigint");
45 b.Property<
string>(
"Name")
48 .HasColumnType(
"varchar(100)");
50 b.Property<
int>(
"Provider")
51 .HasColumnType(
"int");
53 b.Property<uint?>(
"ReconnectionInterval")
55 .HasColumnType(
"int unsigned");
59 b.HasIndex(
"InstanceId",
"Name")
62 b.ToTable(
"ChatBots");
65 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
67 b.Property<
long>(
"Id")
68 .ValueGeneratedOnAdd()
69 .HasColumnType(
"bigint");
71 b.Property<
long>(
"ChatSettingsId")
72 .HasColumnType(
"bigint");
74 b.Property<ulong?>(
"DiscordChannelId")
75 .HasColumnType(
"bigint unsigned");
77 b.Property<
string>(
"IrcChannel")
79 .HasColumnType(
"varchar(100)");
81 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"IrcChannel"),
"utf8mb4");
83 b.Property<
bool?>(
"IsAdminChannel")
85 .HasColumnType(
"tinyint(1)");
87 b.Property<
bool?>(
"IsSystemChannel")
89 .HasColumnType(
"tinyint(1)");
91 b.Property<
bool?>(
"IsUpdatesChannel")
93 .HasColumnType(
"tinyint(1)");
95 b.Property<
bool?>(
"IsWatchdogChannel")
97 .HasColumnType(
"tinyint(1)");
99 b.Property<
string>(
"Tag")
101 .HasColumnType(
"longtext");
103 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Tag"),
"utf8mb4");
107 b.HasIndex(
"ChatSettingsId",
"DiscordChannelId")
110 b.HasIndex(
"ChatSettingsId",
"IrcChannel")
113 b.ToTable(
"ChatChannels");
116 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
118 b.Property<
long?>(
"Id")
119 .ValueGeneratedOnAdd()
120 .HasColumnType(
"bigint");
122 b.Property<
string>(
"ByondVersion")
124 .HasColumnType(
"longtext");
126 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"ByondVersion"),
"utf8mb4");
128 b.Property<
int?>(
"DMApiMajorVersion")
129 .HasColumnType(
"int");
131 b.Property<
int?>(
"DMApiMinorVersion")
132 .HasColumnType(
"int");
134 b.Property<
int?>(
"DMApiPatchVersion")
135 .HasColumnType(
"int");
137 b.Property<Guid?>(
"DirectoryName")
139 .HasColumnType(
"char(36)");
141 b.Property<
string>(
"DmeName")
143 .HasColumnType(
"longtext");
145 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"DmeName"),
"utf8mb4");
147 b.Property<
int?>(
"GitHubDeploymentId")
148 .HasColumnType(
"int");
150 b.Property<
long?>(
"GitHubRepoId")
151 .HasColumnType(
"bigint");
153 b.Property<
long>(
"JobId")
154 .HasColumnType(
"bigint");
156 b.Property<
int?>(
"MinimumSecurityLevel")
157 .HasColumnType(
"int");
159 b.Property<
string>(
"Output")
161 .HasColumnType(
"longtext");
163 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Output"),
"utf8mb4");
165 b.Property<
string>(
"RepositoryOrigin")
166 .HasColumnType(
"longtext");
168 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"RepositoryOrigin"),
"utf8mb4");
170 b.Property<
long>(
"RevisionInformationId")
171 .HasColumnType(
"bigint");
175 b.HasIndex(
"DirectoryName");
180 b.HasIndex(
"RevisionInformationId");
182 b.ToTable(
"CompileJobs");
185 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
187 b.Property<
long>(
"Id")
188 .ValueGeneratedOnAdd()
189 .HasColumnType(
"bigint");
191 b.Property<
string>(
"AdditionalParameters")
194 .HasColumnType(
"longtext");
196 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"AdditionalParameters"),
"utf8mb4");
198 b.Property<
bool?>(
"AllowWebClient")
200 .HasColumnType(
"tinyint(1)");
202 b.Property<
bool?>(
"AutoStart")
204 .HasColumnType(
"tinyint(1)");
206 b.Property<
bool?>(
"DumpOnHeartbeatRestart")
208 .HasColumnType(
"tinyint(1)")
209 .HasColumnName(
"DumpOnHealthCheckRestart");
211 b.Property<uint?>(
"HeartbeatSeconds")
213 .HasColumnType(
"int unsigned")
214 .HasColumnName(
"HealthCheckSeconds");
216 b.Property<
long>(
"InstanceId")
217 .HasColumnType(
"bigint");
219 b.Property<
bool?>(
"LogOutput")
221 .HasColumnType(
"tinyint(1)");
223 b.Property<ushort?>(
"Port")
225 .HasColumnType(
"smallint unsigned");
227 b.Property<
int>(
"SecurityLevel")
228 .HasColumnType(
"int");
230 b.Property<
bool?>(
"StartProfiler")
232 .HasColumnType(
"tinyint(1)");
234 b.Property<uint?>(
"StartupTimeout")
236 .HasColumnType(
"int unsigned");
238 b.Property<uint?>(
"TopicRequestTimeout")
240 .HasColumnType(
"int unsigned");
242 b.Property<
int>(
"Visibility")
243 .HasColumnType(
"int");
247 b.HasIndex(
"InstanceId")
250 b.ToTable(
"DreamDaemonSettings");
253 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
255 b.Property<
long>(
"Id")
256 .ValueGeneratedOnAdd()
257 .HasColumnType(
"bigint");
259 b.Property<ushort?>(
"ApiValidationPort")
261 .HasColumnType(
"smallint unsigned");
263 b.Property<
int>(
"ApiValidationSecurityLevel")
264 .HasColumnType(
"int");
266 b.Property<
long>(
"InstanceId")
267 .HasColumnType(
"bigint");
269 b.Property<
string>(
"ProjectName")
271 .HasColumnType(
"longtext");
273 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"ProjectName"),
"utf8mb4");
275 b.Property<
bool?>(
"RequireDMApiValidation")
277 .HasColumnType(
"tinyint(1)");
279 b.Property<TimeSpan?>(
"Timeout")
281 .HasColumnType(
"time(6)");
285 b.HasIndex(
"InstanceId")
288 b.ToTable(
"DreamMakerSettings");
291 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
293 b.Property<
long?>(
"Id")
294 .ValueGeneratedOnAdd()
295 .HasColumnType(
"bigint");
297 b.Property<uint?>(
"AutoUpdateInterval")
299 .HasColumnType(
"int unsigned");
301 b.Property<ushort?>(
"ChatBotLimit")
303 .HasColumnType(
"smallint unsigned");
305 b.Property<
int>(
"ConfigurationType")
306 .HasColumnType(
"int");
308 b.Property<
string>(
"Name")
311 .HasColumnType(
"varchar(100)");
313 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Name"),
"utf8mb4");
315 b.Property<
bool?>(
"Online")
317 .HasColumnType(
"tinyint(1)");
319 b.Property<
string>(
"Path")
321 .HasColumnType(
"varchar(255)");
323 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Path"),
"utf8mb4");
325 b.Property<
string>(
"SwarmIdentifer")
326 .HasColumnType(
"varchar(255)");
328 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"SwarmIdentifer"),
"utf8mb4");
332 b.HasIndex(
"Path",
"SwarmIdentifer")
335 b.ToTable(
"Instances");
338 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
340 b.Property<
long>(
"Id")
341 .ValueGeneratedOnAdd()
342 .HasColumnType(
"bigint");
344 b.Property<ulong>(
"ByondRights")
345 .HasColumnType(
"bigint unsigned");
347 b.Property<ulong>(
"ChatBotRights")
348 .HasColumnType(
"bigint unsigned");
350 b.Property<ulong>(
"ConfigurationRights")
351 .HasColumnType(
"bigint unsigned");
353 b.Property<ulong>(
"DreamDaemonRights")
354 .HasColumnType(
"bigint unsigned");
356 b.Property<ulong>(
"DreamMakerRights")
357 .HasColumnType(
"bigint unsigned");
359 b.Property<
long>(
"InstanceId")
360 .HasColumnType(
"bigint");
362 b.Property<ulong>(
"InstancePermissionSetRights")
363 .HasColumnType(
"bigint unsigned");
365 b.Property<
long>(
"PermissionSetId")
366 .HasColumnType(
"bigint");
368 b.Property<ulong>(
"RepositoryRights")
369 .HasColumnType(
"bigint unsigned");
373 b.HasIndex(
"InstanceId");
375 b.HasIndex(
"PermissionSetId",
"InstanceId")
378 b.ToTable(
"InstancePermissionSets");
381 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
383 b.Property<
long?>(
"Id")
384 .ValueGeneratedOnAdd()
385 .HasColumnType(
"bigint");
387 b.Property<ulong?>(
"CancelRight")
388 .HasColumnType(
"bigint unsigned");
390 b.Property<ulong?>(
"CancelRightsType")
391 .HasColumnType(
"bigint unsigned");
393 b.Property<
bool?>(
"Cancelled")
395 .HasColumnType(
"tinyint(1)");
397 b.Property<
long?>(
"CancelledById")
398 .HasColumnType(
"bigint");
400 b.Property<
string>(
"Description")
402 .HasColumnType(
"longtext");
404 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Description"),
"utf8mb4");
406 b.Property<uint?>(
"ErrorCode")
407 .HasColumnType(
"int unsigned");
409 b.Property<
string>(
"ExceptionDetails")
410 .HasColumnType(
"longtext");
412 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"ExceptionDetails"),
"utf8mb4");
414 b.Property<
long>(
"InstanceId")
415 .HasColumnType(
"bigint");
417 b.Property<DateTimeOffset?>(
"StartedAt")
419 .HasColumnType(
"datetime(6)");
421 b.Property<
long>(
"StartedById")
422 .HasColumnType(
"bigint");
424 b.Property<DateTimeOffset?>(
"StoppedAt")
425 .HasColumnType(
"datetime(6)");
429 b.HasIndex(
"CancelledById");
431 b.HasIndex(
"InstanceId");
433 b.HasIndex(
"StartedById");
438 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
440 b.Property<
long>(
"Id")
441 .ValueGeneratedOnAdd()
442 .HasColumnType(
"bigint");
444 b.Property<
string>(
"ExternalUserId")
447 .HasColumnType(
"varchar(100)");
449 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"ExternalUserId"),
"utf8mb4");
451 b.Property<
int>(
"Provider")
452 .HasColumnType(
"int");
454 b.Property<
long?>(
"UserId")
455 .HasColumnType(
"bigint");
459 b.HasIndex(
"UserId");
461 b.HasIndex(
"Provider",
"ExternalUserId")
464 b.ToTable(
"OAuthConnections");
467 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
469 b.Property<
long?>(
"Id")
470 .ValueGeneratedOnAdd()
471 .HasColumnType(
"bigint");
473 b.Property<ulong>(
"AdministrationRights")
474 .HasColumnType(
"bigint unsigned");
476 b.Property<
long?>(
"GroupId")
477 .HasColumnType(
"bigint");
479 b.Property<ulong>(
"InstanceManagerRights")
480 .HasColumnType(
"bigint unsigned");
482 b.Property<
long?>(
"UserId")
483 .HasColumnType(
"bigint");
487 b.HasIndex(
"GroupId")
493 b.ToTable(
"PermissionSets");
496 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
498 b.Property<
long>(
"Id")
499 .ValueGeneratedOnAdd()
500 .HasColumnType(
"bigint");
502 b.Property<
string>(
"AccessIdentifier")
504 .HasColumnType(
"longtext");
506 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"AccessIdentifier"),
"utf8mb4");
508 b.Property<
long>(
"CompileJobId")
509 .HasColumnType(
"bigint");
511 b.Property<
long?>(
"InitialCompileJobId")
512 .HasColumnType(
"bigint");
514 b.Property<
int>(
"LaunchSecurityLevel")
515 .HasColumnType(
"int");
517 b.Property<
int>(
"LaunchVisibility")
518 .HasColumnType(
"int");
520 b.Property<ushort>(
"Port")
521 .HasColumnType(
"smallint unsigned");
523 b.Property<
int>(
"ProcessId")
524 .HasColumnType(
"int");
526 b.Property<
int>(
"RebootState")
527 .HasColumnType(
"int");
531 b.HasIndex(
"CompileJobId");
533 b.HasIndex(
"InitialCompileJobId");
535 b.ToTable(
"ReattachInformations");
538 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
540 b.Property<
long>(
"Id")
541 .ValueGeneratedOnAdd()
542 .HasColumnType(
"bigint");
544 b.Property<
string>(
"AccessToken")
546 .HasColumnType(
"longtext");
548 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"AccessToken"),
"utf8mb4");
550 b.Property<
string>(
"AccessUser")
552 .HasColumnType(
"longtext");
554 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"AccessUser"),
"utf8mb4");
556 b.Property<
bool?>(
"AutoUpdatesKeepTestMerges")
558 .HasColumnType(
"tinyint(1)");
560 b.Property<
bool?>(
"AutoUpdatesSynchronize")
562 .HasColumnType(
"tinyint(1)");
564 b.Property<
string>(
"CommitterEmail")
567 .HasColumnType(
"longtext");
569 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"CommitterEmail"),
"utf8mb4");
571 b.Property<
string>(
"CommitterName")
574 .HasColumnType(
"longtext");
576 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"CommitterName"),
"utf8mb4");
578 b.Property<
bool?>(
"CreateGitHubDeployments")
580 .HasColumnType(
"tinyint(1)");
582 b.Property<
long>(
"InstanceId")
583 .HasColumnType(
"bigint");
585 b.Property<
bool?>(
"PostTestMergeComment")
587 .HasColumnType(
"tinyint(1)");
589 b.Property<
bool?>(
"PushTestMergeCommits")
591 .HasColumnType(
"tinyint(1)");
593 b.Property<
bool?>(
"ShowTestMergeCommitters")
595 .HasColumnType(
"tinyint(1)");
597 b.Property<
bool?>(
"UpdateSubmodules")
599 .HasColumnType(
"tinyint(1)");
603 b.HasIndex(
"InstanceId")
606 b.ToTable(
"RepositorySettings");
609 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
611 b.Property<
long>(
"Id")
612 .ValueGeneratedOnAdd()
613 .HasColumnType(
"bigint");
615 b.Property<
long>(
"RevisionInformationId")
616 .HasColumnType(
"bigint");
618 b.Property<
long>(
"TestMergeId")
619 .HasColumnType(
"bigint");
623 b.HasIndex(
"RevisionInformationId");
625 b.HasIndex(
"TestMergeId");
627 b.ToTable(
"RevInfoTestMerges");
630 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
632 b.Property<
long>(
"Id")
633 .ValueGeneratedOnAdd()
634 .HasColumnType(
"bigint");
636 b.Property<
string>(
"CommitSha")
639 .HasColumnType(
"varchar(40)");
641 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"CommitSha"),
"utf8mb4");
643 b.Property<
long>(
"InstanceId")
644 .HasColumnType(
"bigint");
646 b.Property<
string>(
"OriginCommitSha")
649 .HasColumnType(
"varchar(40)");
651 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"OriginCommitSha"),
"utf8mb4");
653 b.Property<DateTimeOffset>(
"Timestamp")
654 .HasColumnType(
"datetime(6)");
658 b.HasIndex(
"InstanceId",
"CommitSha")
661 b.ToTable(
"RevisionInformations");
664 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
666 b.Property<
long>(
"Id")
667 .ValueGeneratedOnAdd()
668 .HasColumnType(
"bigint");
670 b.Property<
string>(
"Author")
672 .HasColumnType(
"longtext");
674 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Author"),
"utf8mb4");
676 b.Property<
string>(
"BodyAtMerge")
678 .HasColumnType(
"longtext");
680 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"BodyAtMerge"),
"utf8mb4");
682 b.Property<
string>(
"Comment")
684 .HasColumnType(
"longtext");
686 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Comment"),
"utf8mb4");
688 b.Property<DateTimeOffset>(
"MergedAt")
689 .HasColumnType(
"datetime(6)");
691 b.Property<
long>(
"MergedById")
692 .HasColumnType(
"bigint");
694 b.Property<
int>(
"Number")
695 .HasColumnType(
"int");
697 b.Property<
long?>(
"PrimaryRevisionInformationId")
699 .HasColumnType(
"bigint");
701 b.Property<
string>(
"TargetCommitSha")
704 .HasColumnType(
"varchar(40)");
706 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"TargetCommitSha"),
"utf8mb4");
708 b.Property<
string>(
"TitleAtMerge")
710 .HasColumnType(
"longtext");
712 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"TitleAtMerge"),
"utf8mb4");
714 b.Property<
string>(
"Url")
716 .HasColumnType(
"longtext");
718 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Url"),
"utf8mb4");
722 b.HasIndex(
"MergedById");
724 b.HasIndex(
"PrimaryRevisionInformationId")
727 b.ToTable(
"TestMerges");
730 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
732 b.Property<
long?>(
"Id")
733 .ValueGeneratedOnAdd()
734 .HasColumnType(
"bigint");
736 b.Property<
string>(
"CanonicalName")
739 .HasColumnType(
"varchar(100)");
741 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"CanonicalName"),
"utf8mb4");
743 b.Property<DateTimeOffset?>(
"CreatedAt")
745 .HasColumnType(
"datetime(6)");
747 b.Property<
long?>(
"CreatedById")
748 .HasColumnType(
"bigint");
750 b.Property<
bool?>(
"Enabled")
752 .HasColumnType(
"tinyint(1)");
754 b.Property<
long?>(
"GroupId")
755 .HasColumnType(
"bigint");
757 b.Property<DateTimeOffset?>(
"LastPasswordUpdate")
758 .HasColumnType(
"datetime(6)");
760 b.Property<
string>(
"Name")
763 .HasColumnType(
"varchar(100)");
765 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Name"),
"utf8mb4");
767 b.Property<
string>(
"PasswordHash")
768 .HasColumnType(
"longtext");
770 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"PasswordHash"),
"utf8mb4");
772 b.Property<
string>(
"SystemIdentifier")
774 .HasColumnType(
"varchar(100)");
776 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"SystemIdentifier"),
"utf8mb4");
780 b.HasIndex(
"CanonicalName")
783 b.HasIndex(
"CreatedById");
785 b.HasIndex(
"GroupId");
787 b.HasIndex(
"SystemIdentifier")
793 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
795 b.Property<
long?>(
"Id")
796 .ValueGeneratedOnAdd()
797 .HasColumnType(
"bigint");
799 b.Property<
string>(
"Name")
802 .HasColumnType(
"varchar(100)");
804 MySqlPropertyBuilderExtensions.HasCharSet(b.Property<
string>(
"Name"),
"utf8mb4");
814 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
816 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
817 .WithMany(
"ChatSettings")
818 .HasForeignKey(
"InstanceId")
819 .OnDelete(DeleteBehavior.Cascade)
822 b.Navigation(
"Instance");
825 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatChannel", b =>
827 b.HasOne(
"Tgstation.Server.Host.Models.ChatBot",
"ChatSettings")
828 .WithMany(
"Channels")
829 .HasForeignKey(
"ChatSettingsId")
830 .OnDelete(DeleteBehavior.Cascade)
833 b.Navigation(
"ChatSettings");
836 modelBuilder.Entity(
"Tgstation.Server.Host.Models.CompileJob", b =>
838 b.HasOne(
"Tgstation.Server.Host.Models.Job",
"Job")
840 .HasForeignKey(
"Tgstation.Server.Host.Models.CompileJob",
"JobId")
841 .OnDelete(DeleteBehavior.Cascade)
844 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
845 .WithMany(
"CompileJobs")
846 .HasForeignKey(
"RevisionInformationId")
847 .OnDelete(DeleteBehavior.Cascade)
852 b.Navigation(
"RevisionInformation");
855 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
857 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
858 .WithOne(
"DreamDaemonSettings")
859 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamDaemonSettings",
"InstanceId")
860 .OnDelete(DeleteBehavior.Cascade)
863 b.Navigation(
"Instance");
866 modelBuilder.Entity(
"Tgstation.Server.Host.Models.DreamMakerSettings", b =>
868 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
869 .WithOne(
"DreamMakerSettings")
870 .HasForeignKey(
"Tgstation.Server.Host.Models.DreamMakerSettings",
"InstanceId")
871 .OnDelete(DeleteBehavior.Cascade)
874 b.Navigation(
"Instance");
877 modelBuilder.Entity(
"Tgstation.Server.Host.Models.InstancePermissionSet", b =>
879 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
880 .WithMany(
"InstancePermissionSets")
881 .HasForeignKey(
"InstanceId")
882 .OnDelete(DeleteBehavior.Cascade)
885 b.HasOne(
"Tgstation.Server.Host.Models.PermissionSet",
"PermissionSet")
886 .WithMany(
"InstancePermissionSets")
887 .HasForeignKey(
"PermissionSetId")
888 .OnDelete(DeleteBehavior.Cascade)
891 b.Navigation(
"Instance");
893 b.Navigation(
"PermissionSet");
896 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Job", b =>
898 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CancelledBy")
900 .HasForeignKey(
"CancelledById");
902 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
904 .HasForeignKey(
"InstanceId")
905 .OnDelete(DeleteBehavior.Cascade)
908 b.HasOne(
"Tgstation.Server.Host.Models.User",
"StartedBy")
910 .HasForeignKey(
"StartedById")
911 .OnDelete(DeleteBehavior.Cascade)
914 b.Navigation(
"CancelledBy");
916 b.Navigation(
"Instance");
918 b.Navigation(
"StartedBy");
921 modelBuilder.Entity(
"Tgstation.Server.Host.Models.OAuthConnection", b =>
923 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
924 .WithMany(
"OAuthConnections")
925 .HasForeignKey(
"UserId")
926 .OnDelete(DeleteBehavior.Cascade);
928 b.Navigation(
"User");
931 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
933 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
934 .WithOne(
"PermissionSet")
935 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"GroupId")
936 .OnDelete(DeleteBehavior.Cascade);
938 b.HasOne(
"Tgstation.Server.Host.Models.User",
"User")
939 .WithOne(
"PermissionSet")
940 .HasForeignKey(
"Tgstation.Server.Host.Models.PermissionSet",
"UserId")
941 .OnDelete(DeleteBehavior.Cascade);
943 b.Navigation(
"Group");
945 b.Navigation(
"User");
948 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ReattachInformation", b =>
950 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"CompileJob")
952 .HasForeignKey(
"CompileJobId")
953 .OnDelete(DeleteBehavior.Cascade)
956 b.HasOne(
"Tgstation.Server.Host.Models.CompileJob",
"InitialCompileJob")
958 .HasForeignKey(
"InitialCompileJobId");
960 b.Navigation(
"CompileJob");
962 b.Navigation(
"InitialCompileJob");
965 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RepositorySettings", b =>
967 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
968 .WithOne(
"RepositorySettings")
969 .HasForeignKey(
"Tgstation.Server.Host.Models.RepositorySettings",
"InstanceId")
970 .OnDelete(DeleteBehavior.Cascade)
973 b.Navigation(
"Instance");
976 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
978 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"RevisionInformation")
979 .WithMany(
"ActiveTestMerges")
980 .HasForeignKey(
"RevisionInformationId")
981 .OnDelete(DeleteBehavior.Cascade)
984 b.HasOne(
"Tgstation.Server.Host.Models.TestMerge",
"TestMerge")
985 .WithMany(
"RevisonInformations")
986 .HasForeignKey(
"TestMergeId")
987 .OnDelete(DeleteBehavior.ClientNoAction)
990 b.Navigation(
"RevisionInformation");
992 b.Navigation(
"TestMerge");
995 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
997 b.HasOne(
"Tgstation.Server.Host.Models.Instance",
"Instance")
998 .WithMany(
"RevisionInformations")
999 .HasForeignKey(
"InstanceId")
1000 .OnDelete(DeleteBehavior.Cascade)
1003 b.Navigation(
"Instance");
1006 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
1008 b.HasOne(
"Tgstation.Server.Host.Models.User",
"MergedBy")
1009 .WithMany(
"TestMerges")
1010 .HasForeignKey(
"MergedById")
1011 .OnDelete(DeleteBehavior.Restrict)
1014 b.HasOne(
"Tgstation.Server.Host.Models.RevisionInformation",
"PrimaryRevisionInformation")
1015 .WithOne(
"PrimaryTestMerge")
1016 .HasForeignKey(
"Tgstation.Server.Host.Models.TestMerge",
"PrimaryRevisionInformationId")
1017 .OnDelete(DeleteBehavior.Cascade)
1020 b.Navigation(
"MergedBy");
1022 b.Navigation(
"PrimaryRevisionInformation");
1025 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
1027 b.HasOne(
"Tgstation.Server.Host.Models.User",
"CreatedBy")
1028 .WithMany(
"CreatedUsers")
1029 .HasForeignKey(
"CreatedById");
1031 b.HasOne(
"Tgstation.Server.Host.Models.UserGroup",
"Group")
1033 .HasForeignKey(
"GroupId");
1035 b.Navigation(
"CreatedBy");
1037 b.Navigation(
"Group");
1040 modelBuilder.Entity(
"Tgstation.Server.Host.Models.ChatBot", b =>
1042 b.Navigation(
"Channels");
1045 modelBuilder.Entity(
"Tgstation.Server.Host.Models.Instance", b =>
1047 b.Navigation(
"ChatSettings");
1049 b.Navigation(
"DreamDaemonSettings");
1051 b.Navigation(
"DreamMakerSettings");
1053 b.Navigation(
"InstancePermissionSets");
1055 b.Navigation(
"Jobs");
1057 b.Navigation(
"RepositorySettings");
1059 b.Navigation(
"RevisionInformations");
1062 modelBuilder.Entity(
"Tgstation.Server.Host.Models.PermissionSet", b =>
1064 b.Navigation(
"InstancePermissionSets");
1067 modelBuilder.Entity(
"Tgstation.Server.Host.Models.RevisionInformation", b =>
1069 b.Navigation(
"ActiveTestMerges");
1071 b.Navigation(
"CompileJobs");
1073 b.Navigation(
"PrimaryTestMerge");
1076 modelBuilder.Entity(
"Tgstation.Server.Host.Models.TestMerge", b =>
1078 b.Navigation(
"RevisonInformations");
1081 modelBuilder.Entity(
"Tgstation.Server.Host.Models.User", b =>
1083 b.Navigation(
"CreatedUsers");
1085 b.Navigation(
"OAuthConnections");
1087 b.Navigation(
"PermissionSet");
1089 b.Navigation(
"TestMerges");
1092 modelBuilder.Entity(
"Tgstation.Server.Host.Models.UserGroup", b =>
1094 b.Navigation(
"PermissionSet")
1097 b.Navigation(
"Users");
1099#pragma warning restore 612, 618