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