forked from Alexey/DAS_2024_1
Compare commits
114 Commits
borschevsk
...
main
Author | SHA1 | Date | |
---|---|---|---|
85b809333b | |||
5e3c9c0d5b | |||
daf24d364d | |||
6c13deb231 | |||
543d41d9c3 | |||
153684c403 | |||
0708b01560 | |||
8a6932ff20 | |||
35cf16824d | |||
ac3dc2e566 | |||
2f46c05849 | |||
84cb26162c | |||
129b991712 | |||
ffecef8fa3 | |||
1289d67a62 | |||
b09f3ea844 | |||
2f368ffb07 | |||
ead06782ad | |||
b2ac5eba9a | |||
0c0a47549a | |||
|
84e8cac198 | ||
bde242318f | |||
761cc83ebd | |||
4699fda797 | |||
940cc6757f | |||
1e9bdf2806 | |||
|
9bd14a60b4 | ||
5aa2cae670 | |||
281d30a89e | |||
f2093f376c | |||
80c666d6b0 | |||
a589994db5 | |||
38ce2bb347 | |||
f25af86d9c | |||
45eb2b72c5 | |||
77bdc1d8e9 | |||
da6593c4d0 | |||
|
eeac04be49 | ||
0a73e2d5d4 | |||
1565e49462 | |||
858ea65e71 | |||
0f898b968d | |||
8b96102dbd | |||
82ecad71f4 | |||
8a96320fd5 | |||
bd25930973 | |||
|
8efc2422cf | ||
c3537b5abe | |||
a0ef65e0f9 | |||
6815b2e560 | |||
48b7fbd900 | |||
080625d270 | |||
37996c249a | |||
9456d4fe01 | |||
c14e105db5 | |||
4d1e900721 | |||
7184d6d728 | |||
|
6e7055efa4 | ||
|
9e40adc53c | ||
|
4a36528cc7 | ||
ad3988e5fc | |||
780b4b2924 | |||
d9f5f75f5e | |||
7d9c9ec4d0 | |||
5047b16cde | |||
2b87427299 | |||
|
21cdd4971d | ||
6b55b7b0fc | |||
47193155d9 | |||
bc8c4c887e | |||
4a2adcc35a | |||
d7cb666a0d | |||
6c642384c1 | |||
bdb5cc07ed | |||
e761e33201 | |||
|
ceee500b95 | ||
2be2c71b69 | |||
|
aa8180ba49 | ||
c509e74465 | |||
314751f25c | |||
48f7f3a215 | |||
f112d2a44b | |||
477afb824d | |||
6ce78e60ad | |||
b13182c80e | |||
e7b9938278 | |||
822467bd99 | |||
|
ba7480cb4f | ||
d7faf2a1b7 | |||
d98803227e | |||
6f12270c73 | |||
6e6266c228 | |||
06d1d8cdd4 | |||
4c76a9dea6 | |||
e5d0aa0b3d | |||
d326e64f24 | |||
1a118ae71f | |||
e9b06b1f27 | |||
|
1adaac9281 | ||
|
5e9e2600f3 | ||
b6e311755e | |||
8eedde24a1 | |||
57970b3333 | |||
1c77ba3272 | |||
ce9527b1c9 | |||
a1419f21ec | |||
aac01e9f48 | |||
221f3e248b | |||
3d98388a13 | |||
4922e9075e | |||
891eae4211 | |||
121e4bbcd2 | |||
0590f7b532 | |||
0eec58a347 |
9
.gitignore
vendored
Normal file
9
.gitignore
vendored
Normal file
@ -0,0 +1,9 @@
|
||||
|
||||
/dozorova_alena_lab_2/.vs
|
||||
/dozorova_alena_lab_2/ConsoleApp1/.vs
|
||||
/dozorova_alena_lab_2/ConsoleApp1/bin
|
||||
/dozorova_alena_lab_2/ConsoleApp1/obj
|
||||
/dozorova_alena_lab_2/ConsoleApp1/Properties/PublishProfiles
|
||||
/dozorova_alena_lab_2/ConsoleApp2/.vs
|
||||
/dozorova_alena_lab_2/ConsoleApp2/bin
|
||||
/dozorova_alena_lab_2/ConsoleApp2/obj
|
59
balakhonov_danila_lab_1/README.md
Normal file
59
balakhonov_danila_lab_1/README.md
Normal file
@ -0,0 +1,59 @@
|
||||
# Лабораторная работа номер 1
|
||||
|
||||
> Здравствуйте меня зовут Балахонов Данила группа ПИбд-42
|
||||
>
|
||||
> *— Балахонов Данила ПИбд-42*
|
||||
|
||||
Видео лабораторной работы номер 1 доступно по этой [ссылке](https://drive.google.com/file/d/1Up_JzDcK_TjYLixpfYXN7PhJmOeg_Uck/view?usp=sharing).
|
||||
|
||||
## Как запустить лабораторную работу номер 1?
|
||||
### Необходимые компоненты для запуска лабораторной работы номер 1
|
||||
> Здесь рассказана установка необходимых компонентов для запуска лабораторной работы номер 1 под дистрибутив GNU/Linux **Ubuntu**.
|
||||
|
||||
Для запуска лабораторной работы номер 1 необходимы такие компоненты:
|
||||
- Git
|
||||
- Docker
|
||||
- Docker compose
|
||||
|
||||
Чтобы установить **Git**, необходимо ввести данные команды в командную строку:
|
||||
``` bash
|
||||
sudo apt-get update
|
||||
sudo apt-get install git
|
||||
```
|
||||
|
||||
Чтобы установить **Docker** и **Docker compose**, стоит ввести такие команды:
|
||||
``` bash
|
||||
# Настройка репозитория Docker
|
||||
sudo apt-get update
|
||||
sudo apt-get install ca-certificates curl
|
||||
sudo install -m 0755 -d /etc/apt/keyrings
|
||||
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
|
||||
sudo chmod a+r /etc/apt/keyrings/docker.asc
|
||||
|
||||
echo \
|
||||
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
|
||||
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
|
||||
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
sudo apt-get update
|
||||
|
||||
# Установка Docker и его компонентов
|
||||
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
|
||||
```
|
||||
### Запуск лабораторной работы номер 1
|
||||
Для запуска лабораторной работы номер 1 необходимо **склонировать** репозиторий в любую папку и **перейти на ветку** balakhonov_danila_lab_1.
|
||||
Далее в папке с `docker-compose.yaml` нужно вызвать такую команду:
|
||||
``` bash
|
||||
sudo docker-compose up -d
|
||||
```
|
||||
Таким образом будут запущены контейнеры в фоновом режиме.
|
||||
## Какие технологии были использованы?
|
||||
Для выполнения лабораторной работы номер 1 использовались такие технологии, как: *git*, *docker*, *docker compose*.
|
||||
|
||||
Сервисы, выбранные для запуска в docker-compose файле:
|
||||
- *Gitea* - удобный сервис отслеживания версий разрабатываемого ПО
|
||||
- *MediaWiki* - сервис создания и ведения электронной энциклопедии
|
||||
- *PostgreSQL* - база данных, используемая сервисами выше
|
||||
|
||||
Системой, на которую были установлены указанные технологии, является Ubuntu 22.
|
||||
## Что делает лабораторная работа номер 1?
|
||||
Лабораторная работа номер 1 заключается в написании docker-compose файла для удобного запуска и администрирования сразу нескольких сервисов в docker-контейнерах.
|
58
balakhonov_danila_lab_1/docker-compose.yaml
Normal file
58
balakhonov_danila_lab_1/docker-compose.yaml
Normal file
@ -0,0 +1,58 @@
|
||||
services:
|
||||
# PostgreSQL
|
||||
db:
|
||||
# Образ контейнера PostgreSQL последней версии
|
||||
image: postgres
|
||||
# Название контейнера
|
||||
container_name: db
|
||||
# Переменные окружения для настройки базы данных
|
||||
environment:
|
||||
- POSTGRES_USER=gitea
|
||||
- POSTGRES_PASSWORD=gitea
|
||||
- POSTGRES_DB=gitea
|
||||
# Настройка корневого каталога, где хранятся данные
|
||||
# Слева указан каталог компьютера, справа - каталог контейнера
|
||||
# Нужно для сохранения данных на сервере после отключения контейнера
|
||||
volumes:
|
||||
- ./postgres:/var/lib/postgresql/data
|
||||
# Порт, через который можно будет подключиться к базе данных
|
||||
ports:
|
||||
- 5432:5432
|
||||
# После перезапуска докера всегда запускать этот контейнер
|
||||
restart: always
|
||||
# Gitea
|
||||
gitea:
|
||||
# Используется Gitea последней версии
|
||||
image: gitea/gitea
|
||||
container_name: gitea
|
||||
# После перезапуска докера всегда запускать этот контейнер
|
||||
restart: always
|
||||
volumes:
|
||||
- ./data:/var/lib/gitea
|
||||
- ./config:/etc/gitea
|
||||
- /etc/timezone:/etc/timezone:ro
|
||||
- /etc/localtime:/etc/localtime:ro
|
||||
ports:
|
||||
- 3000:3000
|
||||
- 2222:2222
|
||||
environment:
|
||||
- GITEA__database__DB_TYPE=postgres
|
||||
- GITEA__database__HOST=db:5432
|
||||
- GITEA__database__NAME=gitea
|
||||
- GITEA__database__USER=gitea
|
||||
- GITEA__database__PASSWD=gitea
|
||||
# Указывается, что этот контейнер запускается только после запуска контейнера db
|
||||
depends_on:
|
||||
- db
|
||||
# MediaWiki
|
||||
mediawiki:
|
||||
# Образ контейнера MediaWiki последней версии
|
||||
image: mediawiki
|
||||
container_name: mediawiki
|
||||
restart: always
|
||||
ports:
|
||||
- 8080:80
|
||||
links:
|
||||
- db
|
||||
volumes:
|
||||
- ./images:/var/www/html/images
|
64
balakhonov_danila_lab_2/README.md
Normal file
64
balakhonov_danila_lab_2/README.md
Normal file
@ -0,0 +1,64 @@
|
||||
# Лабораторная работа номер 2
|
||||
|
||||
> Здравствуйте меня зовут Балахонов Данила группа ПИбд-42
|
||||
>
|
||||
> *— Балахонов Данила ПИбд-42*
|
||||
|
||||
Видео лабораторной работы номер 2 доступно по этой [ссылке](https://drive.google.com/file/d/1N4NgWsFLlHY5lGOO3Ps7DPvdJbHNxaqz/view?usp=sharing).
|
||||
|
||||
## Как запустить лабораторную работу номер 2?
|
||||
### Необходимые компоненты для запуска лабораторной работы номер 2
|
||||
> Здесь рассказана установка необходимых компонентов для запуска лабораторной работы номер 2 под дистрибутив GNU/Linux **Ubuntu**.
|
||||
|
||||
Для запуска лабораторной работы номер 2 необходимы такие компоненты:
|
||||
- Git
|
||||
- Docker
|
||||
- Docker compose
|
||||
|
||||
Чтобы установить **Git**, необходимо ввести данные команды в командную строку:
|
||||
``` bash
|
||||
sudo apt-get update
|
||||
sudo apt-get install git
|
||||
```
|
||||
|
||||
Чтобы установить **Docker** и **Docker compose**, стоит ввести такие команды:
|
||||
``` bash
|
||||
# Настройка репозитория Docker
|
||||
sudo apt-get update
|
||||
sudo apt-get install ca-certificates curl
|
||||
sudo install -m 0755 -d /etc/apt/keyrings
|
||||
sudo curl -fsSL https://download.docker.com/linux/ubuntu/gpg -o /etc/apt/keyrings/docker.asc
|
||||
sudo chmod a+r /etc/apt/keyrings/docker.asc
|
||||
|
||||
echo \
|
||||
"deb [arch=$(dpkg --print-architecture) signed-by=/etc/apt/keyrings/docker.asc] https://download.docker.com/linux/ubuntu \
|
||||
$(. /etc/os-release && echo "$VERSION_CODENAME") stable" | \
|
||||
sudo tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||
sudo apt-get update
|
||||
|
||||
# Установка Docker и его компонентов
|
||||
sudo apt-get install docker-ce docker-ce-cli containerd.io docker-buildx-plugin docker-compose-plugin
|
||||
```
|
||||
### Запуск лабораторной работы номер 2
|
||||
Для запуска лабораторной работы номер 2 необходимо **склонировать** репозиторий в любую папку и **перейти на ветку** balakhonov_danila_lab_2.
|
||||
Далее в папке с `docker-compose.yaml` нужно вызвать такую команду:
|
||||
``` bash
|
||||
sudo docker-compose up --build
|
||||
```
|
||||
Таким образом контейнеры будут подготовлены и запущены. Результат выполнения будет находится внутри директории докера. Расположение файлов data.txt и result.txt: `/var/lib/docker/volumes/balakhonov_danila_lab_2_result/_data/`
|
||||
|
||||
## Какие технологии были использованы?
|
||||
Для выполнения лабораторной работы номер 2 были применены такие технологии, как:
|
||||
- Dockerfile
|
||||
- Docker compose
|
||||
- Git
|
||||
- .NET SDK и F# в частности
|
||||
|
||||
Сервисы были написаны с использованием .NET SDK на языке F#.
|
||||
## Что делает лабораторная работа номер 2?
|
||||
Лабораторная работа номер 2 запускает два сервиса:
|
||||
|
||||
1. Сервис, который берёт из каталога `/var/data` случайный файл и перекладывает его в `/var/result/data.txt`
|
||||
2. Сервис, который ищет наибольшее число из файла `/var/result/data.txt` и сохраняет количество таких чисел из последовательности в `/var/result/result.txt`
|
||||
|
||||
Благодаря лабораторной работе номер 2 были получены навыки создания Dockerfile для развертывания проектов в контейнерах, а также их связки с помощью docker-compose.yaml.
|
22
balakhonov_danila_lab_2/docker-compose.yaml
Normal file
22
balakhonov_danila_lab_2/docker-compose.yaml
Normal file
@ -0,0 +1,22 @@
|
||||
services:
|
||||
app1:
|
||||
build: ./sigma_app_1/
|
||||
volumes:
|
||||
# Создание папки /var/data внутри контейнера
|
||||
# И копирование файлов из ./files в эту папку
|
||||
- ./files:/var/data
|
||||
# Создание папки /var/result внутри контейнера
|
||||
# А также папки result внутри директории докера
|
||||
- result:/var/result
|
||||
app2:
|
||||
build: ./skibidi_app_2/
|
||||
# Указано, что пока не запуститься app1, app2 не запустится
|
||||
# Он ЗАВИСИТ от app1 (depends on (с англ.) - зависит от)
|
||||
depends_on:
|
||||
- app1
|
||||
volumes:
|
||||
- result:/var/result
|
||||
volumes:
|
||||
# Указывается, что будет создана папка result
|
||||
# внутри директории докера
|
||||
result:
|
323
balakhonov_danila_lab_2/files/1.txt
Normal file
323
balakhonov_danila_lab_2/files/1.txt
Normal file
@ -0,0 +1,323 @@
|
||||
245
|
||||
678
|
||||
12
|
||||
987
|
||||
456
|
||||
234
|
||||
789
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
987
|
||||
654
|
||||
321
|
||||
456
|
||||
789
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
123
|
||||
456
|
||||
789
|
||||
987
|
||||
654
|
||||
321
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
||||
123
|
||||
456
|
||||
789
|
||||
234
|
||||
567
|
||||
890
|
||||
12
|
||||
34
|
||||
56
|
||||
78
|
||||
90
|
||||
123
|
||||
456
|
||||
789
|
||||
321
|
||||
654
|
||||
987
|
||||
432
|
||||
876
|
||||
543
|
||||
210
|
||||
678
|
||||
345
|
||||
678
|
642
balakhonov_danila_lab_2/files/2.txt
Normal file
642
balakhonov_danila_lab_2/files/2.txt
Normal file
@ -0,0 +1,642 @@
|
||||
873
|
||||
62
|
||||
455
|
||||
879
|
||||
235
|
||||
941
|
||||
267
|
||||
811
|
||||
174
|
||||
517
|
||||
382
|
||||
399
|
||||
460
|
||||
221
|
||||
640
|
||||
915
|
||||
384
|
||||
622
|
||||
897
|
||||
212
|
||||
798
|
||||
109
|
||||
477
|
||||
546
|
||||
29
|
||||
995
|
||||
678
|
||||
342
|
||||
135
|
||||
804
|
||||
890
|
||||
453
|
||||
726
|
||||
891
|
||||
664
|
||||
290
|
||||
872
|
||||
190
|
||||
526
|
||||
304
|
||||
12
|
||||
587
|
||||
234
|
||||
753
|
||||
980
|
||||
197
|
||||
824
|
||||
579
|
||||
458
|
||||
15
|
||||
999
|
||||
614
|
||||
704
|
||||
205
|
||||
860
|
||||
537
|
||||
842
|
||||
491
|
||||
668
|
||||
210
|
||||
920
|
||||
477
|
||||
811
|
||||
350
|
||||
731
|
||||
95
|
||||
639
|
||||
287
|
||||
127
|
||||
423
|
||||
1000
|
||||
394
|
||||
521
|
||||
8
|
||||
267
|
||||
154
|
||||
431
|
||||
715
|
||||
266
|
||||
834
|
||||
173
|
||||
268
|
||||
947
|
||||
582
|
||||
157
|
||||
367
|
||||
882
|
||||
737
|
||||
305
|
||||
472
|
||||
481
|
||||
651
|
||||
960
|
||||
843
|
||||
701
|
||||
122
|
||||
514
|
||||
92
|
||||
658
|
||||
884
|
||||
371
|
||||
458
|
||||
637
|
||||
620
|
||||
793
|
||||
285
|
||||
611
|
||||
785
|
||||
495
|
||||
822
|
||||
849
|
||||
708
|
||||
592
|
||||
465
|
||||
469
|
||||
78
|
||||
734
|
||||
667
|
||||
606
|
||||
241
|
||||
666
|
||||
474
|
||||
569
|
||||
543
|
||||
918
|
||||
68
|
||||
906
|
||||
123
|
||||
501
|
||||
330
|
||||
947
|
||||
111
|
||||
365
|
||||
734
|
||||
249
|
||||
429
|
||||
296
|
||||
16
|
||||
511
|
||||
974
|
||||
317
|
||||
764
|
||||
230
|
||||
542
|
||||
920
|
||||
821
|
||||
718
|
||||
281
|
||||
556
|
||||
575
|
||||
900
|
||||
632
|
||||
720
|
||||
462
|
||||
88
|
||||
275
|
||||
403
|
||||
100
|
||||
418
|
||||
684
|
||||
600
|
||||
119
|
||||
863
|
||||
781
|
||||
225
|
||||
971
|
||||
670
|
||||
80
|
||||
643
|
||||
220
|
||||
176
|
||||
588
|
||||
58
|
||||
202
|
||||
850
|
||||
537
|
||||
934
|
||||
748
|
||||
378
|
||||
817
|
||||
505
|
||||
696
|
||||
21
|
||||
630
|
||||
324
|
||||
117
|
||||
420
|
||||
257
|
||||
493
|
||||
826
|
||||
688
|
||||
305
|
||||
772
|
||||
654
|
||||
927
|
||||
208
|
||||
525
|
||||
511
|
||||
256
|
||||
650
|
||||
447
|
||||
163
|
||||
99
|
||||
74
|
||||
99
|
||||
487
|
||||
306
|
||||
754
|
||||
510
|
||||
132
|
||||
201
|
||||
392
|
||||
785
|
||||
778
|
||||
512
|
||||
258
|
||||
904
|
||||
932
|
||||
589
|
||||
694
|
||||
204
|
||||
884
|
||||
110
|
||||
673
|
||||
152
|
||||
649
|
||||
295
|
||||
387
|
||||
758
|
||||
927
|
||||
538
|
||||
619
|
||||
904
|
||||
651
|
||||
174
|
||||
712
|
||||
104
|
||||
641
|
||||
474
|
||||
198
|
||||
322
|
||||
764
|
||||
204
|
||||
407
|
||||
550
|
||||
42
|
||||
879
|
||||
716
|
||||
368
|
||||
316
|
||||
43
|
||||
600
|
||||
893
|
||||
370
|
||||
137
|
||||
631
|
||||
244
|
||||
571
|
||||
663
|
||||
551
|
||||
907
|
||||
211
|
||||
166
|
||||
746
|
||||
583
|
||||
708
|
||||
771
|
||||
215
|
||||
90
|
||||
829
|
||||
653
|
||||
494
|
||||
563
|
||||
334
|
||||
794
|
||||
745
|
||||
936
|
||||
718
|
||||
126
|
||||
923
|
||||
451
|
||||
668
|
||||
966
|
||||
532
|
||||
935
|
||||
886
|
||||
646
|
||||
75
|
||||
858
|
||||
693
|
||||
859
|
||||
284
|
||||
315
|
||||
679
|
||||
133
|
||||
878
|
||||
292
|
||||
340
|
||||
716
|
||||
128
|
||||
250
|
||||
554
|
||||
482
|
||||
789
|
||||
677
|
||||
308
|
||||
494
|
||||
931
|
||||
144
|
||||
337
|
||||
982
|
||||
713
|
||||
535
|
||||
893
|
||||
939
|
||||
932
|
||||
905
|
||||
805
|
||||
236
|
||||
991
|
||||
781
|
||||
686
|
||||
572
|
||||
951
|
||||
335
|
||||
58
|
||||
303
|
||||
335
|
||||
145
|
||||
608
|
||||
794
|
||||
862
|
||||
792
|
||||
619
|
||||
54
|
||||
292
|
||||
878
|
||||
585
|
||||
293
|
||||
959
|
||||
379
|
||||
20
|
||||
484
|
||||
144
|
||||
678
|
||||
67
|
||||
363
|
||||
946
|
||||
566
|
||||
106
|
||||
442
|
||||
820
|
||||
562
|
||||
109
|
||||
201
|
||||
759
|
||||
481
|
||||
289
|
||||
698
|
||||
25
|
||||
847
|
||||
648
|
||||
733
|
||||
613
|
||||
776
|
||||
989
|
||||
257
|
||||
864
|
||||
32
|
||||
703
|
||||
989
|
||||
465
|
||||
103
|
||||
963
|
||||
515
|
||||
829
|
||||
30
|
||||
303
|
||||
926
|
||||
159
|
||||
586
|
||||
268
|
||||
852
|
||||
953
|
||||
321
|
||||
306
|
||||
978
|
||||
909
|
||||
177
|
||||
835
|
||||
458
|
||||
994
|
||||
885
|
||||
213
|
||||
775
|
||||
385
|
||||
598
|
||||
267
|
||||
754
|
||||
448
|
||||
1000
|
||||
555
|
||||
354
|
||||
657
|
||||
231
|
||||
979
|
||||
265
|
||||
374
|
||||
68
|
||||
197
|
||||
953
|
||||
648
|
||||
153
|
||||
523
|
||||
761
|
||||
827
|
||||
819
|
||||
63
|
||||
782
|
||||
766
|
||||
882
|
||||
404
|
||||
258
|
||||
672
|
||||
883
|
||||
80
|
||||
111
|
||||
212
|
||||
681
|
||||
812
|
||||
911
|
||||
837
|
||||
194
|
||||
161
|
||||
143
|
||||
427
|
||||
981
|
||||
132
|
||||
357
|
||||
605
|
||||
810
|
||||
414
|
||||
20
|
||||
210
|
||||
772
|
||||
882
|
||||
313
|
||||
186
|
||||
578
|
||||
154
|
||||
523
|
||||
339
|
||||
383
|
||||
903
|
||||
29
|
||||
172
|
||||
62
|
||||
314
|
||||
491
|
||||
289
|
||||
550
|
||||
521
|
||||
327
|
||||
794
|
||||
299
|
||||
678
|
||||
769
|
||||
415
|
||||
266
|
||||
77
|
||||
33
|
||||
438
|
||||
233
|
||||
160
|
||||
11
|
||||
523
|
||||
623
|
||||
254
|
||||
29
|
||||
327
|
||||
924
|
||||
938
|
||||
588
|
||||
444
|
||||
976
|
||||
547
|
||||
775
|
||||
638
|
||||
35
|
||||
23
|
||||
203
|
||||
203
|
||||
927
|
||||
149
|
||||
198
|
||||
150
|
||||
370
|
||||
728
|
||||
775
|
||||
818
|
||||
768
|
||||
99
|
||||
40
|
||||
969
|
||||
435
|
||||
49
|
||||
276
|
||||
360
|
||||
964
|
||||
277
|
||||
283
|
||||
825
|
||||
479
|
||||
331
|
||||
471
|
||||
381
|
||||
652
|
||||
264
|
||||
564
|
||||
891
|
||||
638
|
||||
470
|
||||
291
|
||||
101
|
||||
143
|
||||
93
|
||||
663
|
||||
328
|
||||
841
|
||||
881
|
||||
94
|
||||
327
|
||||
2
|
||||
628
|
||||
474
|
||||
905
|
||||
545
|
||||
421
|
||||
453
|
||||
282
|
||||
276
|
||||
24
|
||||
655
|
||||
295
|
||||
48
|
||||
102
|
||||
49
|
||||
676
|
||||
187
|
||||
773
|
||||
169
|
||||
170
|
||||
165
|
||||
405
|
||||
348
|
||||
4
|
||||
654
|
||||
276
|
||||
343
|
||||
153
|
||||
381
|
||||
756
|
||||
753
|
||||
816
|
||||
474
|
||||
186
|
||||
652
|
||||
67
|
||||
689
|
||||
69
|
||||
920
|
||||
880
|
||||
363
|
||||
637
|
||||
524
|
||||
171
|
||||
753
|
||||
12
|
||||
634
|
||||
648
|
||||
668
|
||||
220
|
||||
408
|
||||
348
|
||||
887
|
||||
341
|
||||
738
|
||||
681
|
||||
408
|
||||
377
|
||||
693
|
||||
234
|
||||
83
|
||||
982
|
||||
417
|
||||
222
|
||||
322
|
||||
253
|
||||
494
|
||||
868
|
||||
951
|
||||
344
|
||||
60
|
||||
23
|
||||
41
|
||||
99
|
||||
944
|
||||
723
|
||||
156
|
||||
813
|
||||
5
|
||||
44
|
||||
62
|
||||
899
|
||||
835
|
||||
482
|
||||
469
|
||||
157
|
||||
637
|
||||
295
|
||||
929
|
||||
992
|
||||
234
|
||||
66
|
||||
31
|
||||
170
|
||||
333
|
||||
92
|
||||
185
|
||||
117
|
||||
627
|
||||
82
|
||||
292
|
||||
796
|
||||
840
|
||||
768
|
||||
532
|
||||
981
|
||||
300
|
||||
125
|
||||
958
|
||||
4
|
489
balakhonov_danila_lab_2/files/3.txt
Normal file
489
balakhonov_danila_lab_2/files/3.txt
Normal file
@ -0,0 +1,489 @@
|
||||
522
|
||||
173
|
||||
815
|
||||
671
|
||||
284
|
||||
903
|
||||
477
|
||||
639
|
||||
732
|
||||
143
|
||||
928
|
||||
564
|
||||
812
|
||||
109
|
||||
397
|
||||
249
|
||||
868
|
||||
301
|
||||
848
|
||||
376
|
||||
794
|
||||
99
|
||||
506
|
||||
217
|
||||
645
|
||||
12
|
||||
187
|
||||
930
|
||||
811
|
||||
583
|
||||
684
|
||||
455
|
||||
94
|
||||
499
|
||||
118
|
||||
722
|
||||
603
|
||||
267
|
||||
772
|
||||
947
|
||||
845
|
||||
210
|
||||
495
|
||||
632
|
||||
372
|
||||
930
|
||||
908
|
||||
546
|
||||
327
|
||||
685
|
||||
883
|
||||
235
|
||||
613
|
||||
579
|
||||
762
|
||||
491
|
||||
328
|
||||
672
|
||||
156
|
||||
739
|
||||
1000
|
||||
421
|
||||
731
|
||||
215
|
||||
867
|
||||
610
|
||||
847
|
||||
732
|
||||
204
|
||||
411
|
||||
515
|
||||
150
|
||||
438
|
||||
651
|
||||
174
|
||||
590
|
||||
725
|
||||
963
|
||||
530
|
||||
889
|
||||
577
|
||||
694
|
||||
417
|
||||
261
|
||||
767
|
||||
480
|
||||
934
|
||||
125
|
||||
558
|
||||
282
|
||||
899
|
||||
96
|
||||
653
|
||||
908
|
||||
303
|
||||
774
|
||||
617
|
||||
407
|
||||
482
|
||||
538
|
||||
239
|
||||
472
|
||||
766
|
||||
118
|
||||
920
|
||||
206
|
||||
797
|
||||
420
|
||||
853
|
||||
205
|
||||
340
|
||||
123
|
||||
387
|
||||
497
|
||||
640
|
||||
24
|
||||
999
|
||||
476
|
||||
77
|
||||
920
|
||||
382
|
||||
405
|
||||
55
|
||||
834
|
||||
371
|
||||
167
|
||||
290
|
||||
300
|
||||
611
|
||||
53
|
||||
470
|
||||
81
|
||||
232
|
||||
14
|
||||
451
|
||||
678
|
||||
623
|
||||
564
|
||||
787
|
||||
99
|
||||
648
|
||||
873
|
||||
803
|
||||
888
|
||||
504
|
||||
186
|
||||
256
|
||||
405
|
||||
102
|
||||
999
|
||||
673
|
||||
721
|
||||
434
|
||||
814
|
||||
305
|
||||
582
|
||||
436
|
||||
90
|
||||
774
|
||||
216
|
||||
706
|
||||
855
|
||||
702
|
||||
307
|
||||
59
|
||||
835
|
||||
812
|
||||
234
|
||||
736
|
||||
168
|
||||
523
|
||||
219
|
||||
868
|
||||
365
|
||||
294
|
||||
500
|
||||
207
|
||||
927
|
||||
450
|
||||
521
|
||||
851
|
||||
703
|
||||
992
|
||||
327
|
||||
916
|
||||
554
|
||||
846
|
||||
658
|
||||
88
|
||||
659
|
||||
628
|
||||
764
|
||||
84
|
||||
45
|
||||
10
|
||||
870
|
||||
779
|
||||
320
|
||||
882
|
||||
942
|
||||
93
|
||||
792
|
||||
836
|
||||
137
|
||||
489
|
||||
862
|
||||
391
|
||||
337
|
||||
887
|
||||
114
|
||||
237
|
||||
178
|
||||
874
|
||||
569
|
||||
135
|
||||
919
|
||||
931
|
||||
231
|
||||
50
|
||||
995
|
||||
215
|
||||
658
|
||||
139
|
||||
484
|
||||
292
|
||||
903
|
||||
113
|
||||
755
|
||||
333
|
||||
829
|
||||
942
|
||||
360
|
||||
172
|
||||
689
|
||||
42
|
||||
127
|
||||
799
|
||||
191
|
||||
455
|
||||
533
|
||||
234
|
||||
15
|
||||
404
|
||||
636
|
||||
373
|
||||
884
|
||||
921
|
||||
977
|
||||
113
|
||||
227
|
||||
703
|
||||
173
|
||||
297
|
||||
440
|
||||
604
|
||||
575
|
||||
971
|
||||
855
|
||||
82
|
||||
252
|
||||
589
|
||||
276
|
||||
826
|
||||
206
|
||||
166
|
||||
482
|
||||
375
|
||||
174
|
||||
612
|
||||
818
|
||||
854
|
||||
832
|
||||
809
|
||||
569
|
||||
306
|
||||
993
|
||||
931
|
||||
289
|
||||
148
|
||||
943
|
||||
421
|
||||
784
|
||||
441
|
||||
536
|
||||
426
|
||||
548
|
||||
49
|
||||
687
|
||||
415
|
||||
505
|
||||
951
|
||||
583
|
||||
368
|
||||
172
|
||||
974
|
||||
47
|
||||
173
|
||||
570
|
||||
264
|
||||
754
|
||||
701
|
||||
693
|
||||
796
|
||||
914
|
||||
809
|
||||
310
|
||||
512
|
||||
725
|
||||
963
|
||||
829
|
||||
614
|
||||
220
|
||||
410
|
||||
631
|
||||
860
|
||||
270
|
||||
158
|
||||
168
|
||||
595
|
||||
62
|
||||
715
|
||||
913
|
||||
517
|
||||
157
|
||||
5
|
||||
660
|
||||
274
|
||||
414
|
||||
139
|
||||
300
|
||||
698
|
||||
675
|
||||
263
|
||||
872
|
||||
292
|
||||
142
|
||||
375
|
||||
696
|
||||
895
|
||||
302
|
||||
75
|
||||
576
|
||||
899
|
||||
524
|
||||
362
|
||||
721
|
||||
916
|
||||
883
|
||||
347
|
||||
980
|
||||
29
|
||||
392
|
||||
839
|
||||
971
|
||||
593
|
||||
708
|
||||
804
|
||||
678
|
||||
234
|
||||
719
|
||||
659
|
||||
418
|
||||
914
|
||||
437
|
||||
550
|
||||
418
|
||||
576
|
||||
776
|
||||
293
|
||||
737
|
||||
348
|
||||
292
|
||||
48
|
||||
975
|
||||
547
|
||||
205
|
||||
831
|
||||
783
|
||||
587
|
||||
657
|
||||
132
|
||||
733
|
||||
53
|
||||
700
|
||||
785
|
||||
292
|
||||
332
|
||||
771
|
||||
849
|
||||
994
|
||||
905
|
||||
460
|
||||
420
|
||||
923
|
||||
663
|
||||
134
|
||||
658
|
||||
673
|
||||
618
|
||||
779
|
||||
951
|
||||
244
|
||||
425
|
||||
312
|
||||
436
|
||||
878
|
||||
538
|
||||
236
|
||||
805
|
||||
457
|
||||
897
|
||||
799
|
||||
134
|
||||
469
|
||||
56
|
||||
724
|
||||
370
|
||||
521
|
||||
654
|
||||
20
|
||||
260
|
||||
315
|
||||
525
|
||||
501
|
||||
433
|
||||
90
|
||||
368
|
||||
192
|
||||
162
|
||||
198
|
||||
65
|
||||
652
|
||||
613
|
||||
222
|
||||
160
|
||||
76
|
||||
755
|
||||
541
|
||||
305
|
||||
257
|
||||
669
|
||||
179
|
||||
849
|
||||
878
|
||||
249
|
||||
224
|
||||
4
|
||||
1
|
||||
860
|
||||
967
|
||||
738
|
||||
712
|
||||
281
|
||||
834
|
||||
908
|
||||
774
|
||||
964
|
||||
880
|
||||
902
|
||||
234
|
||||
635
|
||||
138
|
||||
305
|
||||
532
|
||||
585
|
||||
956
|
||||
68
|
||||
21
|
||||
278
|
||||
639
|
||||
622
|
||||
473
|
||||
769
|
||||
161
|
||||
580
|
||||
285
|
||||
204
|
||||
410
|
||||
115
|
||||
430
|
||||
953
|
||||
968
|
||||
593
|
||||
703
|
||||
704
|
||||
469
|
||||
835
|
||||
623
|
||||
991
|
4
balakhonov_danila_lab_2/sigma_app_1/.dockerignore
Normal file
4
balakhonov_danila_lab_2/sigma_app_1/.dockerignore
Normal file
@ -0,0 +1,4 @@
|
||||
bin/
|
||||
obj/
|
||||
Dockerfile
|
||||
README.md
|
484
balakhonov_danila_lab_2/sigma_app_1/.gitignore
vendored
Normal file
484
balakhonov_danila_lab_2/sigma_app_1/.gitignore
vendored
Normal file
@ -0,0 +1,484 @@
|
||||
## Ignore Visual Studio temporary files, build results, and
|
||||
## files generated by popular Visual Studio add-ons.
|
||||
##
|
||||
## Get latest from `dotnet new gitignore`
|
||||
|
||||
# dotenv files
|
||||
.env
|
||||
|
||||
# User-specific files
|
||||
*.rsuser
|
||||
*.suo
|
||||
*.user
|
||||
*.userosscache
|
||||
*.sln.docstates
|
||||
|
||||
# User-specific files (MonoDevelop/Xamarin Studio)
|
||||
*.userprefs
|
||||
|
||||
# Mono auto generated files
|
||||
mono_crash.*
|
||||
|
||||
# Build results
|
||||
[Dd]ebug/
|
||||
[Dd]ebugPublic/
|
||||
[Rr]elease/
|
||||
[Rr]eleases/
|
||||
x64/
|
||||
x86/
|
||||
[Ww][Ii][Nn]32/
|
||||
[Aa][Rr][Mm]/
|
||||
[Aa][Rr][Mm]64/
|
||||
bld/
|
||||
[Bb]in/
|
||||
[Oo]bj/
|
||||
[Ll]og/
|
||||
[Ll]ogs/
|
||||
|
||||
# Visual Studio 2015/2017 cache/options directory
|
||||
.vs/
|
||||
# Uncomment if you have tasks that create the project's static files in wwwroot
|
||||
#wwwroot/
|
||||
|
||||
# Visual Studio 2017 auto generated files
|
||||
Generated\ Files/
|
||||
|
||||
# MSTest test Results
|
||||
[Tt]est[Rr]esult*/
|
||||
[Bb]uild[Ll]og.*
|
||||
|
||||
# NUnit
|
||||
*.VisualState.xml
|
||||
TestResult.xml
|
||||
nunit-*.xml
|
||||
|
||||
# Build Results of an ATL Project
|
||||
[Dd]ebugPS/
|
||||
[Rr]eleasePS/
|
||||
dlldata.c
|
||||
|
||||
# Benchmark Results
|
||||
BenchmarkDotNet.Artifacts/
|
||||
|
||||
# .NET
|
||||
project.lock.json
|
||||
project.fragment.lock.json
|
||||
artifacts/
|
||||
|
||||
# Tye
|
||||
.tye/
|
||||
|
||||
# ASP.NET Scaffolding
|
||||
ScaffoldingReadMe.txt
|
||||
|
||||
# StyleCop
|
||||
StyleCopReport.xml
|
||||
|
||||
# Files built by Visual Studio
|
||||
*_i.c
|
||||
*_p.c
|
||||
*_h.h
|
||||
*.ilk
|
||||
*.meta
|
||||
*.obj
|
||||
*.iobj
|
||||
*.pch
|
||||
*.pdb
|
||||
*.ipdb
|
||||
*.pgc
|
||||
*.pgd
|
||||
*.rsp
|
||||
*.sbr
|
||||
*.tlb
|
||||
*.tli
|
||||
*.tlh
|
||||
*.tmp
|
||||
*.tmp_proj
|
||||
*_wpftmp.csproj
|
||||
*.log
|
||||
*.tlog
|
||||
*.vspscc
|
||||
*.vssscc
|
||||
.builds
|
||||
*.pidb
|
||||
*.svclog
|
||||
*.scc
|
||||
|
||||
# Chutzpah Test files
|
||||
_Chutzpah*
|
||||
|
||||
# Visual C++ cache files
|
||||
ipch/
|
||||
*.aps
|
||||
*.ncb
|
||||
*.opendb
|
||||
*.opensdf
|
||||
*.sdf
|
||||
*.cachefile
|
||||
*.VC.db
|
||||
*.VC.VC.opendb
|
||||
|
||||
# Visual Studio profiler
|
||||
*.psess
|
||||
*.vsp
|
||||
*.vspx
|
||||
*.sap
|
||||
|
||||
# Visual Studio Trace Files
|
||||
*.e2e
|
||||
|
||||
# TFS 2012 Local Workspace
|
||||
$tf/
|
||||
|
||||
# Guidance Automation Toolkit
|
||||
*.gpState
|
||||
|
||||
# ReSharper is a .NET coding add-in
|
||||
_ReSharper*/
|
||||
*.[Rr]e[Ss]harper
|
||||
*.DotSettings.user
|
||||
|
||||
# TeamCity is a build add-in
|
||||
_TeamCity*
|
||||
|
||||
# DotCover is a Code Coverage Tool
|
||||
*.dotCover
|
||||
|
||||
# AxoCover is a Code Coverage Tool
|
||||
.axoCover/*
|
||||
!.axoCover/settings.json
|
||||
|
||||
# Coverlet is a free, cross platform Code Coverage Tool
|
||||
coverage*.json
|
||||
coverage*.xml
|
||||
coverage*.info
|
||||
|
||||
# Visual Studio code coverage results
|
||||
*.coverage
|
||||
*.coveragexml
|
||||
|
||||
# NCrunch
|
||||
_NCrunch_*
|
||||
.*crunch*.local.xml
|
||||
nCrunchTemp_*
|
||||
|
||||
# MightyMoose
|
||||
*.mm.*
|
||||
AutoTest.Net/
|
||||
|
||||
# Web workbench (sass)
|
||||
.sass-cache/
|
||||
|
||||
# Installshield output folder
|
||||
[Ee]xpress/
|
||||
|
||||
# DocProject is a documentation generator add-in
|
||||
DocProject/buildhelp/
|
||||
DocProject/Help/*.HxT
|
||||
DocProject/Help/*.HxC
|
||||
DocProject/Help/*.hhc
|
||||
DocProject/Help/*.hhk
|
||||
DocProject/Help/*.hhp
|
||||
DocProject/Help/Html2
|
||||
DocProject/Help/html
|
||||
|
||||
# Click-Once directory
|
||||
publish/
|
||||
|
||||
# Publish Web Output
|
||||
*.[Pp]ublish.xml
|
||||
*.azurePubxml
|
||||
# Note: Comment the next line if you want to checkin your web deploy settings,
|
||||
# but database connection strings (with potential passwords) will be unencrypted
|
||||
*.pubxml
|
||||
*.publishproj
|
||||
|
||||
# Microsoft Azure Web App publish settings. Comment the next line if you want to
|
||||
# checkin your Azure Web App publish settings, but sensitive information contained
|
||||
# in these scripts will be unencrypted
|
||||
PublishScripts/
|
||||
|
||||
# NuGet Packages
|
||||
*.nupkg
|
||||
# NuGet Symbol Packages
|
||||
*.snupkg
|
||||
# The packages folder can be ignored because of Package Restore
|
||||
**/[Pp]ackages/*
|
||||
# except build/, which is used as an MSBuild target.
|
||||
!**/[Pp]ackages/build/
|
||||
# Uncomment if necessary however generally it will be regenerated when needed
|
||||
#!**/[Pp]ackages/repositories.config
|
||||
# NuGet v3's project.json files produces more ignorable files
|
||||
*.nuget.props
|
||||
*.nuget.targets
|
||||
|
||||
# Microsoft Azure Build Output
|
||||
csx/
|
||||
*.build.csdef
|
||||
|
||||
# Microsoft Azure Emulator
|
||||
ecf/
|
||||
rcf/
|
||||
|
||||
# Windows Store app package directories and files
|
||||
AppPackages/
|
||||
BundleArtifacts/
|
||||
Package.StoreAssociation.xml
|
||||
_pkginfo.txt
|
||||
*.appx
|
||||
*.appxbundle
|
||||
*.appxupload
|
||||
|
||||
# Visual Studio cache files
|
||||
# files ending in .cache can be ignored
|
||||
*.[Cc]ache
|
||||
# but keep track of directories ending in .cache
|
||||
!?*.[Cc]ache/
|
||||
|
||||
# Others
|
||||
ClientBin/
|
||||
~$*
|
||||
*~
|
||||
*.dbmdl
|
||||
*.dbproj.schemaview
|
||||
*.jfm
|
||||
*.pfx
|
||||
*.publishsettings
|
||||
orleans.codegen.cs
|
||||
|
||||
# Including strong name files can present a security risk
|
||||
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
|
||||
#*.snk
|
||||
|
||||
# Since there are multiple workflows, uncomment next line to ignore bower_components
|
||||
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
|
||||
#bower_components/
|
||||
|
||||
# RIA/Silverlight projects
|
||||
Generated_Code/
|
||||
|
||||
# Backup & report files from converting an old project file
|
||||
# to a newer Visual Studio version. Backup files are not needed,
|
||||
# because we have git ;-)
|
||||
_UpgradeReport_Files/
|
||||
Backup*/
|
||||
UpgradeLog*.XML
|
||||
UpgradeLog*.htm
|
||||
ServiceFabricBackup/
|
||||
*.rptproj.bak
|
||||
|
||||
# SQL Server files
|
||||
*.mdf
|
||||
*.ldf
|
||||
*.ndf
|
||||
|
||||
# Business Intelligence projects
|
||||
*.rdl.data
|
||||
*.bim.layout
|
||||
*.bim_*.settings
|
||||
*.rptproj.rsuser
|
||||
*- [Bb]ackup.rdl
|
||||
*- [Bb]ackup ([0-9]).rdl
|
||||
*- [Bb]ackup ([0-9][0-9]).rdl
|
||||
|
||||
# Microsoft Fakes
|
||||
FakesAssemblies/
|
||||
|
||||
# GhostDoc plugin setting file
|
||||
*.GhostDoc.xml
|
||||
|
||||
# Node.js Tools for Visual Studio
|
||||
.ntvs_analysis.dat
|
||||
node_modules/
|
||||
|
||||
# Visual Studio 6 build log
|
||||
*.plg
|
||||
|
||||
# Visual Studio 6 workspace options file
|
||||
*.opt
|
||||
|
||||
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
|
||||
*.vbw
|
||||
|
||||
# Visual Studio 6 auto-generated project file (contains which files were open etc.)
|
||||
*.vbp
|
||||
|
||||
# Visual Studio 6 workspace and project file (working project files containing files to include in project)
|
||||
*.dsw
|
||||
*.dsp
|
||||
|
||||
# Visual Studio 6 technical files
|
||||
*.ncb
|
||||
*.aps
|
||||
|
||||
# Visual Studio LightSwitch build output
|
||||
**/*.HTMLClient/GeneratedArtifacts
|
||||
**/*.DesktopClient/GeneratedArtifacts
|
||||
**/*.DesktopClient/ModelManifest.xml
|
||||
**/*.Server/GeneratedArtifacts
|
||||
**/*.Server/ModelManifest.xml
|
||||
_Pvt_Extensions
|
||||
|
||||
# Paket dependency manager
|
||||
.paket/paket.exe
|
||||
paket-files/
|
||||
|
||||
# FAKE - F# Make
|
||||
.fake/
|
||||
|
||||
# CodeRush personal settings
|
||||
.cr/personal
|
||||
|
||||
# Python Tools for Visual Studio (PTVS)
|
||||
__pycache__/
|
||||
*.pyc
|
||||
|
||||
# Cake - Uncomment if you are using it
|
||||
# tools/**
|
||||
# !tools/packages.config
|
||||
|
||||
# Tabs Studio
|
||||
*.tss
|
||||
|
||||
# Telerik's JustMock configuration file
|
||||
*.jmconfig
|
||||
|
||||
# BizTalk build output
|
||||
*.btp.cs
|
||||
*.btm.cs
|
||||
*.odx.cs
|
||||
*.xsd.cs
|
||||
|
||||
# OpenCover UI analysis results
|
||||
OpenCover/
|
||||
|
||||
# Azure Stream Analytics local run output
|
||||
ASALocalRun/
|
||||
|
||||
# MSBuild Binary and Structured Log
|
||||
*.binlog
|
||||
|
||||
# NVidia Nsight GPU debugger configuration file
|
||||
*.nvuser
|
||||
|
||||
# MFractors (Xamarin productivity tool) working folder
|
||||
.mfractor/
|
||||
|
||||
# Local History for Visual Studio
|
||||
.localhistory/
|
||||
|
||||
# Visual Studio History (VSHistory) files
|
||||
.vshistory/
|
||||
|
||||
# BeatPulse healthcheck temp database
|
||||
healthchecksdb
|
||||
|
||||
# Backup folder for Package Reference Convert tool in Visual Studio 2017
|
||||
MigrationBackup/
|
||||
|
||||
# Ionide (cross platform F# VS Code tools) working folder
|
||||
.ionide/
|
||||
|
||||
# Fody - auto-generated XML schema
|
||||
FodyWeavers.xsd
|
||||
|
||||
# VS Code files for those working on multiple tools
|
||||
.vscode/*
|
||||
!.vscode/settings.json
|
||||
!.vscode/tasks.json
|
||||
!.vscode/launch.json
|
||||
!.vscode/extensions.json
|
||||
*.code-workspace
|
||||
|
||||
# Local History for Visual Studio Code
|
||||
.history/
|
||||
|
||||
# Windows Installer files from build outputs
|
||||
*.cab
|
||||
*.msi
|
||||
*.msix
|
||||
*.msm
|
||||
*.msp
|
||||
|
||||
# JetBrains Rider
|
||||
*.sln.iml
|
||||
.idea
|
||||
|
||||
##
|
||||
## Visual studio for Mac
|
||||
##
|
||||
|
||||
|
||||
# globs
|
||||
Makefile.in
|
||||
*.userprefs
|
||||
*.usertasks
|
||||
config.make
|
||||
config.status
|
||||
aclocal.m4
|
||||
install-sh
|
||||
autom4te.cache/
|
||||
*.tar.gz
|
||||
tarballs/
|
||||
test-results/
|
||||
|
||||
# Mac bundle stuff
|
||||
*.dmg
|
||||
*.app
|
||||
|
||||
# content below from: https://github.com/github/gitignore/blob/master/Global/macOS.gitignore
|
||||
# General
|
||||
.DS_Store
|
||||
.AppleDouble
|
||||
.LSOverride
|
||||
|
||||
# Icon must end with two \r
|
||||
Icon
|
||||
|
||||
|
||||
# Thumbnails
|
||||
._*
|
||||
|
||||
# Files that might appear in the root of a volume
|
||||
.DocumentRevisions-V100
|
||||
.fseventsd
|
||||
.Spotlight-V100
|
||||
.TemporaryItems
|
||||
.Trashes
|
||||
.VolumeIcon.icns
|
||||
.com.apple.timemachine.donotpresent
|
||||
|
||||
# Directories potentially created on remote AFP share
|
||||
.AppleDB
|
||||
.AppleDesktop
|
||||
Network Trash Folder
|
||||
Temporary Items
|
||||
.apdisk
|
||||
|
||||
# content below from: https://github.com/github/gitignore/blob/master/Global/Windows.gitignore
|
||||
# Windows thumbnail cache files
|
||||
Thumbs.db
|
||||
ehthumbs.db
|
||||
ehthumbs_vista.db
|
||||
|
||||
# Dump file
|
||||
*.stackdump
|
||||
|
||||
# Folder config file
|
||||
[Dd]esktop.ini
|
||||
|
||||
# Recycle Bin used on file shares
|
||||
$RECYCLE.BIN/
|
||||
|
||||
# Windows Installer files
|
||||
*.cab
|
||||
*.msi
|
||||
*.msix
|
||||
*.msm
|
||||
*.msp
|
||||
|
||||
# Windows shortcuts
|
||||
*.lnk
|
||||
|
||||
# Vim temporary swap files
|
||||
*.swp
|
14
balakhonov_danila_lab_2/sigma_app_1/Dockerfile
Normal file
14
balakhonov_danila_lab_2/sigma_app_1/Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
||||
WORKDIR /App
|
||||
|
||||
# Copy everything
|
||||
COPY . ./
|
||||
# Restore as distinct layers
|
||||
RUN dotnet restore
|
||||
# Build and publish a release
|
||||
RUN dotnet publish -c Release -o out
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/runtime:8.0 AS runtime
|
||||
WORKDIR /App
|
||||
COPY --from=build /App/out .
|
||||
ENTRYPOINT ["dotnet", "sigma_app_1.dll"]
|
14
balakhonov_danila_lab_2/sigma_app_1/Program.fs
Normal file
14
balakhonov_danila_lab_2/sigma_app_1/Program.fs
Normal file
@ -0,0 +1,14 @@
|
||||
let PATH = @"/var/data/"
|
||||
let RESULT_PATH = @"/var/result/data.txt"
|
||||
|
||||
let getFiles(path: string): seq<string> =
|
||||
System.IO.Directory.EnumerateFiles(path)
|
||||
|
||||
let getRandFile(files: seq<string>) =
|
||||
let rand = System.Random()
|
||||
let index = rand.Next(Seq.length files)
|
||||
Seq.item index files
|
||||
|
||||
let files = getFiles(PATH)
|
||||
let randFile = getRandFile(files)
|
||||
System.IO.File.Copy(randFile, RESULT_PATH)
|
4
balakhonov_danila_lab_2/sigma_app_1/README.md
Normal file
4
balakhonov_danila_lab_2/sigma_app_1/README.md
Normal file
@ -0,0 +1,4 @@
|
||||
# Первая программа лабораторной работы номер 2
|
||||
> Вариант 6
|
||||
>
|
||||
> Берёт из каталога `/var/data` случайный файл и перекладывает его в `/var/result/data.txt`
|
12
balakhonov_danila_lab_2/sigma_app_1/sigma_app_1.fsproj
Normal file
12
balakhonov_danila_lab_2/sigma_app_1/sigma_app_1.fsproj
Normal file
@ -0,0 +1,12 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="Program.fs" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
4
balakhonov_danila_lab_2/skibidi_app_2/.dockerignore
Normal file
4
balakhonov_danila_lab_2/skibidi_app_2/.dockerignore
Normal file
@ -0,0 +1,4 @@
|
||||
bin/
|
||||
obj/
|
||||
Dockerfile
|
||||
README.md
|
484
balakhonov_danila_lab_2/skibidi_app_2/.gitignore
vendored
Normal file
484
balakhonov_danila_lab_2/skibidi_app_2/.gitignore
vendored
Normal file
@ -0,0 +1,484 @@
|
||||
## Ignore Visual Studio temporary files, build results, and
|
||||
## files generated by popular Visual Studio add-ons.
|
||||
##
|
||||
## Get latest from `dotnet new gitignore`
|
||||
|
||||
# dotenv files
|
||||
.env
|
||||
|
||||
# User-specific files
|
||||
*.rsuser
|
||||
*.suo
|
||||
*.user
|
||||
*.userosscache
|
||||
*.sln.docstates
|
||||
|
||||
# User-specific files (MonoDevelop/Xamarin Studio)
|
||||
*.userprefs
|
||||
|
||||
# Mono auto generated files
|
||||
mono_crash.*
|
||||
|
||||
# Build results
|
||||
[Dd]ebug/
|
||||
[Dd]ebugPublic/
|
||||
[Rr]elease/
|
||||
[Rr]eleases/
|
||||
x64/
|
||||
x86/
|
||||
[Ww][Ii][Nn]32/
|
||||
[Aa][Rr][Mm]/
|
||||
[Aa][Rr][Mm]64/
|
||||
bld/
|
||||
[Bb]in/
|
||||
[Oo]bj/
|
||||
[Ll]og/
|
||||
[Ll]ogs/
|
||||
|
||||
# Visual Studio 2015/2017 cache/options directory
|
||||
.vs/
|
||||
# Uncomment if you have tasks that create the project's static files in wwwroot
|
||||
#wwwroot/
|
||||
|
||||
# Visual Studio 2017 auto generated files
|
||||
Generated\ Files/
|
||||
|
||||
# MSTest test Results
|
||||
[Tt]est[Rr]esult*/
|
||||
[Bb]uild[Ll]og.*
|
||||
|
||||
# NUnit
|
||||
*.VisualState.xml
|
||||
TestResult.xml
|
||||
nunit-*.xml
|
||||
|
||||
# Build Results of an ATL Project
|
||||
[Dd]ebugPS/
|
||||
[Rr]eleasePS/
|
||||
dlldata.c
|
||||
|
||||
# Benchmark Results
|
||||
BenchmarkDotNet.Artifacts/
|
||||
|
||||
# .NET
|
||||
project.lock.json
|
||||
project.fragment.lock.json
|
||||
artifacts/
|
||||
|
||||
# Tye
|
||||
.tye/
|
||||
|
||||
# ASP.NET Scaffolding
|
||||
ScaffoldingReadMe.txt
|
||||
|
||||
# StyleCop
|
||||
StyleCopReport.xml
|
||||
|
||||
# Files built by Visual Studio
|
||||
*_i.c
|
||||
*_p.c
|
||||
*_h.h
|
||||
*.ilk
|
||||
*.meta
|
||||
*.obj
|
||||
*.iobj
|
||||
*.pch
|
||||
*.pdb
|
||||
*.ipdb
|
||||
*.pgc
|
||||
*.pgd
|
||||
*.rsp
|
||||
*.sbr
|
||||
*.tlb
|
||||
*.tli
|
||||
*.tlh
|
||||
*.tmp
|
||||
*.tmp_proj
|
||||
*_wpftmp.csproj
|
||||
*.log
|
||||
*.tlog
|
||||
*.vspscc
|
||||
*.vssscc
|
||||
.builds
|
||||
*.pidb
|
||||
*.svclog
|
||||
*.scc
|
||||
|
||||
# Chutzpah Test files
|
||||
_Chutzpah*
|
||||
|
||||
# Visual C++ cache files
|
||||
ipch/
|
||||
*.aps
|
||||
*.ncb
|
||||
*.opendb
|
||||
*.opensdf
|
||||
*.sdf
|
||||
*.cachefile
|
||||
*.VC.db
|
||||
*.VC.VC.opendb
|
||||
|
||||
# Visual Studio profiler
|
||||
*.psess
|
||||
*.vsp
|
||||
*.vspx
|
||||
*.sap
|
||||
|
||||
# Visual Studio Trace Files
|
||||
*.e2e
|
||||
|
||||
# TFS 2012 Local Workspace
|
||||
$tf/
|
||||
|
||||
# Guidance Automation Toolkit
|
||||
*.gpState
|
||||
|
||||
# ReSharper is a .NET coding add-in
|
||||
_ReSharper*/
|
||||
*.[Rr]e[Ss]harper
|
||||
*.DotSettings.user
|
||||
|
||||
# TeamCity is a build add-in
|
||||
_TeamCity*
|
||||
|
||||
# DotCover is a Code Coverage Tool
|
||||
*.dotCover
|
||||
|
||||
# AxoCover is a Code Coverage Tool
|
||||
.axoCover/*
|
||||
!.axoCover/settings.json
|
||||
|
||||
# Coverlet is a free, cross platform Code Coverage Tool
|
||||
coverage*.json
|
||||
coverage*.xml
|
||||
coverage*.info
|
||||
|
||||
# Visual Studio code coverage results
|
||||
*.coverage
|
||||
*.coveragexml
|
||||
|
||||
# NCrunch
|
||||
_NCrunch_*
|
||||
.*crunch*.local.xml
|
||||
nCrunchTemp_*
|
||||
|
||||
# MightyMoose
|
||||
*.mm.*
|
||||
AutoTest.Net/
|
||||
|
||||
# Web workbench (sass)
|
||||
.sass-cache/
|
||||
|
||||
# Installshield output folder
|
||||
[Ee]xpress/
|
||||
|
||||
# DocProject is a documentation generator add-in
|
||||
DocProject/buildhelp/
|
||||
DocProject/Help/*.HxT
|
||||
DocProject/Help/*.HxC
|
||||
DocProject/Help/*.hhc
|
||||
DocProject/Help/*.hhk
|
||||
DocProject/Help/*.hhp
|
||||
DocProject/Help/Html2
|
||||
DocProject/Help/html
|
||||
|
||||
# Click-Once directory
|
||||
publish/
|
||||
|
||||
# Publish Web Output
|
||||
*.[Pp]ublish.xml
|
||||
*.azurePubxml
|
||||
# Note: Comment the next line if you want to checkin your web deploy settings,
|
||||
# but database connection strings (with potential passwords) will be unencrypted
|
||||
*.pubxml
|
||||
*.publishproj
|
||||
|
||||
# Microsoft Azure Web App publish settings. Comment the next line if you want to
|
||||
# checkin your Azure Web App publish settings, but sensitive information contained
|
||||
# in these scripts will be unencrypted
|
||||
PublishScripts/
|
||||
|
||||
# NuGet Packages
|
||||
*.nupkg
|
||||
# NuGet Symbol Packages
|
||||
*.snupkg
|
||||
# The packages folder can be ignored because of Package Restore
|
||||
**/[Pp]ackages/*
|
||||
# except build/, which is used as an MSBuild target.
|
||||
!**/[Pp]ackages/build/
|
||||
# Uncomment if necessary however generally it will be regenerated when needed
|
||||
#!**/[Pp]ackages/repositories.config
|
||||
# NuGet v3's project.json files produces more ignorable files
|
||||
*.nuget.props
|
||||
*.nuget.targets
|
||||
|
||||
# Microsoft Azure Build Output
|
||||
csx/
|
||||
*.build.csdef
|
||||
|
||||
# Microsoft Azure Emulator
|
||||
ecf/
|
||||
rcf/
|
||||
|
||||
# Windows Store app package directories and files
|
||||
AppPackages/
|
||||
BundleArtifacts/
|
||||
Package.StoreAssociation.xml
|
||||
_pkginfo.txt
|
||||
*.appx
|
||||
*.appxbundle
|
||||
*.appxupload
|
||||
|
||||
# Visual Studio cache files
|
||||
# files ending in .cache can be ignored
|
||||
*.[Cc]ache
|
||||
# but keep track of directories ending in .cache
|
||||
!?*.[Cc]ache/
|
||||
|
||||
# Others
|
||||
ClientBin/
|
||||
~$*
|
||||
*~
|
||||
*.dbmdl
|
||||
*.dbproj.schemaview
|
||||
*.jfm
|
||||
*.pfx
|
||||
*.publishsettings
|
||||
orleans.codegen.cs
|
||||
|
||||
# Including strong name files can present a security risk
|
||||
# (https://github.com/github/gitignore/pull/2483#issue-259490424)
|
||||
#*.snk
|
||||
|
||||
# Since there are multiple workflows, uncomment next line to ignore bower_components
|
||||
# (https://github.com/github/gitignore/pull/1529#issuecomment-104372622)
|
||||
#bower_components/
|
||||
|
||||
# RIA/Silverlight projects
|
||||
Generated_Code/
|
||||
|
||||
# Backup & report files from converting an old project file
|
||||
# to a newer Visual Studio version. Backup files are not needed,
|
||||
# because we have git ;-)
|
||||
_UpgradeReport_Files/
|
||||
Backup*/
|
||||
UpgradeLog*.XML
|
||||
UpgradeLog*.htm
|
||||
ServiceFabricBackup/
|
||||
*.rptproj.bak
|
||||
|
||||
# SQL Server files
|
||||
*.mdf
|
||||
*.ldf
|
||||
*.ndf
|
||||
|
||||
# Business Intelligence projects
|
||||
*.rdl.data
|
||||
*.bim.layout
|
||||
*.bim_*.settings
|
||||
*.rptproj.rsuser
|
||||
*- [Bb]ackup.rdl
|
||||
*- [Bb]ackup ([0-9]).rdl
|
||||
*- [Bb]ackup ([0-9][0-9]).rdl
|
||||
|
||||
# Microsoft Fakes
|
||||
FakesAssemblies/
|
||||
|
||||
# GhostDoc plugin setting file
|
||||
*.GhostDoc.xml
|
||||
|
||||
# Node.js Tools for Visual Studio
|
||||
.ntvs_analysis.dat
|
||||
node_modules/
|
||||
|
||||
# Visual Studio 6 build log
|
||||
*.plg
|
||||
|
||||
# Visual Studio 6 workspace options file
|
||||
*.opt
|
||||
|
||||
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
|
||||
*.vbw
|
||||
|
||||
# Visual Studio 6 auto-generated project file (contains which files were open etc.)
|
||||
*.vbp
|
||||
|
||||
# Visual Studio 6 workspace and project file (working project files containing files to include in project)
|
||||
*.dsw
|
||||
*.dsp
|
||||
|
||||
# Visual Studio 6 technical files
|
||||
*.ncb
|
||||
*.aps
|
||||
|
||||
# Visual Studio LightSwitch build output
|
||||
**/*.HTMLClient/GeneratedArtifacts
|
||||
**/*.DesktopClient/GeneratedArtifacts
|
||||
**/*.DesktopClient/ModelManifest.xml
|
||||
**/*.Server/GeneratedArtifacts
|
||||
**/*.Server/ModelManifest.xml
|
||||
_Pvt_Extensions
|
||||
|
||||
# Paket dependency manager
|
||||
.paket/paket.exe
|
||||
paket-files/
|
||||
|
||||
# FAKE - F# Make
|
||||
.fake/
|
||||
|
||||
# CodeRush personal settings
|
||||
.cr/personal
|
||||
|
||||
# Python Tools for Visual Studio (PTVS)
|
||||
__pycache__/
|
||||
*.pyc
|
||||
|
||||
# Cake - Uncomment if you are using it
|
||||
# tools/**
|
||||
# !tools/packages.config
|
||||
|
||||
# Tabs Studio
|
||||
*.tss
|
||||
|
||||
# Telerik's JustMock configuration file
|
||||
*.jmconfig
|
||||
|
||||
# BizTalk build output
|
||||
*.btp.cs
|
||||
*.btm.cs
|
||||
*.odx.cs
|
||||
*.xsd.cs
|
||||
|
||||
# OpenCover UI analysis results
|
||||
OpenCover/
|
||||
|
||||
# Azure Stream Analytics local run output
|
||||
ASALocalRun/
|
||||
|
||||
# MSBuild Binary and Structured Log
|
||||
*.binlog
|
||||
|
||||
# NVidia Nsight GPU debugger configuration file
|
||||
*.nvuser
|
||||
|
||||
# MFractors (Xamarin productivity tool) working folder
|
||||
.mfractor/
|
||||
|
||||
# Local History for Visual Studio
|
||||
.localhistory/
|
||||
|
||||
# Visual Studio History (VSHistory) files
|
||||
.vshistory/
|
||||
|
||||
# BeatPulse healthcheck temp database
|
||||
healthchecksdb
|
||||
|
||||
# Backup folder for Package Reference Convert tool in Visual Studio 2017
|
||||
MigrationBackup/
|
||||
|
||||
# Ionide (cross platform F# VS Code tools) working folder
|
||||
.ionide/
|
||||
|
||||
# Fody - auto-generated XML schema
|
||||
FodyWeavers.xsd
|
||||
|
||||
# VS Code files for those working on multiple tools
|
||||
.vscode/*
|
||||
!.vscode/settings.json
|
||||
!.vscode/tasks.json
|
||||
!.vscode/launch.json
|
||||
!.vscode/extensions.json
|
||||
*.code-workspace
|
||||
|
||||
# Local History for Visual Studio Code
|
||||
.history/
|
||||
|
||||
# Windows Installer files from build outputs
|
||||
*.cab
|
||||
*.msi
|
||||
*.msix
|
||||
*.msm
|
||||
*.msp
|
||||
|
||||
# JetBrains Rider
|
||||
*.sln.iml
|
||||
.idea
|
||||
|
||||
##
|
||||
## Visual studio for Mac
|
||||
##
|
||||
|
||||
|
||||
# globs
|
||||
Makefile.in
|
||||
*.userprefs
|
||||
*.usertasks
|
||||
config.make
|
||||
config.status
|
||||
aclocal.m4
|
||||
install-sh
|
||||
autom4te.cache/
|
||||
*.tar.gz
|
||||
tarballs/
|
||||
test-results/
|
||||
|
||||
# Mac bundle stuff
|
||||
*.dmg
|
||||
*.app
|
||||
|
||||
# content below from: https://github.com/github/gitignore/blob/master/Global/macOS.gitignore
|
||||
# General
|
||||
.DS_Store
|
||||
.AppleDouble
|
||||
.LSOverride
|
||||
|
||||
# Icon must end with two \r
|
||||
Icon
|
||||
|
||||
|
||||
# Thumbnails
|
||||
._*
|
||||
|
||||
# Files that might appear in the root of a volume
|
||||
.DocumentRevisions-V100
|
||||
.fseventsd
|
||||
.Spotlight-V100
|
||||
.TemporaryItems
|
||||
.Trashes
|
||||
.VolumeIcon.icns
|
||||
.com.apple.timemachine.donotpresent
|
||||
|
||||
# Directories potentially created on remote AFP share
|
||||
.AppleDB
|
||||
.AppleDesktop
|
||||
Network Trash Folder
|
||||
Temporary Items
|
||||
.apdisk
|
||||
|
||||
# content below from: https://github.com/github/gitignore/blob/master/Global/Windows.gitignore
|
||||
# Windows thumbnail cache files
|
||||
Thumbs.db
|
||||
ehthumbs.db
|
||||
ehthumbs_vista.db
|
||||
|
||||
# Dump file
|
||||
*.stackdump
|
||||
|
||||
# Folder config file
|
||||
[Dd]esktop.ini
|
||||
|
||||
# Recycle Bin used on file shares
|
||||
$RECYCLE.BIN/
|
||||
|
||||
# Windows Installer files
|
||||
*.cab
|
||||
*.msi
|
||||
*.msix
|
||||
*.msm
|
||||
*.msp
|
||||
|
||||
# Windows shortcuts
|
||||
*.lnk
|
||||
|
||||
# Vim temporary swap files
|
||||
*.swp
|
14
balakhonov_danila_lab_2/skibidi_app_2/Dockerfile
Normal file
14
balakhonov_danila_lab_2/skibidi_app_2/Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
FROM mcr.microsoft.com/dotnet/sdk:8.0 AS build
|
||||
WORKDIR /App
|
||||
|
||||
# Copy everything
|
||||
COPY . ./
|
||||
# Restore as distinct layers
|
||||
RUN dotnet restore
|
||||
# Build and publish a release
|
||||
RUN dotnet publish -c Release -o out
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/runtime:8.0 AS runtime
|
||||
WORKDIR /App
|
||||
COPY --from=build /App/out .
|
||||
ENTRYPOINT ["dotnet", "skibidi_app_2.dll"]
|
16
balakhonov_danila_lab_2/skibidi_app_2/Program.fs
Normal file
16
balakhonov_danila_lab_2/skibidi_app_2/Program.fs
Normal file
@ -0,0 +1,16 @@
|
||||
let INPUT_FILE = @"/var/result/data.txt"
|
||||
let OUTPUT_FILE = @"/var/result/result.txt"
|
||||
|
||||
let getNumbersFromFile(path: string): seq<int> =
|
||||
System.IO.File.ReadLines(path)
|
||||
|> Seq.map int
|
||||
|
||||
let getCountOfMaxNumber(numbers: seq<int>): int =
|
||||
numbers
|
||||
|> Seq.max
|
||||
|> fun maxNum -> Seq.filter ((=) maxNum) numbers
|
||||
|> Seq.length
|
||||
|
||||
let numbers = getNumbersFromFile(INPUT_FILE)
|
||||
let count = getCountOfMaxNumber(numbers)
|
||||
System.IO.File.WriteAllText(OUTPUT_FILE, string count)
|
4
balakhonov_danila_lab_2/skibidi_app_2/README.md
Normal file
4
balakhonov_danila_lab_2/skibidi_app_2/README.md
Normal file
@ -0,0 +1,4 @@
|
||||
# Вторая программа лабораторной работы номер 2
|
||||
> Вариант 3
|
||||
>
|
||||
> Ищет набольшее число из файла `/var/result/data.txt` и сохраняет количество таких чисел из последовательности в `/var/result/result.txt`
|
12
balakhonov_danila_lab_2/skibidi_app_2/skibidi_app_2.fsproj
Normal file
12
balakhonov_danila_lab_2/skibidi_app_2/skibidi_app_2.fsproj
Normal file
@ -0,0 +1,12 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net8.0</TargetFramework>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<Compile Include="Program.fs" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
2
bazunov_andrew_lab_1/.gitignore
vendored
Normal file
2
bazunov_andrew_lab_1/.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
ollama
|
||||
./ollama
|
33
bazunov_andrew_lab_1/README.md
Normal file
33
bazunov_andrew_lab_1/README.md
Normal file
@ -0,0 +1,33 @@
|
||||
# Распределенные вычисления и приложения Л1
|
||||
## _Автор Базунов Андрей Игревич ПИбд-42_
|
||||
|
||||
В качестве сервисов были выбраны:
|
||||
- 1.Ollama (_Сервис для использования LLMs моделей_)
|
||||
- 2.Open Web Ui (_Сервис для удобного общения с моделью из сервиса Ollama_)
|
||||
- 3.Gitea (_Гит сервис_)
|
||||
|
||||
# Docker
|
||||
|
||||
>Перед исполнением вполняем установку docker и проверяем версию
|
||||
|
||||
```sh
|
||||
docker-compose --version
|
||||
```
|
||||
|
||||
>Далее производим настройку файла docker-compose.yaml и запускаем контейнер
|
||||
|
||||
```sh
|
||||
docker-compose up -d
|
||||
```
|
||||
|
||||
>Для завершения работы контейнера используем команду
|
||||
```sh
|
||||
docker-compose down
|
||||
```
|
||||
---
|
||||
> Замечание: после запуска контейнера, необходимо перейти в контейнер **ollamа** и выполнить установку модели [gemma2](https://ollama.com/library/gemma2:2b)
|
||||
> ```sh
|
||||
> docker-compose exec ollama ollama run ollama run gemma2:2b
|
||||
> ```
|
||||
---
|
||||
Далее можно использовать веб сервис Open Web Ui по адресу **localhost:8080** для общения с моделью и Gitea по адресу **localhost:3000** - [демонстрация работы](https://vk.com/video/@viltskaa?z=video236673313_456239574%2Fpl_236673313_-2)
|
61
bazunov_andrew_lab_1/docker-compose.yml
Normal file
61
bazunov_andrew_lab_1/docker-compose.yml
Normal file
@ -0,0 +1,61 @@
|
||||
services:
|
||||
gitea: # Имя сервиса
|
||||
image: gitea/gitea:latest # Имя образа
|
||||
container_name: gitea # Имя контейнера, может быть произовольным
|
||||
ports:
|
||||
- "3000:3000" # Проброс порта Gitea на хост
|
||||
volumes: # хранилище
|
||||
- data:/data
|
||||
environment: # переменные окружения
|
||||
USER_UID: 1000
|
||||
USER_GID: 1000
|
||||
|
||||
ollama:
|
||||
image: ollama/ollama:latest
|
||||
container_name: ollama
|
||||
restart: always
|
||||
ports:
|
||||
- 7869:11434
|
||||
pull_policy: always
|
||||
tty: true
|
||||
volumes:
|
||||
- .:/code
|
||||
- ./ollama/ollama:/root/.ollama # Директория для данных Ollama
|
||||
environment:
|
||||
- OLLAMA_KEEP_ALIVE=24h
|
||||
- OLLAMA_HOST=0.0.0.0 # Указываем хост для API Ollama
|
||||
networks:
|
||||
- ollama-docker
|
||||
command: ["serve"] # Запускаем Ollama в режиме сервера
|
||||
|
||||
ollama-webui:
|
||||
image: ghcr.io/open-webui/open-webui:main # Образ Open Web UI
|
||||
container_name: ollama-webui
|
||||
restart: unless-stopped
|
||||
volumes:
|
||||
- ./ollama/ollama-webui:/app/backend/data
|
||||
ports:
|
||||
- 8080:8080 # Порт для веб-интерфейса
|
||||
environment: # https://docs.openwebui.com/getting-started/env-configuration#default_models
|
||||
- OLLAMA_BASE_URLS=http://host.docker.internal:7869
|
||||
- ENV=dev
|
||||
- WEBUI_AUTH=False
|
||||
- WEBUI_NAME=Viltskaa AI
|
||||
- WEBUI_URL=http://localhost:8080
|
||||
- WEBUI_SECRET_KEY=t0p-s3cr3t
|
||||
depends_on:
|
||||
- ollama
|
||||
extra_hosts:
|
||||
- host.docker.internal:host-gateway
|
||||
networks:
|
||||
- ollama-docker
|
||||
|
||||
networks:
|
||||
ollama-docker:
|
||||
external: false
|
||||
|
||||
volumes:
|
||||
ollama:
|
||||
driver: local
|
||||
data:
|
||||
driver: local
|
14
bazunov_andrew_lab_2/FileCreator/Dockerfile
Normal file
14
bazunov_andrew_lab_2/FileCreator/Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
# Используем официальный образ Go в качестве базового
|
||||
FROM golang:1.23
|
||||
|
||||
# Устанавливаем рабочую директорию
|
||||
WORKDIR /app
|
||||
|
||||
# Копируем файлы модуля
|
||||
COPY . .
|
||||
|
||||
# Сборка модуля
|
||||
RUN go build -o /bin/FileCreator
|
||||
|
||||
# Запуск модуля
|
||||
CMD ["/bin/FileCreator"]
|
1
bazunov_andrew_lab_2/FileCreator/go.mod
Normal file
1
bazunov_andrew_lab_2/FileCreator/go.mod
Normal file
@ -0,0 +1 @@
|
||||
module FileCreator
|
92
bazunov_andrew_lab_2/FileCreator/main.go
Normal file
92
bazunov_andrew_lab_2/FileCreator/main.go
Normal file
@ -0,0 +1,92 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"crypto/md5"
|
||||
"encoding/hex"
|
||||
"fmt"
|
||||
"math/rand"
|
||||
"os"
|
||||
"path/filepath"
|
||||
)
|
||||
|
||||
const DIR = "/var/data"
|
||||
|
||||
func Exists(name string) (bool, error) {
|
||||
_, err := os.Stat(name)
|
||||
if os.IsNotExist(err) {
|
||||
return false, nil
|
||||
}
|
||||
return err != nil, err
|
||||
}
|
||||
|
||||
func CreateDirectory(dirs string) error {
|
||||
if _, err := os.Stat(dirs); os.IsNotExist(err) {
|
||||
err := os.MkdirAll(dirs, 0664)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func CreateFileOrOpenIfExist(name string) (*os.File, error) {
|
||||
err := CreateDirectory(filepath.Dir(name))
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
exists, err := Exists(name)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if exists {
|
||||
return os.OpenFile(name, os.O_WRONLY|os.O_CREATE, 0664)
|
||||
}
|
||||
return os.Create(name)
|
||||
}
|
||||
|
||||
func CreateFileAndWriteData(filename string) error {
|
||||
file, err := CreateFileOrOpenIfExist(filename)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
lines := rand.Intn(1000) + 100
|
||||
|
||||
for i := 0; i < lines; i++ {
|
||||
randomValueForLine := rand.Intn(1_000_000)
|
||||
_, err = fmt.Fprintf(file, "%d\r\n", randomValueForLine)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
err = file.Close()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func GetMD5Hash(text string) string {
|
||||
hash := md5.Sum([]byte(text))
|
||||
return hex.EncodeToString(hash[:])
|
||||
}
|
||||
|
||||
func main() {
|
||||
for i := 0; i < 10; i++ {
|
||||
filename := fmt.Sprintf("%s/%s.txt", DIR, GetMD5Hash(fmt.Sprintf("%d", i)))
|
||||
err := CreateFileAndWriteData(filename)
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
} else {
|
||||
fmt.Printf("Created file %s\n", filename)
|
||||
}
|
||||
}
|
||||
|
||||
err := CreateFileAndWriteData(DIR + "/data.txt")
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
} else {
|
||||
fmt.Printf("Created file %s\n", DIR+"/data.txt")
|
||||
}
|
||||
}
|
14
bazunov_andrew_lab_2/FirstService/Dockerfile
Normal file
14
bazunov_andrew_lab_2/FirstService/Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
# Используем официальный образ Go в качестве базового
|
||||
FROM golang:1.23
|
||||
|
||||
# Устанавливаем рабочую директорию
|
||||
WORKDIR /app
|
||||
|
||||
# Копируем файлы модуля
|
||||
COPY . .
|
||||
|
||||
# Сборка модуля
|
||||
RUN go build -o /bin/FirstService
|
||||
|
||||
# Запуск модуля
|
||||
CMD ["/bin/FirstService"]
|
1
bazunov_andrew_lab_2/FirstService/go.mod
Normal file
1
bazunov_andrew_lab_2/FirstService/go.mod
Normal file
@ -0,0 +1 @@
|
||||
module RVIP2
|
94
bazunov_andrew_lab_2/FirstService/main.go
Normal file
94
bazunov_andrew_lab_2/FirstService/main.go
Normal file
@ -0,0 +1,94 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"fmt"
|
||||
"os"
|
||||
)
|
||||
|
||||
// Формирует файл /var/result/data.txt так,
|
||||
// что каждая строка файла - количество символов в именах файлов из каталога /var/data.
|
||||
|
||||
const INPUT = "/var/data"
|
||||
const OUTPUT = "/data/result"
|
||||
|
||||
func GetListFilesInDirectory(directory string) ([]string, error) {
|
||||
f, err := os.Open(directory)
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
return nil, err
|
||||
}
|
||||
files, err := f.Readdir(0)
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
return nil, err
|
||||
}
|
||||
|
||||
var fileNames []string
|
||||
for _, file := range files {
|
||||
fileName := file.Name()
|
||||
fileNames = append(fileNames, fileName)
|
||||
}
|
||||
return fileNames, nil
|
||||
}
|
||||
|
||||
func Exists(name string) (bool, error) {
|
||||
_, err := os.Stat(name)
|
||||
if os.IsNotExist(err) {
|
||||
return false, nil
|
||||
}
|
||||
return err != nil, err
|
||||
}
|
||||
|
||||
func CreateFileOrOpenIfExist(name string) (*os.File, error) {
|
||||
exists, err := Exists(name)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
if exists {
|
||||
return os.OpenFile(name, os.O_WRONLY|os.O_CREATE, 0664)
|
||||
}
|
||||
return os.Create(name)
|
||||
}
|
||||
|
||||
func CreateFileAndWriteData(filename string, lines []string) error {
|
||||
file, err := CreateFileOrOpenIfExist(filename)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
for _, line := range lines {
|
||||
_, err = fmt.Fprintf(file, line)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
}
|
||||
|
||||
err = file.Close()
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
return nil
|
||||
}
|
||||
|
||||
func main() {
|
||||
filenames, err := GetListFilesInDirectory(INPUT)
|
||||
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
return
|
||||
}
|
||||
|
||||
var lenghtOfFilenames []string
|
||||
for _, filename := range filenames {
|
||||
fmt.Println(filename)
|
||||
lenghtOfFilenames = append(lenghtOfFilenames, fmt.Sprintf("%d", len(filename)))
|
||||
}
|
||||
|
||||
err = CreateFileAndWriteData(OUTPUT+"/data.txt", filenames)
|
||||
if err != nil {
|
||||
return
|
||||
}
|
||||
|
||||
fmt.Println("First Service is end.")
|
||||
}
|
30
bazunov_andrew_lab_2/README.md
Normal file
30
bazunov_andrew_lab_2/README.md
Normal file
@ -0,0 +1,30 @@
|
||||
# Распределенные вычисления и приложения Л2
|
||||
## _Автор Базунов Андрей Игревич ПИбд-42_
|
||||
|
||||
Сервисы ( _порядок исполнения сервисов соблюден_ ):
|
||||
- 1.FileCreator - (_Создание тестовых данных_)
|
||||
- 2.FirstService - (_Выполнение 1.4 варианта задания_)
|
||||
- 3.SecondService - (_Выполнение 2.2 варианта задания_)
|
||||
|
||||
В качестве основного языка был выбран GoLang. Для каждого сервиса был создан DOCKERFILE где были прописаны условия и действия для сборки каждого из модулей
|
||||
|
||||
# Docker
|
||||
|
||||
>Перед исполнением вполняем установку docker и проверяем версию
|
||||
|
||||
```sh
|
||||
docker-compose --version
|
||||
```
|
||||
|
||||
>Далее производим настройку файла docker-compose.yaml и запускаем контейнер с сборкой образов
|
||||
|
||||
```sh
|
||||
docker-compose up -d --build
|
||||
```
|
||||
|
||||
>Для завершения работы контейнера используем команду
|
||||
```sh
|
||||
docker-compose down
|
||||
```
|
||||
|
||||
[Демонстрация работы](https://vk.com/video236673313_456239575)
|
14
bazunov_andrew_lab_2/SecondService/Dockerfile
Normal file
14
bazunov_andrew_lab_2/SecondService/Dockerfile
Normal file
@ -0,0 +1,14 @@
|
||||
# Используем официальный образ Go в качестве базового
|
||||
FROM golang:1.23
|
||||
|
||||
# Устанавливаем рабочую директорию
|
||||
WORKDIR /app
|
||||
|
||||
# Копируем файлы модуля
|
||||
COPY . .
|
||||
|
||||
# Сборка модуля
|
||||
RUN go build -o /bin/SecondService
|
||||
|
||||
# Запуск модуля
|
||||
CMD ["/bin/SecondService"]
|
1
bazunov_andrew_lab_2/SecondService/go.mod
Normal file
1
bazunov_andrew_lab_2/SecondService/go.mod
Normal file
@ -0,0 +1 @@
|
||||
module SecondService
|
79
bazunov_andrew_lab_2/SecondService/main.go
Normal file
79
bazunov_andrew_lab_2/SecondService/main.go
Normal file
@ -0,0 +1,79 @@
|
||||
package main
|
||||
|
||||
import (
|
||||
"bufio"
|
||||
"fmt"
|
||||
"os"
|
||||
)
|
||||
|
||||
//Ищет наименьшее число из файла /var/data/data.txt и сохраняет его третью степень в /var/result/result.txt.
|
||||
|
||||
const INPUT = "/var/data/data.txt"
|
||||
const OUTPUT = "/var/result/result.txt"
|
||||
|
||||
func ReadlinesFromFile(filename string) ([]string, error) {
|
||||
file, err := os.Open(filename)
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
var output []string
|
||||
scanner := bufio.NewScanner(file)
|
||||
for scanner.Scan() {
|
||||
output = append(output, scanner.Text())
|
||||
}
|
||||
|
||||
err = file.Close()
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
return output, nil
|
||||
}
|
||||
|
||||
func WriteIntToFile(filename string, i int) error {
|
||||
file, err := os.Create(filename)
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
|
||||
defer func(file *os.File) {
|
||||
err := file.Close()
|
||||
if err != nil {
|
||||
|
||||
}
|
||||
}(file)
|
||||
|
||||
_, err = file.WriteString(fmt.Sprintf("%d\n", i))
|
||||
if err != nil {
|
||||
return err
|
||||
}
|
||||
return nil
|
||||
}
|
||||
|
||||
func main() {
|
||||
lines, err := ReadlinesFromFile(INPUT)
|
||||
if err != nil {
|
||||
fmt.Println(err)
|
||||
}
|
||||
|
||||
minValue := 0
|
||||
|
||||
for _, line := range lines {
|
||||
if intValue, err := fmt.Sscanf(line, "%d", &minValue); err != nil {
|
||||
fmt.Println(err)
|
||||
} else {
|
||||
if minValue >= intValue {
|
||||
minValue = intValue
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if err = WriteIntToFile(OUTPUT, minValue); err != nil {
|
||||
return
|
||||
} else {
|
||||
fmt.Printf("Write %d to %s\n", minValue, OUTPUT)
|
||||
}
|
||||
|
||||
fmt.Println("Second Service is end.")
|
||||
}
|
27
bazunov_andrew_lab_2/docker-compose.yaml
Normal file
27
bazunov_andrew_lab_2/docker-compose.yaml
Normal file
@ -0,0 +1,27 @@
|
||||
services:
|
||||
file_generate:
|
||||
build:
|
||||
context: ./FileCreator
|
||||
dockerfile: Dockerfile
|
||||
volumes:
|
||||
- ./data:/var/data # Монтирование локальной папки data в /var/data в контейнере
|
||||
|
||||
first_service:
|
||||
build:
|
||||
context: ./FirstService
|
||||
dockerfile: Dockerfile
|
||||
volumes:
|
||||
- ./data:/var/data
|
||||
- ./data:/var/result
|
||||
depends_on:
|
||||
- file_generate
|
||||
|
||||
second_service:
|
||||
build:
|
||||
context: ./SecondService
|
||||
dockerfile: Dockerfile
|
||||
volumes:
|
||||
- ./data:/var/data
|
||||
- ./data:/var/result
|
||||
depends_on:
|
||||
- first_service
|
35
bogdanov_dmitry_lab_1/README.md
Normal file
35
bogdanov_dmitry_lab_1/README.md
Normal file
@ -0,0 +1,35 @@
|
||||
# Лабораторная работа №1
|
||||
|
||||
## Богданов Дмитрий ПИбд-42
|
||||
|
||||
### Для выполнения были развернуты следующие сервисы:
|
||||
|
||||
* PostgreSQL - база данных
|
||||
* Mediawiki - движок вики
|
||||
* Gitea - движок гита
|
||||
|
||||
### С использованием следующих технологий:
|
||||
|
||||
* git
|
||||
* docker
|
||||
* docker-compose
|
||||
|
||||
|
||||
### Запуск лабораторной:
|
||||
Необходимо перейти в папку с файлом docker-compose.yaml и ввести следующую команду:
|
||||
```
|
||||
docker-compose up -d
|
||||
```
|
||||
|
||||
## Результат запуска:
|
||||
```
|
||||
[+] Running 4/4
|
||||
✔ Network bogdanov_dmitry_lab_1_default Created 0.0s
|
||||
✔ Container bogdanov_dmitry_lab_1-mediawiki-1 Started 0.7s
|
||||
✔ Container bogdanov_dmitry_lab_1-git-1 Started 0.8s
|
||||
✔ Container bogdanov_dmitry_lab_1-db-1 Started 0.7s
|
||||
```
|
||||
|
||||
## Видео с результатом запуска:
|
||||
|
||||
Видео можно посмотреть по данной [ссылке](https://drive.google.com/file/d/1TES58HIeCnnKbtwWgED2oig4N7plBmol/view).
|
40
bogdanov_dmitry_lab_1/docker-compose.yaml
Normal file
40
bogdanov_dmitry_lab_1/docker-compose.yaml
Normal file
@ -0,0 +1,40 @@
|
||||
services:
|
||||
# PostgreSQL
|
||||
db:
|
||||
# Образ контейнера
|
||||
image: postgres
|
||||
# Перезапуск при падении
|
||||
restart: always
|
||||
# Порт для подключения
|
||||
ports:
|
||||
- 5432:5432
|
||||
# Каталог с данными. Каталог компьютера:каталог контейнера
|
||||
volumes:
|
||||
- ./volumes/postgres:/var/lib/postgresql/data
|
||||
# Переменные среды для определения хотя бы одного пользователя при запуске
|
||||
environment:
|
||||
- POSTGRES_USER=admin
|
||||
- POSTGRES_PASSWORD=admin
|
||||
# Mediawiki
|
||||
mediawiki:
|
||||
# Образ
|
||||
image: mediawiki
|
||||
# Перезапуск при падении
|
||||
restart: always
|
||||
# Порт для подключения
|
||||
ports:
|
||||
- 8080:80
|
||||
# Каталоги
|
||||
volumes:
|
||||
- ./volumes/mediawiki:/var/www/html/images
|
||||
# Gitea
|
||||
git:
|
||||
image: gitea/gitea:latest
|
||||
restart: always
|
||||
ports:
|
||||
- "3000:3000"
|
||||
- "222:22"
|
||||
volumes:
|
||||
- ./volumes/gitea:/data
|
||||
- ./volumes/timezone:/etc/timezone:ro
|
||||
- ./volumes/localtime:/etc/localtime:ro
|
4
dolgov_dmitriy_lab_1/.gitignore
vendored
Normal file
4
dolgov_dmitriy_lab_1/.gitignore
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
data/
|
||||
log/
|
||||
wordpress/
|
||||
custom/
|
34
dolgov_dmitriy_lab_1/README.md
Normal file
34
dolgov_dmitriy_lab_1/README.md
Normal file
@ -0,0 +1,34 @@
|
||||
# Лабораторная работа №1
|
||||
|
||||
## Выполнил: Долгов Дмитрий, группа ПИбд-42
|
||||
|
||||
### Были развёрнуты следующие сервисы:
|
||||
|
||||
* mediawiki (движок вики)
|
||||
* wordpress (популярная система управления контентом)
|
||||
* gitea (сервис для хранения репозиториев git)
|
||||
* mariaDB
|
||||
### Были использованы следующие технологии:
|
||||
|
||||
* git
|
||||
* docker
|
||||
* docker-compose
|
||||
|
||||
|
||||
### Для запуска лабораторной работы необходимо ввести в консоль следующую команду:
|
||||
```
|
||||
docker compose up -d
|
||||
```
|
||||
|
||||
## Результат запуска:
|
||||
```
|
||||
[+] Running 4/4
|
||||
✔ Container dolgov_dmitriy_lab_1-wordpress-1 Running 0.0s
|
||||
✔ Container dolgov_dmitriy_lab_1-database-1 Running 0.0s
|
||||
✔ Container dolgov_dmitriy_lab_1-mediawiki-1 Running 0.0s
|
||||
✔ Container gitea Running
|
||||
```
|
||||
|
||||
## Видео с результатом запуска:
|
||||
|
||||
Видео можно посмотреть по данной [ссылке](https://drive.google.com/file/d/1hC6HhNvYBRuYVClobXyDMReA4ngwxhwc/view?usp=drive_link).
|
73
dolgov_dmitriy_lab_1/docker-compose.yml
Normal file
73
dolgov_dmitriy_lab_1/docker-compose.yml
Normal file
@ -0,0 +1,73 @@
|
||||
# Сервисы по заданию
|
||||
services:
|
||||
# Сервис MediaWiki
|
||||
mediawiki:
|
||||
# Образ MediaWiki
|
||||
image: mediawiki
|
||||
# Автоматический перезапуск при сбое
|
||||
restart: always
|
||||
# проброс порта 80 из контейнера на порт 8080 хоста
|
||||
ports:
|
||||
- "8080:80"
|
||||
# связь с сервисом database
|
||||
links:
|
||||
- database
|
||||
# монтирование volume для хранения данных
|
||||
volumes:
|
||||
- images:/var/www/html/images
|
||||
|
||||
# Сервис WordPress
|
||||
wordpress:
|
||||
# Образ WordPress
|
||||
image: wordpress:latest
|
||||
# Автоматический перезапуск при сбое
|
||||
ports:
|
||||
- "8082:80"
|
||||
restart: always
|
||||
volumes:
|
||||
- ./wordpress:/var/www/html
|
||||
|
||||
# Сервис Gitea
|
||||
server:
|
||||
image: gitea/gitea:latest
|
||||
container_name: gitea
|
||||
restart: always
|
||||
environment:
|
||||
- USER_UID=1000
|
||||
- USER_GID=1000
|
||||
volumes:
|
||||
- ./data:/data
|
||||
- ./custom:/app/gitea/custom
|
||||
- ./log:/app/gitea/log
|
||||
ports:
|
||||
- "8081:3000"
|
||||
links:
|
||||
- database
|
||||
depends_on:
|
||||
- database
|
||||
|
||||
# Сервис MariaDB
|
||||
database:
|
||||
# Образ MariaDB
|
||||
image: mariadb
|
||||
# Автоматический перезапуск при сбое
|
||||
restart: always
|
||||
# переменные окружения для настройки базы данных
|
||||
environment:
|
||||
# имя базы данных
|
||||
MYSQL_DATABASE: my_wiki
|
||||
# имя пользователя
|
||||
MYSQL_USER: user
|
||||
# пароль пользователя
|
||||
MYSQL_PASSWORD: user
|
||||
# случайный пароль для пользователя root
|
||||
MYSQL_RANDOM_ROOT_PASSWORD: 'yes'
|
||||
# монтирование volume для хранения данных
|
||||
volumes:
|
||||
- db:/var/lib/mysql
|
||||
|
||||
# тома для хранения данных
|
||||
volumes:
|
||||
images:
|
||||
db:
|
||||
|
BIN
dolgov_dmitriy_lab_1/screenshots/image.png
Normal file
BIN
dolgov_dmitriy_lab_1/screenshots/image.png
Normal file
Binary file not shown.
After Width: | Height: | Size: 275 KiB |
2
dolgov_dmitriy_lab_2/.gitignore
vendored
Normal file
2
dolgov_dmitriy_lab_2/.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
||||
data
|
||||
result
|
36
dolgov_dmitriy_lab_2/README.md
Normal file
36
dolgov_dmitriy_lab_2/README.md
Normal file
@ -0,0 +1,36 @@
|
||||
# Лабораторная работа №2
|
||||
|
||||
## Выполнил: Долгов Дмитрий, группа ПИбд-42
|
||||
|
||||
### Были выбраны следующие варианты программ:
|
||||
|
||||
* _Вариант первого приложения: 6._ Берёт из каталога /var/data случайный файл и перекладывает его в /var/result/data.txt.
|
||||
* _Вариант второго приложения: 1._ Ищет набольшее число из файла /var/data/data.txt и сохраняет его вторую степень в /var/result/result.txt.
|
||||
|
||||
Кроме того, для генерации файлов был реализован сервис file_generator
|
||||
|
||||
### Были использованы следующие технологии:
|
||||
|
||||
* git
|
||||
* docker
|
||||
* docker-compose
|
||||
* язык программирования Python
|
||||
|
||||
### Для запуска лабораторной работы, находясь в папке `dolgov_dmitriy_lab_2`, необходимо выполнить следующую команду:
|
||||
|
||||
```
|
||||
docker-compose up --build
|
||||
```
|
||||
Таким образом, запустятся все сервисы, необходимые для выполнения лабораторной работы.
|
||||
|
||||
## Результат запуска:
|
||||
```
|
||||
app2-1 | Наибольшее числовое значение: 29.0
|
||||
app2-1 | Результат: 841.0
|
||||
app1-1 | Файл file_3.txt успешно перемещен в /var/result/data.txt
|
||||
app2-1 exited with code 0
|
||||
app1-1 exited with code 0
|
||||
```
|
||||
## Видео с результатом запуска:
|
||||
|
||||
Видео можно посмотреть по данной [ссылке](https://drive.google.com/file/d/1Iw6BR0lRvh4382QsIEfr5E68-09aKX9C/view?usp=drive_link).
|
8
dolgov_dmitriy_lab_2/app1/Dockerfile
Normal file
8
dolgov_dmitriy_lab_2/app1/Dockerfile
Normal file
@ -0,0 +1,8 @@
|
||||
# Стандартный образ Python
|
||||
FROM python:3.9
|
||||
# Указываем рабочую директорию
|
||||
WORKDIR /app
|
||||
# Копируем в ней файл app1.py
|
||||
COPY app1.py .
|
||||
# Команда для запуска при старте контейнера
|
||||
CMD ["python", "app1.py"]
|
27
dolgov_dmitriy_lab_2/app1/app1.py
Normal file
27
dolgov_dmitriy_lab_2/app1/app1.py
Normal file
@ -0,0 +1,27 @@
|
||||
import os
|
||||
import random
|
||||
import shutil
|
||||
|
||||
def move_random_file():
|
||||
src_dir = "/var/data"
|
||||
dst_file = "/var/result/data.txt"
|
||||
|
||||
# Получаем список всех файлов в src_dir
|
||||
files = os.listdir(src_dir)
|
||||
|
||||
if files:
|
||||
# Выбираем случайный файл
|
||||
random_file = random.choice(files)
|
||||
|
||||
# Проверяем, что файл существует
|
||||
if os.path.exists(os.path.join(src_dir, random_file)):
|
||||
# Перемещаем файл в целевое место
|
||||
shutil.move(os.path.join(src_dir, random_file), dst_file)
|
||||
print(f"Файл {random_file} успешно перемещен в {dst_file}")
|
||||
else:
|
||||
print(f"Ошибка: Файл {random_file} не найден в {src_dir}")
|
||||
else:
|
||||
print("Папка пуста")
|
||||
|
||||
if __name__ == "__main__":
|
||||
move_random_file()
|
8
dolgov_dmitriy_lab_2/app2/Dockerfile
Normal file
8
dolgov_dmitriy_lab_2/app2/Dockerfile
Normal file
@ -0,0 +1,8 @@
|
||||
# Стандартный образ Python
|
||||
FROM python:3.9
|
||||
# Указываем рабочую директорию
|
||||
WORKDIR /app
|
||||
# Копируем содержимое текущей директории в рабочую директорию
|
||||
COPY app2.py .
|
||||
# Запускаем приложение
|
||||
CMD ["python", "app2.py"]
|
26
dolgov_dmitriy_lab_2/app2/app2.py
Normal file
26
dolgov_dmitriy_lab_2/app2/app2.py
Normal file
@ -0,0 +1,26 @@
|
||||
import os
|
||||
from math import sqrt
|
||||
|
||||
def find_largest_number_and_square():
|
||||
input_file = "/var/data/data.txt"
|
||||
output_file = "/var/result/result.txt"
|
||||
|
||||
try:
|
||||
with open(input_file, 'r') as f:
|
||||
numbers = [float(num.strip()) for num in f]
|
||||
|
||||
largest_num = max(numbers)
|
||||
squared_num = largest_num ** 2
|
||||
|
||||
with open(output_file, 'w') as f:
|
||||
f.write(str(squared_num))
|
||||
|
||||
print(f"Наибольшее числовое значение: {largest_num}")
|
||||
print(f"Результат: {squared_num}")
|
||||
except FileNotFoundError:
|
||||
print(f"Ошибка: Файл {input_file} не найден")
|
||||
except ValueError:
|
||||
print("Ошибка: В файле содержатся некорректные данные")
|
||||
|
||||
if __name__ == "__main__":
|
||||
find_largest_number_and_square()
|
42
dolgov_dmitriy_lab_2/docker-compose.yml
Normal file
42
dolgov_dmitriy_lab_2/docker-compose.yml
Normal file
@ -0,0 +1,42 @@
|
||||
# Сервисы, которые будут запускаться
|
||||
services:
|
||||
# Сервис генерации файлов
|
||||
file_generator:
|
||||
build:
|
||||
# Директория с Dockerfile и скриптом генератора
|
||||
context: ./file_generator
|
||||
dockerfile: Dockerfile
|
||||
# Монтирование локальной папки data в /var/data в контейнере
|
||||
volumes:
|
||||
- ./data:/var/data
|
||||
- ./result:/var/result
|
||||
# Запуск команды, которая генерирует файл в папке /var/data
|
||||
command: ["python", "file_generator.py"]
|
||||
|
||||
# Первая программа, которая перемещает рандомный файл из одной папки в другую
|
||||
app1:
|
||||
build:
|
||||
# Директория с Dockerfile для первого приложения
|
||||
context: ./app1
|
||||
dockerfile: Dockerfile
|
||||
# Монтирование локальной папки result в /var/result в контейнере
|
||||
volumes:
|
||||
- ./result:/var/result
|
||||
- ./data:/var/data
|
||||
# Указывает, что первый сервис зависит от завершения работы генератора
|
||||
depends_on:
|
||||
- file_generator
|
||||
# Запуск скрипта
|
||||
command: ["python", "app1.py"]
|
||||
|
||||
# Вторая программа, которая считает квадрат максимального числа в файле (пояснения аналогичны первой)
|
||||
app2:
|
||||
build:
|
||||
context: ./app2
|
||||
dockerfile: Dockerfile
|
||||
volumes:
|
||||
- ./result:/var/result
|
||||
- ./data:/var/data
|
||||
depends_on:
|
||||
- file_generator
|
||||
command: ["python", "app2.py"]
|
7
dolgov_dmitriy_lab_2/file_generator/Dockerfile
Normal file
7
dolgov_dmitriy_lab_2/file_generator/Dockerfile
Normal file
@ -0,0 +1,7 @@
|
||||
FROM python:3.9
|
||||
|
||||
WORKDIR /app
|
||||
|
||||
COPY file_generator.py .
|
||||
|
||||
CMD [ "python", "file_generator.py" ]
|
33
dolgov_dmitriy_lab_2/file_generator/file_generator.py
Normal file
33
dolgov_dmitriy_lab_2/file_generator/file_generator.py
Normal file
@ -0,0 +1,33 @@
|
||||
import os
|
||||
import random
|
||||
|
||||
def generate_files(count):
|
||||
directory = "/var/data/"
|
||||
if not os.path.exists(directory):
|
||||
os.makedirs(directory)
|
||||
|
||||
for _ in range(count):
|
||||
file_name = f"{directory}file_{random.randint(1, 10)}.txt"
|
||||
|
||||
with open(file_name, 'w') as f:
|
||||
for _ in range(random.randint(1, 100)):
|
||||
f.write(f"{random.randint(1, 100)}\n")
|
||||
|
||||
print(f"Сгенерирован файл {file_name}")
|
||||
|
||||
|
||||
def generate_data():
|
||||
|
||||
file_name = "/var/data/data.txt"
|
||||
|
||||
with open(file_name, 'w') as f:
|
||||
for _ in range(random.randint(10, 100)):
|
||||
f.write(f"{random.randint(1, 30)}\n")
|
||||
print(f"Сгенерирован файл {file_name}")
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
generate_files(10)
|
||||
generate_data()
|
||||
|
||||
|
30
dozorova_alena_lab_2/ConsoleApp1/.dockerignore
Normal file
30
dozorova_alena_lab_2/ConsoleApp1/.dockerignore
Normal file
@ -0,0 +1,30 @@
|
||||
**/.classpath
|
||||
**/.dockerignore
|
||||
**/.env
|
||||
**/.git
|
||||
**/.gitignore
|
||||
**/.project
|
||||
**/.settings
|
||||
**/.toolstarget
|
||||
**/.vs
|
||||
**/.vscode
|
||||
**/*.*proj.user
|
||||
**/*.dbmdl
|
||||
**/*.jfm
|
||||
**/azds.yaml
|
||||
**/bin
|
||||
**/charts
|
||||
**/docker-compose*
|
||||
**/Dockerfile*
|
||||
**/node_modules
|
||||
**/npm-debug.log
|
||||
**/obj
|
||||
**/secrets.dev.yaml
|
||||
**/values.dev.yaml
|
||||
LICENSE
|
||||
README.md
|
||||
!**/.gitignore
|
||||
!.git/HEAD
|
||||
!.git/config
|
||||
!.git/packed-refs
|
||||
!.git/refs/heads/**
|
13
dozorova_alena_lab_2/ConsoleApp1/ConsoleApp1.csproj
Normal file
13
dozorova_alena_lab_2/ConsoleApp1/ConsoleApp1.csproj
Normal file
@ -0,0 +1,13 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk;Microsoft.NET.Sdk.Publish">
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
||||
<DockerfileContext>.</DockerfileContext>
|
||||
</PropertyGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.VisualStudio.Azure.Containers.Tools.Targets" Version="1.20.1" />
|
||||
</ItemGroup>
|
||||
</Project>
|
7
dozorova_alena_lab_2/ConsoleApp1/ConsoleApp1.csproj.user
Normal file
7
dozorova_alena_lab_2/ConsoleApp1/ConsoleApp1.csproj.user
Normal file
@ -0,0 +1,7 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ActiveDebugProfile>Container (Dockerfile)</ActiveDebugProfile>
|
||||
<_LastSelectedProfileId>C:\Users\Alena\WorkFolder\Study\politech\7\РВиП\DAS_2024_1\dozorova_alena_lab_2\ConsoleApp1\Properties\PublishProfiles\registry.hub.docker.com_alenadozorova.pubxml</_LastSelectedProfileId>
|
||||
</PropertyGroup>
|
||||
</Project>
|
25
dozorova_alena_lab_2/ConsoleApp1/ConsoleApp1.sln
Normal file
25
dozorova_alena_lab_2/ConsoleApp1/ConsoleApp1.sln
Normal file
@ -0,0 +1,25 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.10.35004.147
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp1", "ConsoleApp1.csproj", "{093B5FCB-33F6-4F14-B150-87DA092D2BFA}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{093B5FCB-33F6-4F14-B150-87DA092D2BFA}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{093B5FCB-33F6-4F14-B150-87DA092D2BFA}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{093B5FCB-33F6-4F14-B150-87DA092D2BFA}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{093B5FCB-33F6-4F14-B150-87DA092D2BFA}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {CDC30087-C732-4ED0-97FB-E43A9F219F67}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
22
dozorova_alena_lab_2/ConsoleApp1/Dockerfile
Normal file
22
dozorova_alena_lab_2/ConsoleApp1/Dockerfile
Normal file
@ -0,0 +1,22 @@
|
||||
#See https://aka.ms/customizecontainer to learn how to customize your debug container and how Visual Studio uses this Dockerfile to build your images for faster debugging.
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/runtime:6.0 AS base
|
||||
WORKDIR /app
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
|
||||
ARG BUILD_CONFIGURATION=Release
|
||||
WORKDIR /src
|
||||
COPY ["ConsoleApp1.csproj", "."]
|
||||
RUN dotnet restore "./ConsoleApp1.csproj"
|
||||
COPY . .
|
||||
WORKDIR "/src/."
|
||||
RUN dotnet build "./ConsoleApp1.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
||||
|
||||
FROM build AS publish
|
||||
ARG BUILD_CONFIGURATION=Release
|
||||
RUN dotnet publish "./ConsoleApp1.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
|
||||
|
||||
FROM base AS final
|
||||
WORKDIR /app
|
||||
COPY --from=publish /app/publish .
|
||||
ENTRYPOINT ["dotnet", "ConsoleApp1.dll"]
|
32
dozorova_alena_lab_2/ConsoleApp1/Program.cs
Normal file
32
dozorova_alena_lab_2/ConsoleApp1/Program.cs
Normal file
@ -0,0 +1,32 @@
|
||||
// Ищет в каталоге /var/data файл с самым коротким названием и перекладывает
|
||||
// его в /var/result/data.txt.
|
||||
|
||||
Console.WriteLine("Start first service");
|
||||
var files = Directory.GetFiles("/var/data/");
|
||||
|
||||
if(files == null || files.Length == 0)
|
||||
{
|
||||
File.Create("./var/data/data.txt");
|
||||
}
|
||||
|
||||
string res = files[0];
|
||||
|
||||
files.ToList().ForEach(f =>
|
||||
{
|
||||
if(res.Length > f.Length)
|
||||
{
|
||||
res = f;
|
||||
}
|
||||
});
|
||||
|
||||
Console.WriteLine("Find file " + res);
|
||||
|
||||
if(!Directory.Exists("/var/result"))
|
||||
{
|
||||
Directory.CreateDirectory("/var/result");
|
||||
}
|
||||
|
||||
File.Copy(res, "/var/result/data.txt");
|
||||
|
||||
Console.WriteLine("Copy to /var/result/data.txt");
|
||||
|
@ -0,0 +1,10 @@
|
||||
{
|
||||
"profiles": {
|
||||
"ConsoleApp1": {
|
||||
"commandName": "Project"
|
||||
},
|
||||
"Container (Dockerfile)": {
|
||||
"commandName": "Docker"
|
||||
}
|
||||
}
|
||||
}
|
30
dozorova_alena_lab_2/ConsoleApp2/.dockerignore
Normal file
30
dozorova_alena_lab_2/ConsoleApp2/.dockerignore
Normal file
@ -0,0 +1,30 @@
|
||||
**/.classpath
|
||||
**/.dockerignore
|
||||
**/.env
|
||||
**/.git
|
||||
**/.gitignore
|
||||
**/.project
|
||||
**/.settings
|
||||
**/.toolstarget
|
||||
**/.vs
|
||||
**/.vscode
|
||||
**/*.*proj.user
|
||||
**/*.dbmdl
|
||||
**/*.jfm
|
||||
**/azds.yaml
|
||||
**/bin
|
||||
**/charts
|
||||
**/docker-compose*
|
||||
**/Dockerfile*
|
||||
**/node_modules
|
||||
**/npm-debug.log
|
||||
**/obj
|
||||
**/secrets.dev.yaml
|
||||
**/values.dev.yaml
|
||||
LICENSE
|
||||
README.md
|
||||
!**/.gitignore
|
||||
!.git/HEAD
|
||||
!.git/config
|
||||
!.git/packed-refs
|
||||
!.git/refs/heads/**
|
16
dozorova_alena_lab_2/ConsoleApp2/ConsoleApp2.csproj
Normal file
16
dozorova_alena_lab_2/ConsoleApp2/ConsoleApp2.csproj
Normal file
@ -0,0 +1,16 @@
|
||||
<Project Sdk="Microsoft.NET.Sdk">
|
||||
|
||||
<PropertyGroup>
|
||||
<OutputType>Exe</OutputType>
|
||||
<TargetFramework>net6.0</TargetFramework>
|
||||
<ImplicitUsings>enable</ImplicitUsings>
|
||||
<Nullable>enable</Nullable>
|
||||
<DockerDefaultTargetOS>Linux</DockerDefaultTargetOS>
|
||||
<DockerfileContext>.</DockerfileContext>
|
||||
</PropertyGroup>
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="Microsoft.VisualStudio.Azure.Containers.Tools.Targets" Version="1.20.1" />
|
||||
</ItemGroup>
|
||||
|
||||
</Project>
|
6
dozorova_alena_lab_2/ConsoleApp2/ConsoleApp2.csproj.user
Normal file
6
dozorova_alena_lab_2/ConsoleApp2/ConsoleApp2.csproj.user
Normal file
@ -0,0 +1,6 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<Project ToolsVersion="Current" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||
<PropertyGroup>
|
||||
<ActiveDebugProfile>Container (Dockerfile)</ActiveDebugProfile>
|
||||
</PropertyGroup>
|
||||
</Project>
|
25
dozorova_alena_lab_2/ConsoleApp2/ConsoleApp2.sln
Normal file
25
dozorova_alena_lab_2/ConsoleApp2/ConsoleApp2.sln
Normal file
@ -0,0 +1,25 @@
|
||||
|
||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||
# Visual Studio Version 17
|
||||
VisualStudioVersion = 17.10.35004.147
|
||||
MinimumVisualStudioVersion = 10.0.40219.1
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ConsoleApp2", "ConsoleApp2.csproj", "{364FF6E2-3AED-4C3A-B2DD-D20CA9214BB8}"
|
||||
EndProject
|
||||
Global
|
||||
GlobalSection(SolutionConfigurationPlatforms) = preSolution
|
||||
Debug|Any CPU = Debug|Any CPU
|
||||
Release|Any CPU = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(ProjectConfigurationPlatforms) = postSolution
|
||||
{364FF6E2-3AED-4C3A-B2DD-D20CA9214BB8}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
|
||||
{364FF6E2-3AED-4C3A-B2DD-D20CA9214BB8}.Debug|Any CPU.Build.0 = Debug|Any CPU
|
||||
{364FF6E2-3AED-4C3A-B2DD-D20CA9214BB8}.Release|Any CPU.ActiveCfg = Release|Any CPU
|
||||
{364FF6E2-3AED-4C3A-B2DD-D20CA9214BB8}.Release|Any CPU.Build.0 = Release|Any CPU
|
||||
EndGlobalSection
|
||||
GlobalSection(SolutionProperties) = preSolution
|
||||
HideSolutionNode = FALSE
|
||||
EndGlobalSection
|
||||
GlobalSection(ExtensibilityGlobals) = postSolution
|
||||
SolutionGuid = {E5B491A6-064F-48E0-ACBD-E1B4FE3D0898}
|
||||
EndGlobalSection
|
||||
EndGlobal
|
22
dozorova_alena_lab_2/ConsoleApp2/Dockerfile
Normal file
22
dozorova_alena_lab_2/ConsoleApp2/Dockerfile
Normal file
@ -0,0 +1,22 @@
|
||||
#See https://aka.ms/customizecontainer to learn how to customize your debug container and how Visual Studio uses this Dockerfile to build your images for faster debugging.
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/runtime:6.0 AS base
|
||||
WORKDIR /app
|
||||
|
||||
FROM mcr.microsoft.com/dotnet/sdk:6.0 AS build
|
||||
ARG BUILD_CONFIGURATION=Release
|
||||
WORKDIR /src
|
||||
COPY ["ConsoleApp2.csproj", "."]
|
||||
RUN dotnet restore "./ConsoleApp2.csproj"
|
||||
COPY . .
|
||||
WORKDIR "/src/."
|
||||
RUN dotnet build "./ConsoleApp2.csproj" -c $BUILD_CONFIGURATION -o /app/build
|
||||
|
||||
FROM build AS publish
|
||||
ARG BUILD_CONFIGURATION=Release
|
||||
RUN dotnet publish "./ConsoleApp2.csproj" -c $BUILD_CONFIGURATION -o /app/publish /p:UseAppHost=false
|
||||
|
||||
FROM base AS final
|
||||
WORKDIR /app
|
||||
COPY --from=publish /app/publish .
|
||||
ENTRYPOINT ["dotnet", "ConsoleApp2.dll"]
|
16
dozorova_alena_lab_2/ConsoleApp2/Program.cs
Normal file
16
dozorova_alena_lab_2/ConsoleApp2/Program.cs
Normal file
@ -0,0 +1,16 @@
|
||||
// Ищет набольшее число из файла /var/data/data.txt и сохраняет
|
||||
// его вторую степень в /var/result/result.txt.
|
||||
Console.WriteLine("Start second service");
|
||||
var data = File.ReadAllText("/var/data/data.txt").Split(" ").ToList();
|
||||
|
||||
var max = data.Select(x => Int32.TryParse(x, out int value) ? value : 0).Max();
|
||||
|
||||
Console.WriteLine("Find max value: "+max);
|
||||
if(!Directory.Exists("/var/result/"))
|
||||
{
|
||||
Directory.CreateDirectory("/var/result/");
|
||||
}
|
||||
|
||||
File.WriteAllText("/var/result/result.txt", Math.Pow(max, 2).ToString());
|
||||
|
||||
Console.WriteLine("Save to /var/result/result.txt");
|
@ -0,0 +1,10 @@
|
||||
{
|
||||
"profiles": {
|
||||
"ConsoleApp2": {
|
||||
"commandName": "Project"
|
||||
},
|
||||
"Container (Dockerfile)": {
|
||||
"commandName": "Docker"
|
||||
}
|
||||
}
|
||||
}
|
1
dozorova_alena_lab_2/FilesInput/First/0.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/0.txt
Normal file
@ -0,0 +1 @@
|
||||
52 32 22 57 23 30 63 22 27 32 10 0 58 40 83 86 21 87 84 27 44 31 59 35 37 57 21 97 87 7 23 89 27 35 55 9 14 35 59
|
1
dozorova_alena_lab_2/FilesInput/First/1.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/1.txt
Normal file
@ -0,0 +1 @@
|
||||
93 95 67 2 81 16 46 47 40 43 93 71 16 63 6 86 94 8 55 32 59 28 71 43 39 29 60 23 43 75 67 70 73 50 75 65 10 99 41
|
1
dozorova_alena_lab_2/FilesInput/First/10.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/10.txt
Normal file
@ -0,0 +1 @@
|
||||
48 88 38 25 7 96 34 30 92 34 97 0 81 41 94 85 4 82 77 23 41 8 78 93 38 12 27 55 97 46 20 52 88 54 35 72 62 28 43
|
1
dozorova_alena_lab_2/FilesInput/First/11.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/11.txt
Normal file
@ -0,0 +1 @@
|
||||
14 3 92 80 29 21 88 21 98 41 64 10 73 57 31 27 92 84 53 37 35 27 60 52 54 90 89 4 90 95 26 79 55 31 34 17 26 90 49
|
1
dozorova_alena_lab_2/FilesInput/First/12.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/12.txt
Normal file
@ -0,0 +1 @@
|
||||
66 33 75 48 42 37 2 29 34 77 0 11 59 38 61 80 85 29 50 59 14 64 37 91 65 65 3 14 41 19 13 49 42 30 55 69 81 8 39
|
1
dozorova_alena_lab_2/FilesInput/First/13.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/13.txt
Normal file
@ -0,0 +1 @@
|
||||
57 54 24 59 80 67 13 95 86 96 58 60 32 20 79 56 5 98 27 5 71 92 1 54 47 85 33 87 97 41 49 52 35 86 60 21 64 76 75
|
1
dozorova_alena_lab_2/FilesInput/First/14.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/14.txt
Normal file
@ -0,0 +1 @@
|
||||
75 57 65 15 61 79 94 34 49 33 25 58 91 55 91 81 64 50 25 46 87 44 28 65 15 68 94 56 58 2 40 39 14 29 35 24 9 48 65
|
1
dozorova_alena_lab_2/FilesInput/First/15.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/15.txt
Normal file
@ -0,0 +1 @@
|
||||
91 31 90 98 76 35 61 95 67 78 23 91 26 33 2 44 93 20 90 14 33 22 19 35 57 65 81 62 91 84 69 74 55 34 63 98 64 4 77
|
1
dozorova_alena_lab_2/FilesInput/First/16.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/16.txt
Normal file
@ -0,0 +1 @@
|
||||
41 11 46 24 85 69 93 45 33 33 97 31 91 75 43 60 32 3 76 58 70 66 97 7 75 14 62 1 32 17 54 79 3 59 67 15 43 92 43
|
1
dozorova_alena_lab_2/FilesInput/First/17.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/17.txt
Normal file
@ -0,0 +1 @@
|
||||
36 88 91 3 42 4 87 65 42 10 95 54 71 79 60 9 5 63 87 27 75 79 67 45 89 32 65 38 64 22 73 78 48 57 89 28 81 58 18
|
1
dozorova_alena_lab_2/FilesInput/First/18.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/18.txt
Normal file
@ -0,0 +1 @@
|
||||
39 86 99 32 34 57 95 27 73 90 80 62 85 91 50 24 54 36 15 87 6 54 63 63 78 10 18 90 9 20 14 57 54 4 97 22 80 50 24
|
1
dozorova_alena_lab_2/FilesInput/First/19.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/19.txt
Normal file
@ -0,0 +1 @@
|
||||
32 65 91 95 28 84 23 47 63 3 78 70 48 15 17 58 22 20 67 58 27 24 68 97 3 55 57 9 18 85 14 16 23 10 1 97 24 64 83
|
1
dozorova_alena_lab_2/FilesInput/First/2.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/2.txt
Normal file
@ -0,0 +1 @@
|
||||
50 60 55 6 46 82 92 76 47 53 94 93 58 71 54 68 83 56 32 39 96 9 31 93 30 72 88 15 1 45 5 98 64 83 45 60 73 69 74
|
1
dozorova_alena_lab_2/FilesInput/First/20.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/20.txt
Normal file
@ -0,0 +1 @@
|
||||
26 79 84 64 17 53 9 84 52 98 27 42 8 11 83 67 66 57 81 80 47 95 53 98 66 88 60 0 93 98 43 87 47 17 48 49 28 35 28
|
1
dozorova_alena_lab_2/FilesInput/First/21.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/21.txt
Normal file
@ -0,0 +1 @@
|
||||
60 70 16 18 71 67 22 71 54 55 70 57 13 54 84 73 99 27 53 13 49 68 12 89 96 77 93 52 80 62 59 11 73 9 33 40 49 82 1
|
1
dozorova_alena_lab_2/FilesInput/First/22.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/22.txt
Normal file
@ -0,0 +1 @@
|
||||
67 22 18 71 64 80 19 5 28 2 75 73 9 51 8 81 76 36 96 26 58 96 95 4 88 51 24 10 71 33 79 63 21 59 95 61 28 97 40
|
1
dozorova_alena_lab_2/FilesInput/First/23.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/23.txt
Normal file
@ -0,0 +1 @@
|
||||
62 36 50 68 46 3 28 7 16 30 26 1 21 39 27 78 13 92 34 6 6 38 70 1 1 42 45 20 98 49 61 24 51 45 56 33 53 3 75
|
1
dozorova_alena_lab_2/FilesInput/First/24.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/24.txt
Normal file
@ -0,0 +1 @@
|
||||
81 40 95 8 98 87 88 60 51 87 38 42 13 99 75 24 98 90 33 71 99 41 95 68 39 52 9 64 77 61 70 17 90 91 64 53 41 13 5
|
1
dozorova_alena_lab_2/FilesInput/First/25.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/25.txt
Normal file
@ -0,0 +1 @@
|
||||
79 25 4 32 1 51 91 16 26 23 87 8 98 25 23 86 23 94 24 35 34 84 54 79 46 18 40 48 90 9 98 80 37 20 80 79 4 13 57
|
1
dozorova_alena_lab_2/FilesInput/First/26.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/26.txt
Normal file
@ -0,0 +1 @@
|
||||
66 95 69 29 36 5 17 70 97 10 6 72 92 87 72 90 68 94 77 49 23 68 73 74 77 49 94 75 40 52 57 70 80 77 67 34 67 65 61
|
1
dozorova_alena_lab_2/FilesInput/First/27.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/27.txt
Normal file
@ -0,0 +1 @@
|
||||
21 5 57 27 17 89 4 91 80 49 55 57 92 9 61 37 92 33 28 18 27 45 88 7 61 26 22 64 24 17 63 70 75 1 69 96 62 77 47
|
1
dozorova_alena_lab_2/FilesInput/First/28.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/28.txt
Normal file
@ -0,0 +1 @@
|
||||
28 63 7 24 14 25 49 42 34 18 14 1 59 60 47 21 75 54 29 11 89 46 90 69 61 37 18 75 55 43 43 16 80 93 55 27 67 50 11
|
1
dozorova_alena_lab_2/FilesInput/First/29.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/29.txt
Normal file
@ -0,0 +1 @@
|
||||
35 9 60 57 42 99 29 73 61 44 21 75 18 96 67 9 81 37 39 54 83 33 62 62 17 30 11 7 30 10 37 1 36 75 92 40 77 37 69
|
1
dozorova_alena_lab_2/FilesInput/First/3.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/3.txt
Normal file
@ -0,0 +1 @@
|
||||
10 26 86 88 31 39 62 76 84 21 83 62 10 0 70 87 46 67 31 19 40 17 68 18 57 87 63 58 21 90 31 74 30 76 4 25 47 77 88
|
1
dozorova_alena_lab_2/FilesInput/First/30.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/30.txt
Normal file
@ -0,0 +1 @@
|
||||
2 39 85 29 46 99 69 64 89 20 5 72 23 47 57 14 64 9 62 22 15 48 93 51 14 28 97 18 60 48 44 9 70 22 25 69 53 86 67
|
1
dozorova_alena_lab_2/FilesInput/First/31.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/31.txt
Normal file
@ -0,0 +1 @@
|
||||
21 39 28 1 2 38 90 22 23 47 88 51 84 55 44 20 74 48 66 82 9 37 39 5 30 24 53 33 25 1 83 69 61 80 68 30 55 49 61
|
1
dozorova_alena_lab_2/FilesInput/First/32.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/32.txt
Normal file
@ -0,0 +1 @@
|
||||
77 3 9 39 23 95 77 44 53 18 33 10 85 90 84 47 55 48 69 91 44 93 70 1 30 12 64 98 15 57 43 18 69 61 8 17 77 16 95
|
1
dozorova_alena_lab_2/FilesInput/First/33.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/33.txt
Normal file
@ -0,0 +1 @@
|
||||
13 6 29 65 44 37 43 75 20 61 35 9 39 20 28 58 58 55 11 16 18 65 62 41 36 96 63 75 61 5 13 75 9 84 1 59 73 87 10
|
1
dozorova_alena_lab_2/FilesInput/First/34.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/34.txt
Normal file
@ -0,0 +1 @@
|
||||
57 35 36 64 48 37 9 72 89 61 83 89 29 6 13 25 11 41 33 21 68 58 74 63 54 48 16 49 53 1 70 93 3 87 9 34 69 77 95
|
1
dozorova_alena_lab_2/FilesInput/First/35.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/35.txt
Normal file
@ -0,0 +1 @@
|
||||
34 62 93 45 30 62 34 1 60 29 15 69 96 74 2 24 98 13 95 65 0 36 64 37 60 56 54 55 7 49 10 21 16 86 63 49 96 11 26
|
1
dozorova_alena_lab_2/FilesInput/First/36.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/36.txt
Normal file
@ -0,0 +1 @@
|
||||
29 15 87 70 80 67 79 64 7 52 29 91 5 88 52 77 83 56 74 34 27 27 25 22 95 91 56 10 21 84 82 54 92 94 98 23 56 65 43
|
1
dozorova_alena_lab_2/FilesInput/First/37.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/37.txt
Normal file
@ -0,0 +1 @@
|
||||
87 41 82 29 38 22 89 69 3 92 55 73 0 30 70 20 71 96 98 38 60 26 62 21 34 0 10 99 71 31 83 40 56 25 40 16 21 48 17
|
1
dozorova_alena_lab_2/FilesInput/First/38.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/38.txt
Normal file
@ -0,0 +1 @@
|
||||
69 78 36 30 6 95 39 12 30 63 57 84 83 8 25 50 64 96 84 1 99 85 67 48 72 93 93 90 99 74 58 39 15 66 3 11 72 87 70
|
1
dozorova_alena_lab_2/FilesInput/First/4.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/4.txt
Normal file
@ -0,0 +1 @@
|
||||
88 14 19 72 87 34 86 83 13 68 37 54 93 97 67 68 3 8 37 24 22 52 98 83 64 88 0 89 46 7 78 78 26 45 14 10 91 45 35
|
1
dozorova_alena_lab_2/FilesInput/First/5.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/5.txt
Normal file
@ -0,0 +1 @@
|
||||
46 1 4 50 36 86 56 84 17 54 89 38 36 25 4 93 48 97 63 99 34 42 0 9 16 88 82 10 98 57 0 37 41 33 32 27 61 43 3
|
1
dozorova_alena_lab_2/FilesInput/First/6.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/6.txt
Normal file
@ -0,0 +1 @@
|
||||
32 0 85 46 21 63 83 28 15 57 69 68 65 72 86 9 56 3 11 33 62 50 85 20 37 92 61 66 60 78 68 66 84 9 6 77 32 19 36
|
1
dozorova_alena_lab_2/FilesInput/First/7.txt
Normal file
1
dozorova_alena_lab_2/FilesInput/First/7.txt
Normal file
@ -0,0 +1 @@
|
||||
59 49 82 65 53 10 15 58 87 83 57 14 54 34 52 98 97 2 11 1 68 7 15 69 57 67 83 7 26 6 38 31 1 60 38 88 72 33 41
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user