diff --git a/README.md b/README.md index 9e42371..10b0d8f 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,30 @@ # WebProgramming lab work №1 + +## Quick Start +```bash +docker compose up +``` + +## Structure +``` +├── httpd/ # Директория с конфигурациями веб-серверов и статическими файлами + ├── nginx-conf/ # Конфиг веб-сервера для nginx + ├── apache-conf/ # Конфиг веб-сервера для apache (! НА ДАННЫЙ МОМЕНТ ОТКЛЮЧЁН !) + ├── static/ # Директория с статическими файлами + ├── index.html # Основной файл сайта + ├── js/ # Js сайта + └── assets/ # Ресурсы сайта + ├── Dockerfile-nginx # Dockerfile для Nginx + └── Dockerfile-apache # Dockerfile для Apache (! НА ДАННЫЙ МОМЕНТ ОТКЛЮЧЁН !) +├── server/ # Директория с кодом java-сервера (FastCGI) + ├── lib/ # Директория с библиотекой для fastcgi + ├── src/ # Исходники + └── Dockerfile # Dockerfile для fastcgi-сервера +└── docs # Дополнительная документация +``` + + ## TODOs ### Httpd diff --git a/docs/openapi.yaml b/docs/openapi.yaml new file mode 100644 index 0000000..a5e95a1 --- /dev/null +++ b/docs/openapi.yaml @@ -0,0 +1,86 @@ +openapi: 3.0.0 +info: + title: "WebProg Lab1" + version: 0.0.2 + description: | + Сервак из говна и палок + + Last update: 00:00 15.09.25 by NF-coder +servers: + - url: http://localhost:8080/fcgi/ + description: FastCGI API + +paths: + /: + get: + summary: Тест попадания в область + tags: + - General + parameters: + - in: query + name: x + required: true + schema: + $ref: "#/components/schemas/x" + - in: query + name: y + required: true + schema: + $ref: "#/components/schemas/y" + - in: query + name: r + required: true + schema: + $ref: "#/components/schemas/r" + + responses: + 200: + description: Responce with data + content: + application/json: + schema: + type: object + properties: + result: + type: boolean + description: "true if hitted area and false if missed" + example: true + elapsedTimeNs: + type: integer + description: "Time in ns that server spent while handling responce" + example: 12345 + default: + description: Error + content: + application/json: + schema: + $ref: "#/components/schemas/Error" +components: + schemas: + x: + type: integer + description: Кордината X + example: 0 + y: + type: number + description: Кордината Y + example: 0 + r: + type: number + description: Параметр R + example: 2 + + Error: + type: object + required: + - error + properties: + error: + type: string + description: "Description of error" + example: Some text + + + + + diff --git a/httpd/static/assets/img/logo.ico b/httpd/static/assets/img/logo.ico new file mode 100644 index 0000000..acc119e Binary files /dev/null and b/httpd/static/assets/img/logo.ico differ diff --git a/httpd/static/index.html b/httpd/static/index.html index 96dd94a..b872632 100644 --- a/httpd/static/index.html +++ b/httpd/static/index.html @@ -5,6 +5,7 @@