tgstation-server 6.12.0
The /tg/station 13 server suite
Loading...
Searching...
No Matches
20231105004820_SLAddJobCodes.Designer.cs
Go to the documentation of this file.
1// <auto-generated />
2using System;
3
4using Microsoft.EntityFrameworkCore;
5using Microsoft.EntityFrameworkCore.Infrastructure;
6using Microsoft.EntityFrameworkCore.Migrations;
7
9{
10 [DbContext(typeof(SqliteDatabaseContext))]
11 [Migration("20231105004820_SLAddJobCodes")]
12 partial class SLAddJobCodes
13 {
15 protected override void BuildTargetModel(ModelBuilder modelBuilder)
16 {
17#pragma warning disable 612, 618
18 modelBuilder.HasAnnotation("ProductVersion", "7.0.13");
19
20 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
21 {
22 b.Property<long?>("Id")
23 .ValueGeneratedOnAdd()
24 .HasColumnType("INTEGER");
25
26 b.Property<ushort?>("ChannelLimit")
27 .IsRequired()
28 .HasColumnType("INTEGER");
29
30 b.Property<string>("ConnectionString")
31 .IsRequired()
32 .HasMaxLength(10000)
33 .HasColumnType("TEXT");
34
35 b.Property<bool?>("Enabled")
36 .HasColumnType("INTEGER");
37
38 b.Property<long>("InstanceId")
39 .HasColumnType("INTEGER");
40
41 b.Property<string>("Name")
42 .IsRequired()
43 .HasMaxLength(100)
44 .HasColumnType("TEXT");
45
46 b.Property<int>("Provider")
47 .HasColumnType("INTEGER");
48
49 b.Property<uint?>("ReconnectionInterval")
50 .IsRequired()
51 .HasColumnType("INTEGER");
52
53 b.HasKey("Id");
54
55 b.HasIndex("InstanceId", "Name")
56 .IsUnique();
57
58 b.ToTable("ChatBots");
59 });
60
61 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatChannel", b =>
62 {
63 b.Property<long>("Id")
64 .ValueGeneratedOnAdd()
65 .HasColumnType("INTEGER");
66
67 b.Property<long>("ChatSettingsId")
68 .HasColumnType("INTEGER");
69
70 b.Property<ulong?>("DiscordChannelId")
71 .HasColumnType("INTEGER");
72
73 b.Property<string>("IrcChannel")
74 .HasMaxLength(100)
75 .HasColumnType("TEXT");
76
77 b.Property<bool?>("IsAdminChannel")
78 .IsRequired()
79 .HasColumnType("INTEGER");
80
81 b.Property<bool?>("IsSystemChannel")
82 .IsRequired()
83 .HasColumnType("INTEGER");
84
85 b.Property<bool?>("IsUpdatesChannel")
86 .IsRequired()
87 .HasColumnType("INTEGER");
88
89 b.Property<bool?>("IsWatchdogChannel")
90 .IsRequired()
91 .HasColumnType("INTEGER");
92
93 b.Property<string>("Tag")
94 .HasMaxLength(10000)
95 .HasColumnType("TEXT");
96
97 b.HasKey("Id");
98
99 b.HasIndex("ChatSettingsId", "DiscordChannelId")
100 .IsUnique();
101
102 b.HasIndex("ChatSettingsId", "IrcChannel")
103 .IsUnique();
104
105 b.ToTable("ChatChannels");
106 });
107
108 modelBuilder.Entity("Tgstation.Server.Host.Models.CompileJob", b =>
109 {
110 b.Property<long?>("Id")
111 .ValueGeneratedOnAdd()
112 .HasColumnType("INTEGER");
113
114 b.Property<string>("ByondVersion")
115 .IsRequired()
116 .HasColumnType("TEXT");
117
118 b.Property<int?>("DMApiMajorVersion")
119 .HasColumnType("INTEGER");
120
121 b.Property<int?>("DMApiMinorVersion")
122 .HasColumnType("INTEGER");
123
124 b.Property<int?>("DMApiPatchVersion")
125 .HasColumnType("INTEGER");
126
127 b.Property<Guid?>("DirectoryName")
128 .IsRequired()
129 .HasColumnType("TEXT");
130
131 b.Property<string>("DmeName")
132 .IsRequired()
133 .HasColumnType("TEXT");
134
135 b.Property<int?>("GitHubDeploymentId")
136 .HasColumnType("INTEGER");
137
138 b.Property<long?>("GitHubRepoId")
139 .HasColumnType("INTEGER");
140
141 b.Property<long>("JobId")
142 .HasColumnType("INTEGER");
143
144 b.Property<int?>("MinimumSecurityLevel")
145 .HasColumnType("INTEGER");
146
147 b.Property<string>("Output")
148 .IsRequired()
149 .HasColumnType("TEXT");
150
151 b.Property<string>("RepositoryOrigin")
152 .HasColumnType("TEXT");
153
154 b.Property<long>("RevisionInformationId")
155 .HasColumnType("INTEGER");
156
157 b.HasKey("Id");
158
159 b.HasIndex("DirectoryName");
160
161 b.HasIndex("JobId")
162 .IsUnique();
163
164 b.HasIndex("RevisionInformationId");
165
166 b.ToTable("CompileJobs");
167 });
168
169 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
170 {
171 b.Property<long>("Id")
172 .ValueGeneratedOnAdd()
173 .HasColumnType("INTEGER");
174
175 b.Property<string>("AdditionalParameters")
176 .IsRequired()
177 .HasMaxLength(10000)
178 .HasColumnType("TEXT");
179
180 b.Property<bool?>("AllowWebClient")
181 .IsRequired()
182 .HasColumnType("INTEGER");
183
184 b.Property<bool?>("AutoStart")
185 .IsRequired()
186 .HasColumnType("INTEGER");
187
188 b.Property<bool?>("DumpOnHealthCheckRestart")
189 .IsRequired()
190 .HasColumnType("INTEGER");
191
192 b.Property<uint?>("HealthCheckSeconds")
193 .IsRequired()
194 .HasColumnType("INTEGER");
195
196 b.Property<long>("InstanceId")
197 .HasColumnType("INTEGER");
198
199 b.Property<bool?>("LogOutput")
200 .IsRequired()
201 .HasColumnType("INTEGER");
202
203 b.Property<uint?>("MapThreads")
204 .IsRequired()
205 .HasColumnType("INTEGER");
206
207 b.Property<ushort?>("Port")
208 .IsRequired()
209 .HasColumnType("INTEGER");
210
211 b.Property<int>("SecurityLevel")
212 .HasColumnType("INTEGER");
213
214 b.Property<bool?>("StartProfiler")
215 .IsRequired()
216 .HasColumnType("INTEGER");
217
218 b.Property<uint?>("StartupTimeout")
219 .IsRequired()
220 .HasColumnType("INTEGER");
221
222 b.Property<uint?>("TopicRequestTimeout")
223 .IsRequired()
224 .HasColumnType("INTEGER");
225
226 b.Property<int>("Visibility")
227 .HasColumnType("INTEGER");
228
229 b.HasKey("Id");
230
231 b.HasIndex("InstanceId")
232 .IsUnique();
233
234 b.ToTable("DreamDaemonSettings");
235 });
236
237 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamMakerSettings", b =>
238 {
239 b.Property<long>("Id")
240 .ValueGeneratedOnAdd()
241 .HasColumnType("INTEGER");
242
243 b.Property<ushort?>("ApiValidationPort")
244 .IsRequired()
245 .HasColumnType("INTEGER");
246
247 b.Property<int>("ApiValidationSecurityLevel")
248 .HasColumnType("INTEGER");
249
250 b.Property<long>("InstanceId")
251 .HasColumnType("INTEGER");
252
253 b.Property<string>("ProjectName")
254 .HasMaxLength(10000)
255 .HasColumnType("TEXT");
256
257 b.Property<bool?>("RequireDMApiValidation")
258 .IsRequired()
259 .HasColumnType("INTEGER");
260
261 b.Property<TimeSpan?>("Timeout")
262 .IsRequired()
263 .HasColumnType("TEXT");
264
265 b.HasKey("Id");
266
267 b.HasIndex("InstanceId")
268 .IsUnique();
269
270 b.ToTable("DreamMakerSettings");
271 });
272
273 modelBuilder.Entity("Tgstation.Server.Host.Models.Instance", b =>
274 {
275 b.Property<long?>("Id")
276 .ValueGeneratedOnAdd()
277 .HasColumnType("INTEGER");
278
279 b.Property<uint?>("AutoUpdateInterval")
280 .IsRequired()
281 .HasColumnType("INTEGER");
282
283 b.Property<ushort?>("ChatBotLimit")
284 .IsRequired()
285 .HasColumnType("INTEGER");
286
287 b.Property<int>("ConfigurationType")
288 .HasColumnType("INTEGER");
289
290 b.Property<string>("Name")
291 .IsRequired()
292 .HasMaxLength(100)
293 .HasColumnType("TEXT");
294
295 b.Property<bool?>("Online")
296 .IsRequired()
297 .HasColumnType("INTEGER");
298
299 b.Property<string>("Path")
300 .IsRequired()
301 .HasColumnType("TEXT");
302
303 b.Property<string>("SwarmIdentifer")
304 .HasColumnType("TEXT");
305
306 b.HasKey("Id");
307
308 b.HasIndex("Path", "SwarmIdentifer")
309 .IsUnique();
310
311 b.ToTable("Instances");
312 });
313
314 modelBuilder.Entity("Tgstation.Server.Host.Models.InstancePermissionSet", b =>
315 {
316 b.Property<long>("Id")
317 .ValueGeneratedOnAdd()
318 .HasColumnType("INTEGER");
319
320 b.Property<ulong>("ByondRights")
321 .HasColumnType("INTEGER");
322
323 b.Property<ulong>("ChatBotRights")
324 .HasColumnType("INTEGER");
325
326 b.Property<ulong>("ConfigurationRights")
327 .HasColumnType("INTEGER");
328
329 b.Property<ulong>("DreamDaemonRights")
330 .HasColumnType("INTEGER");
331
332 b.Property<ulong>("DreamMakerRights")
333 .HasColumnType("INTEGER");
334
335 b.Property<long>("InstanceId")
336 .HasColumnType("INTEGER");
337
338 b.Property<ulong>("InstancePermissionSetRights")
339 .HasColumnType("INTEGER");
340
341 b.Property<long>("PermissionSetId")
342 .HasColumnType("INTEGER");
343
344 b.Property<ulong>("RepositoryRights")
345 .HasColumnType("INTEGER");
346
347 b.HasKey("Id");
348
349 b.HasIndex("InstanceId");
350
351 b.HasIndex("PermissionSetId", "InstanceId")
352 .IsUnique();
353
354 b.ToTable("InstancePermissionSets");
355 });
356
357 modelBuilder.Entity("Tgstation.Server.Host.Models.Job", b =>
358 {
359 b.Property<long?>("Id")
360 .ValueGeneratedOnAdd()
361 .HasColumnType("INTEGER");
362
363 b.Property<ulong?>("CancelRight")
364 .HasColumnType("INTEGER");
365
366 b.Property<ulong?>("CancelRightsType")
367 .HasColumnType("INTEGER");
368
369 b.Property<bool?>("Cancelled")
370 .IsRequired()
371 .HasColumnType("INTEGER");
372
373 b.Property<long?>("CancelledById")
374 .HasColumnType("INTEGER");
375
376 b.Property<string>("Description")
377 .IsRequired()
378 .HasColumnType("TEXT");
379
380 b.Property<uint?>("ErrorCode")
381 .HasColumnType("INTEGER");
382
383 b.Property<string>("ExceptionDetails")
384 .HasColumnType("TEXT");
385
386 b.Property<long>("InstanceId")
387 .HasColumnType("INTEGER");
388
389 b.Property<byte>("JobCode")
390 .HasColumnType("INTEGER");
391
392 b.Property<DateTimeOffset?>("StartedAt")
393 .IsRequired()
394 .HasColumnType("TEXT");
395
396 b.Property<long>("StartedById")
397 .HasColumnType("INTEGER");
398
399 b.Property<DateTimeOffset?>("StoppedAt")
400 .HasColumnType("TEXT");
401
402 b.HasKey("Id");
403
404 b.HasIndex("CancelledById");
405
406 b.HasIndex("InstanceId");
407
408 b.HasIndex("StartedById");
409
410 b.ToTable("Jobs");
411 });
412
413 modelBuilder.Entity("Tgstation.Server.Host.Models.OAuthConnection", b =>
414 {
415 b.Property<long>("Id")
416 .ValueGeneratedOnAdd()
417 .HasColumnType("INTEGER");
418
419 b.Property<string>("ExternalUserId")
420 .IsRequired()
421 .HasMaxLength(100)
422 .HasColumnType("TEXT");
423
424 b.Property<int>("Provider")
425 .HasColumnType("INTEGER");
426
427 b.Property<long?>("UserId")
428 .HasColumnType("INTEGER");
429
430 b.HasKey("Id");
431
432 b.HasIndex("UserId");
433
434 b.HasIndex("Provider", "ExternalUserId")
435 .IsUnique();
436
437 b.ToTable("OAuthConnections");
438 });
439
440 modelBuilder.Entity("Tgstation.Server.Host.Models.PermissionSet", b =>
441 {
442 b.Property<long?>("Id")
443 .ValueGeneratedOnAdd()
444 .HasColumnType("INTEGER");
445
446 b.Property<ulong>("AdministrationRights")
447 .HasColumnType("INTEGER");
448
449 b.Property<long?>("GroupId")
450 .HasColumnType("INTEGER");
451
452 b.Property<ulong>("InstanceManagerRights")
453 .HasColumnType("INTEGER");
454
455 b.Property<long?>("UserId")
456 .HasColumnType("INTEGER");
457
458 b.HasKey("Id");
459
460 b.HasIndex("GroupId")
461 .IsUnique();
462
463 b.HasIndex("UserId")
464 .IsUnique();
465
466 b.ToTable("PermissionSets");
467 });
468
469 modelBuilder.Entity("Tgstation.Server.Host.Models.ReattachInformation", b =>
470 {
471 b.Property<long>("Id")
472 .ValueGeneratedOnAdd()
473 .HasColumnType("INTEGER");
474
475 b.Property<string>("AccessIdentifier")
476 .IsRequired()
477 .HasColumnType("TEXT");
478
479 b.Property<long>("CompileJobId")
480 .HasColumnType("INTEGER");
481
482 b.Property<long?>("InitialCompileJobId")
483 .HasColumnType("INTEGER");
484
485 b.Property<int>("LaunchSecurityLevel")
486 .HasColumnType("INTEGER");
487
488 b.Property<int>("LaunchVisibility")
489 .HasColumnType("INTEGER");
490
491 b.Property<ushort>("Port")
492 .HasColumnType("INTEGER");
493
494 b.Property<int>("ProcessId")
495 .HasColumnType("INTEGER");
496
497 b.Property<int>("RebootState")
498 .HasColumnType("INTEGER");
499
500 b.HasKey("Id");
501
502 b.HasIndex("CompileJobId");
503
504 b.HasIndex("InitialCompileJobId");
505
506 b.ToTable("ReattachInformations");
507 });
508
509 modelBuilder.Entity("Tgstation.Server.Host.Models.RepositorySettings", b =>
510 {
511 b.Property<long>("Id")
512 .ValueGeneratedOnAdd()
513 .HasColumnType("INTEGER");
514
515 b.Property<string>("AccessToken")
516 .HasMaxLength(10000)
517 .HasColumnType("TEXT");
518
519 b.Property<string>("AccessUser")
520 .HasMaxLength(10000)
521 .HasColumnType("TEXT");
522
523 b.Property<bool?>("AutoUpdatesKeepTestMerges")
524 .IsRequired()
525 .HasColumnType("INTEGER");
526
527 b.Property<bool?>("AutoUpdatesSynchronize")
528 .IsRequired()
529 .HasColumnType("INTEGER");
530
531 b.Property<string>("CommitterEmail")
532 .IsRequired()
533 .HasMaxLength(10000)
534 .HasColumnType("TEXT");
535
536 b.Property<string>("CommitterName")
537 .IsRequired()
538 .HasMaxLength(10000)
539 .HasColumnType("TEXT");
540
541 b.Property<bool?>("CreateGitHubDeployments")
542 .IsRequired()
543 .HasColumnType("INTEGER");
544
545 b.Property<long>("InstanceId")
546 .HasColumnType("INTEGER");
547
548 b.Property<bool?>("PostTestMergeComment")
549 .IsRequired()
550 .HasColumnType("INTEGER");
551
552 b.Property<bool?>("PushTestMergeCommits")
553 .IsRequired()
554 .HasColumnType("INTEGER");
555
556 b.Property<bool?>("ShowTestMergeCommitters")
557 .IsRequired()
558 .HasColumnType("INTEGER");
559
560 b.Property<bool?>("UpdateSubmodules")
561 .IsRequired()
562 .HasColumnType("INTEGER");
563
564 b.HasKey("Id");
565
566 b.HasIndex("InstanceId")
567 .IsUnique();
568
569 b.ToTable("RepositorySettings");
570 });
571
572 modelBuilder.Entity("Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
573 {
574 b.Property<long>("Id")
575 .ValueGeneratedOnAdd()
576 .HasColumnType("INTEGER");
577
578 b.Property<long>("RevisionInformationId")
579 .HasColumnType("INTEGER");
580
581 b.Property<long>("TestMergeId")
582 .HasColumnType("INTEGER");
583
584 b.HasKey("Id");
585
586 b.HasIndex("RevisionInformationId");
587
588 b.HasIndex("TestMergeId");
589
590 b.ToTable("RevInfoTestMerges");
591 });
592
593 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
594 {
595 b.Property<long>("Id")
596 .ValueGeneratedOnAdd()
597 .HasColumnType("INTEGER");
598
599 b.Property<string>("CommitSha")
600 .IsRequired()
601 .HasMaxLength(40)
602 .HasColumnType("TEXT");
603
604 b.Property<long>("InstanceId")
605 .HasColumnType("INTEGER");
606
607 b.Property<string>("OriginCommitSha")
608 .IsRequired()
609 .HasMaxLength(40)
610 .HasColumnType("TEXT");
611
612 b.Property<DateTimeOffset>("Timestamp")
613 .HasColumnType("TEXT");
614
615 b.HasKey("Id");
616
617 b.HasIndex("InstanceId", "CommitSha")
618 .IsUnique();
619
620 b.ToTable("RevisionInformations");
621 });
622
623 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
624 {
625 b.Property<long>("Id")
626 .ValueGeneratedOnAdd()
627 .HasColumnType("INTEGER");
628
629 b.Property<string>("Author")
630 .IsRequired()
631 .HasColumnType("TEXT");
632
633 b.Property<string>("BodyAtMerge")
634 .IsRequired()
635 .HasColumnType("TEXT");
636
637 b.Property<string>("Comment")
638 .HasMaxLength(10000)
639 .HasColumnType("TEXT");
640
641 b.Property<DateTimeOffset>("MergedAt")
642 .HasColumnType("TEXT");
643
644 b.Property<long>("MergedById")
645 .HasColumnType("INTEGER");
646
647 b.Property<int>("Number")
648 .HasColumnType("INTEGER");
649
650 b.Property<long?>("PrimaryRevisionInformationId")
651 .IsRequired()
652 .HasColumnType("INTEGER");
653
654 b.Property<string>("TargetCommitSha")
655 .IsRequired()
656 .HasMaxLength(40)
657 .HasColumnType("TEXT");
658
659 b.Property<string>("TitleAtMerge")
660 .IsRequired()
661 .HasColumnType("TEXT");
662
663 b.Property<string>("Url")
664 .IsRequired()
665 .HasColumnType("TEXT");
666
667 b.HasKey("Id");
668
669 b.HasIndex("MergedById");
670
671 b.HasIndex("PrimaryRevisionInformationId")
672 .IsUnique();
673
674 b.ToTable("TestMerges");
675 });
676
677 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
678 {
679 b.Property<long?>("Id")
680 .ValueGeneratedOnAdd()
681 .HasColumnType("INTEGER");
682
683 b.Property<string>("CanonicalName")
684 .IsRequired()
685 .HasMaxLength(100)
686 .HasColumnType("TEXT");
687
688 b.Property<DateTimeOffset?>("CreatedAt")
689 .IsRequired()
690 .HasColumnType("TEXT");
691
692 b.Property<long?>("CreatedById")
693 .HasColumnType("INTEGER");
694
695 b.Property<bool?>("Enabled")
696 .IsRequired()
697 .HasColumnType("INTEGER");
698
699 b.Property<long?>("GroupId")
700 .HasColumnType("INTEGER");
701
702 b.Property<DateTimeOffset?>("LastPasswordUpdate")
703 .HasColumnType("TEXT");
704
705 b.Property<string>("Name")
706 .IsRequired()
707 .HasMaxLength(100)
708 .HasColumnType("TEXT");
709
710 b.Property<string>("PasswordHash")
711 .HasColumnType("TEXT");
712
713 b.Property<string>("SystemIdentifier")
714 .HasMaxLength(100)
715 .HasColumnType("TEXT");
716
717 b.HasKey("Id");
718
719 b.HasIndex("CanonicalName")
720 .IsUnique();
721
722 b.HasIndex("CreatedById");
723
724 b.HasIndex("GroupId");
725
726 b.HasIndex("SystemIdentifier")
727 .IsUnique();
728
729 b.ToTable("Users");
730 });
731
732 modelBuilder.Entity("Tgstation.Server.Host.Models.UserGroup", b =>
733 {
734 b.Property<long?>("Id")
735 .ValueGeneratedOnAdd()
736 .HasColumnType("INTEGER");
737
738 b.Property<string>("Name")
739 .IsRequired()
740 .HasMaxLength(100)
741 .HasColumnType("TEXT");
742
743 b.HasKey("Id");
744
745 b.HasIndex("Name")
746 .IsUnique();
747
748 b.ToTable("Groups");
749 });
750
751 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
752 {
753 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
754 .WithMany("ChatSettings")
755 .HasForeignKey("InstanceId")
756 .OnDelete(DeleteBehavior.Cascade)
757 .IsRequired();
758
759 b.Navigation("Instance");
760 });
761
762 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatChannel", b =>
763 {
764 b.HasOne("Tgstation.Server.Host.Models.ChatBot", "ChatSettings")
765 .WithMany("Channels")
766 .HasForeignKey("ChatSettingsId")
767 .OnDelete(DeleteBehavior.Cascade)
768 .IsRequired();
769
770 b.Navigation("ChatSettings");
771 });
772
773 modelBuilder.Entity("Tgstation.Server.Host.Models.CompileJob", b =>
774 {
775 b.HasOne("Tgstation.Server.Host.Models.Job", "Job")
776 .WithOne()
777 .HasForeignKey("Tgstation.Server.Host.Models.CompileJob", "JobId")
778 .OnDelete(DeleteBehavior.Cascade)
779 .IsRequired();
780
781 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "RevisionInformation")
782 .WithMany("CompileJobs")
783 .HasForeignKey("RevisionInformationId")
784 .OnDelete(DeleteBehavior.ClientNoAction)
785 .IsRequired();
786
787 b.Navigation("Job");
788
789 b.Navigation("RevisionInformation");
790 });
791
792 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamDaemonSettings", b =>
793 {
794 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
795 .WithOne("DreamDaemonSettings")
796 .HasForeignKey("Tgstation.Server.Host.Models.DreamDaemonSettings", "InstanceId")
797 .OnDelete(DeleteBehavior.Cascade)
798 .IsRequired();
799
800 b.Navigation("Instance");
801 });
802
803 modelBuilder.Entity("Tgstation.Server.Host.Models.DreamMakerSettings", b =>
804 {
805 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
806 .WithOne("DreamMakerSettings")
807 .HasForeignKey("Tgstation.Server.Host.Models.DreamMakerSettings", "InstanceId")
808 .OnDelete(DeleteBehavior.Cascade)
809 .IsRequired();
810
811 b.Navigation("Instance");
812 });
813
814 modelBuilder.Entity("Tgstation.Server.Host.Models.InstancePermissionSet", b =>
815 {
816 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
817 .WithMany("InstancePermissionSets")
818 .HasForeignKey("InstanceId")
819 .OnDelete(DeleteBehavior.Cascade)
820 .IsRequired();
821
822 b.HasOne("Tgstation.Server.Host.Models.PermissionSet", "PermissionSet")
823 .WithMany("InstancePermissionSets")
824 .HasForeignKey("PermissionSetId")
825 .OnDelete(DeleteBehavior.Cascade)
826 .IsRequired();
827
828 b.Navigation("Instance");
829
830 b.Navigation("PermissionSet");
831 });
832
833 modelBuilder.Entity("Tgstation.Server.Host.Models.Job", b =>
834 {
835 b.HasOne("Tgstation.Server.Host.Models.User", "CancelledBy")
836 .WithMany()
837 .HasForeignKey("CancelledById");
838
839 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
840 .WithMany("Jobs")
841 .HasForeignKey("InstanceId")
842 .OnDelete(DeleteBehavior.Cascade)
843 .IsRequired();
844
845 b.HasOne("Tgstation.Server.Host.Models.User", "StartedBy")
846 .WithMany()
847 .HasForeignKey("StartedById")
848 .OnDelete(DeleteBehavior.Cascade)
849 .IsRequired();
850
851 b.Navigation("CancelledBy");
852
853 b.Navigation("Instance");
854
855 b.Navigation("StartedBy");
856 });
857
858 modelBuilder.Entity("Tgstation.Server.Host.Models.OAuthConnection", b =>
859 {
860 b.HasOne("Tgstation.Server.Host.Models.User", "User")
861 .WithMany("OAuthConnections")
862 .HasForeignKey("UserId")
863 .OnDelete(DeleteBehavior.Cascade);
864
865 b.Navigation("User");
866 });
867
868 modelBuilder.Entity("Tgstation.Server.Host.Models.PermissionSet", b =>
869 {
870 b.HasOne("Tgstation.Server.Host.Models.UserGroup", "Group")
871 .WithOne("PermissionSet")
872 .HasForeignKey("Tgstation.Server.Host.Models.PermissionSet", "GroupId")
873 .OnDelete(DeleteBehavior.Cascade);
874
875 b.HasOne("Tgstation.Server.Host.Models.User", "User")
876 .WithOne("PermissionSet")
877 .HasForeignKey("Tgstation.Server.Host.Models.PermissionSet", "UserId")
878 .OnDelete(DeleteBehavior.Cascade);
879
880 b.Navigation("Group");
881
882 b.Navigation("User");
883 });
884
885 modelBuilder.Entity("Tgstation.Server.Host.Models.ReattachInformation", b =>
886 {
887 b.HasOne("Tgstation.Server.Host.Models.CompileJob", "CompileJob")
888 .WithMany()
889 .HasForeignKey("CompileJobId")
890 .OnDelete(DeleteBehavior.Cascade)
891 .IsRequired();
892
893 b.HasOne("Tgstation.Server.Host.Models.CompileJob", "InitialCompileJob")
894 .WithMany()
895 .HasForeignKey("InitialCompileJobId");
896
897 b.Navigation("CompileJob");
898
899 b.Navigation("InitialCompileJob");
900 });
901
902 modelBuilder.Entity("Tgstation.Server.Host.Models.RepositorySettings", b =>
903 {
904 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
905 .WithOne("RepositorySettings")
906 .HasForeignKey("Tgstation.Server.Host.Models.RepositorySettings", "InstanceId")
907 .OnDelete(DeleteBehavior.Cascade)
908 .IsRequired();
909
910 b.Navigation("Instance");
911 });
912
913 modelBuilder.Entity("Tgstation.Server.Host.Models.RevInfoTestMerge", b =>
914 {
915 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "RevisionInformation")
916 .WithMany("ActiveTestMerges")
917 .HasForeignKey("RevisionInformationId")
918 .OnDelete(DeleteBehavior.Cascade)
919 .IsRequired();
920
921 b.HasOne("Tgstation.Server.Host.Models.TestMerge", "TestMerge")
922 .WithMany("RevisonInformations")
923 .HasForeignKey("TestMergeId")
924 .OnDelete(DeleteBehavior.ClientNoAction)
925 .IsRequired();
926
927 b.Navigation("RevisionInformation");
928
929 b.Navigation("TestMerge");
930 });
931
932 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
933 {
934 b.HasOne("Tgstation.Server.Host.Models.Instance", "Instance")
935 .WithMany("RevisionInformations")
936 .HasForeignKey("InstanceId")
937 .OnDelete(DeleteBehavior.Cascade)
938 .IsRequired();
939
940 b.Navigation("Instance");
941 });
942
943 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
944 {
945 b.HasOne("Tgstation.Server.Host.Models.User", "MergedBy")
946 .WithMany("TestMerges")
947 .HasForeignKey("MergedById")
948 .OnDelete(DeleteBehavior.Restrict)
949 .IsRequired();
950
951 b.HasOne("Tgstation.Server.Host.Models.RevisionInformation", "PrimaryRevisionInformation")
952 .WithOne("PrimaryTestMerge")
953 .HasForeignKey("Tgstation.Server.Host.Models.TestMerge", "PrimaryRevisionInformationId")
954 .OnDelete(DeleteBehavior.Cascade)
955 .IsRequired();
956
957 b.Navigation("MergedBy");
958
959 b.Navigation("PrimaryRevisionInformation");
960 });
961
962 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
963 {
964 b.HasOne("Tgstation.Server.Host.Models.User", "CreatedBy")
965 .WithMany("CreatedUsers")
966 .HasForeignKey("CreatedById");
967
968 b.HasOne("Tgstation.Server.Host.Models.UserGroup", "Group")
969 .WithMany("Users")
970 .HasForeignKey("GroupId");
971
972 b.Navigation("CreatedBy");
973
974 b.Navigation("Group");
975 });
976
977 modelBuilder.Entity("Tgstation.Server.Host.Models.ChatBot", b =>
978 {
979 b.Navigation("Channels");
980 });
981
982 modelBuilder.Entity("Tgstation.Server.Host.Models.Instance", b =>
983 {
984 b.Navigation("ChatSettings");
985
986 b.Navigation("DreamDaemonSettings");
987
988 b.Navigation("DreamMakerSettings");
989
990 b.Navigation("InstancePermissionSets");
991
992 b.Navigation("Jobs");
993
994 b.Navigation("RepositorySettings");
995
996 b.Navigation("RevisionInformations");
997 });
998
999 modelBuilder.Entity("Tgstation.Server.Host.Models.PermissionSet", b =>
1000 {
1001 b.Navigation("InstancePermissionSets");
1002 });
1003
1004 modelBuilder.Entity("Tgstation.Server.Host.Models.RevisionInformation", b =>
1005 {
1006 b.Navigation("ActiveTestMerges");
1007
1008 b.Navigation("CompileJobs");
1009
1010 b.Navigation("PrimaryTestMerge");
1011 });
1012
1013 modelBuilder.Entity("Tgstation.Server.Host.Models.TestMerge", b =>
1014 {
1015 b.Navigation("RevisonInformations");
1016 });
1017
1018 modelBuilder.Entity("Tgstation.Server.Host.Models.User", b =>
1019 {
1020 b.Navigation("CreatedUsers");
1021
1022 b.Navigation("OAuthConnections");
1023
1024 b.Navigation("PermissionSet");
1025
1026 b.Navigation("TestMerges");
1027 });
1028
1029 modelBuilder.Entity("Tgstation.Server.Host.Models.UserGroup", b =>
1030 {
1031 b.Navigation("PermissionSet")
1032 .IsRequired();
1033
1034 b.Navigation("Users");
1035 });
1036#pragma warning restore 612, 618
1037 }
1038 }
1039}