Skip to content

Commit eab95d5

Browse files
committed
Added landing website
1 parent d9e1fd8 commit eab95d5

File tree

16 files changed

+264
-152
lines changed

16 files changed

+264
-152
lines changed

README.md

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
# codelm
22

3-
This repository contains five components that together make up the platform used to run the CodeLM programming competition.
3+
This repository contains six components that together make up the platform used to run the CodeLM programming competition.
44

55
## Components
66

@@ -10,6 +10,7 @@ All components are written in TypeScript and run either on Node.js or in the bro
1010
- `coderunner`: Runs inside of a Docker container spawned by the backend. Receives a user's code submission, runs it, and reports the results.
1111
- `common`: Type definitions and utilities used by multiple components.
1212
- `frontend`: The frontend. Contains the competitor dashboard and the admin dashboard. Uses Angular.
13+
- `landing`: The landing site containing general information about the event.
1314
- `test`: An automated stress test suite.
1415

1516
## Previous versions of the CodeLM platform:

backend/deployment/codelm

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,23 @@ upstream app_server_codelm {
22
server 127.0.0.1:8080 fail_timeout=0;
33
}
44

5+
# Landing
56
server {
67
listen 80;
78
listen 443 ssl;
89
server_name newwavecomputers.com www.newwavecomputers.com;
10+
root /home/codelm/dist/landing;
11+
12+
ssl on;
13+
ssl_certificate /root/certs/newwavecomputers.com.pem;
14+
ssl_certificate_key /root/certs/newwavecomputers.com.key;
15+
}
16+
17+
# Dashboard
18+
server {
19+
listen 80;
20+
listen 443 ssl;
21+
server_name dashboard.newwavecomputers.com www.dashboard.newwavecomputers.com;
922
root /home/codelm/dist/frontend;
1023

1124
ssl on;

frontend/src/app/common/components/faq/faq.component.html

Lines changed: 0 additions & 20 deletions
This file was deleted.

frontend/src/app/common/components/faq/faq.component.scss

Lines changed: 0 additions & 12 deletions
This file was deleted.

frontend/src/app/common/components/faq/faq.component.ts

Lines changed: 0 additions & 84 deletions
This file was deleted.

frontend/src/app/common/views/login/login.component.html

Lines changed: 15 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,5 @@
11
<app-card>
22
<img src="assets/logo.png" />
3-
<app-card
4-
display="info"
5-
header="Welcome to the CodeLM {{ year }} dashboard!"
6-
*ngIf="settings.registration"
7-
>
8-
<button mat-raised-button color="accent" type="button" (click)="showFaq()">
9-
Frequently Asked Questions
10-
</button>
11-
<button
12-
mat-raised-button
13-
color="accent"
14-
type="button"
15-
style="float: right;"
16-
(click)="register()"
17-
>
18-
Register
19-
</button>
20-
</app-card>
213
<form
224
#loginForm="ngForm"
235
[formGroup]="formGroup"
@@ -44,6 +26,21 @@
4426
</mat-form-field>
4527
<button mat-raised-button color="accent" type="submit">Log In</button>
4628
</form>
29+
<ng-container *ngIf="settings.registration">
30+
<br />
31+
<mat-divider></mat-divider>
32+
<br />
33+
<button
34+
mat-raised-button
35+
color="basic"
36+
type="button"
37+
class="register-button"
38+
(click)="register()"
39+
>
40+
Register
41+
</button>
42+
<br />
43+
</ng-container>
4744
<br />
4845
<p class="right">
4946
Build:

frontend/src/app/common/views/login/login.component.scss

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ form {
2121
font-size: 20px;
2222
}
2323

24+
.register-button {
25+
width: 100%;
26+
}
27+
2428
p.right {
2529
text-align: right;
2630

frontend/src/app/common/views/login/login.component.ts

Lines changed: 1 addition & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -4,10 +4,9 @@ import { AuthService } from '../../../services/auth.service';
44
import { LoginResponse } from '../../../../../../common/src/packets/server.packet';
55
import { FormControl, FormGroup, NgForm, Validators } from '@angular/forms';
66
import { SettingsModel } from '../../../../../../common/src/models/settings.model';
7-
import { VERSION, YEAR } from '../../../../../../common/version';
7+
import { VERSION } from '../../../../../../common/version';
88
import { MatDialog } from '@angular/material/dialog';
99
import { AllCodeComponent } from '../../components/all-code/all-code.component';
10-
import { FaqComponent } from '../../components/faq/faq.component';
1110

1211
@Component({
1312
selector: 'app-login',
@@ -60,13 +59,6 @@ export class LoginComponent implements OnInit {
6059
this.router.navigate(['register']);
6160
}
6261

63-
showFaq() {
64-
this.dialog.open(FaqComponent, {
65-
width: '90vw',
66-
height: '90vh',
67-
});
68-
}
69-
7062
showAllCode() {
7163
this.dialog.open(AllCodeComponent, {
7264
width: '90vw',
@@ -77,8 +69,4 @@ export class LoginComponent implements OnInit {
7769
get version() {
7870
return VERSION;
7971
}
80-
81-
get year() {
82-
return YEAR;
83-
}
8472
}

frontend/src/app/shared.module.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ import { MatRadioModule } from '@angular/material/radio';
3232
import { MatTooltipModule } from '@angular/material/tooltip';
3333
import { AllCodeComponent } from './common/components/all-code/all-code.component';
3434
import { TitlePipe } from './pipes/title.pipe';
35-
import { FaqComponent } from './common/components/faq/faq.component';
3635
import { GameComponent } from './common/views/game/game.component';
3736
import { FileDropComponent } from './common/components/file-drop/file-drop.component';
3837
import { PluralizeSentencePipe } from './pipes/pluralize-sentence.pipe';
@@ -52,7 +51,6 @@ import { MatButtonToggleModule } from '@angular/material/button-toggle';
5251
CardComponent,
5352
CodeMirrorComponent,
5453
AllCodeComponent,
55-
FaqComponent,
5654
GameComponent,
5755
FileDropComponent,
5856
AlertComponent,

landing/README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
# codelm-landing
2+
3+
The landing site containing general information about the event.

landing/prod.sh

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
mkdir -p ../dist/landing/ && cp -r src/* ../dist/landing/

landing/src/images/2018_1.jpg

3.91 MB
Loading

0 commit comments

Comments
 (0)