generated from bmstu-rsoi/lab4-template
-
Notifications
You must be signed in to change notification settings - Fork 0
59 lines (50 loc) · 1.62 KB
/
classroom.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
name: GitHub Classroom Workflow
on:
push:
branches: [ master ]
jobs:
build:
name: Autograding
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
fetch-depth: 0
- uses: docker/setup-buildx-action@v2
# TODO build, publish to docker hub, deploy to k8s
- name: Build images
run: docker compose build
- name: Login DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKERHUB_LOGIN }}
password: ${{ secrets.DOCKERHUB_PASSWD }}
- name: Push images
run: docker compose push
- name: Deploy to k8s
run: |
curl -sSL https://storage.yandexcloud.net/yandexcloud-yc/install.sh | bash
exec -l $SHELL
echo ${{ secrets.YC_TOKEN }} | yc init --password-stdin
yc managed-kubernetes cluster get-credentials palokap --external
helm install default k8s
sleep 60
- name: Run API Tests
uses: matt-ball/newman-action@master
with:
collection: v2/postman/collection.json
environment: v2/postman/environment.json
delayRequest: 100
reporters: '[ "cli" ]'
- uses: education/autograding@v1
id: autograder
continue-on-error: true
- name: Github auto grader mark
uses: Romanow/[email protected]
with:
google_token: ${{secrets.GOOGLE_API_KEY}}
sheet_id: "1xkgjUX6Qmk7rdJG-QPOToav-HWWtthJjnShIKnw3oIY"
homework_number: 4
user_column: 'D'
column_offset: 'F'
mark: "'+"