diff --git a/kiszolgalo/Dockerfile b/kiszolgalo/Dockerfile new file mode 100644 index 0000000..6927aaf --- /dev/null +++ b/kiszolgalo/Dockerfile @@ -0,0 +1,20 @@ +# Stage 1: Cache Gradle dependencies +FROM gradle:9.1.0-jdk21 AS build +RUN mkdir -p /home/gradle/cache_home +ENV GRADLE_USER_HOME=/home/gradle/cache_home +COPY build.gradle.* gradle.properties /home/gradle/app/ +COPY gradle /home/gradle/app/gradle +WORKDIR /home/gradle/app +RUN gradle dependencies --no-daemon + +COPY --chown=gradle:gradle . /home/gradle/src +WORKDIR /home/gradle/src +# and boot JAR by default. +RUN gradle buildFatJar --no-daemon + +# Stage 2: Create the Runtime Image +FROM amazoncorretto:21 AS runtime +EXPOSE 8080 +RUN mkdir /app +COPY --from=build /home/gradle/src/build/libs/*.jar /app/ktor-docker-sample.jar +ENTRYPOINT ["java","-jar","/app/ktor-docker-sample.jar"] diff --git a/kiszolgalo/docker-compose.yml b/kiszolgalo/docker-compose.yml new file mode 100644 index 0000000..0539ac3 --- /dev/null +++ b/kiszolgalo/docker-compose.yml @@ -0,0 +1,6 @@ +services: + backup-scheduler: + image: kotlin:latest + container_name: "bs" + ports: + - "8080:80" \ No newline at end of file diff --git a/kiszolgalo/src/main/kotlin/Main.kt b/kiszolgalo/src/main/kotlin/Main.kt index cedb84f..623a7c9 100644 --- a/kiszolgalo/src/main/kotlin/Main.kt +++ b/kiszolgalo/src/main/kotlin/Main.kt @@ -12,7 +12,7 @@ import kotlin.random.Random //átlagos JAVA alapú fejlesztő -val httpPort: Int = System.getenv("HTTP_PORT")?.toInt() ?: 8080 +val httpPort: Int = System.getenv("HTTP_PORT")?.toInt() ?: 80 val resourcesPath: String = System.getenv("RESOURCES") ?: "src/main/resources/" @@ -30,6 +30,7 @@ object ConversationHandler { return num } } + fun listAllConversations(): String { val stringBuilder = StringBuilder() @@ -39,6 +40,8 @@ object ConversationHandler { stringBuilder.append(conversation.list()) } + println(stringBuilder.toString()) + return stringBuilder.toString() } diff --git a/kiszolgalo/src/main/resources/about.html b/kiszolgalo/src/main/resources/about.html index 0f403f0..8cd8a3d 100644 --- a/kiszolgalo/src/main/resources/about.html +++ b/kiszolgalo/src/main/resources/about.html @@ -8,64 +8,60 @@ +
-
+ +
+

We're on a mission

-
-

We're on a mission

+

To give slow, unreliable information sometimes. If we feel like it.

-

To give slow, unreliable information sometimes. If we feel like it.

+

+ Our revolutionary technology enables us to create a cost-effective GS (Genuine Stupidity) companion for you to rely on. Our model is using 21 years of + training data, specialized in internet culture, STEM and being miserable. It is using less energy, and less water than almost all AI models on the market + in 2026. Uses a lot more whiskey-coke tho. -

- Our revolutionary technology enables us to create a cost-effective GS (Genuine Stupidity) companion for you to rely on. Our model is using 21 years of - training data, specialized in internet culture, STEM and being miserable. It is using less energy, and less water than almost all AI models on the market - in 2026. Uses a lot more whiskey-coke tho. +

-

+
-
+

+ Straight to the point +

-

- Straight to the point -

+

+ Unlike most modern AI models, our GS model is not going to sugar-coat every response. Of course class matters, which is why with our patent pending + algorithm every response is dripping with authenticity, while managing to stay extremely polite. +

-

- Unlike most modern AI models, our GS model is not going to sugar-coat every response. Of course class matters, which is why with our patent pending - algorithm every response is dripping with authenticity, while managing to stay extremely polite. -

+
-
+

+ Privacy first and foremost +

-

- Privacy first and foremost -

+

+ Powered by an incredibly abstract, high level language, our backend is built from the ground up with privacy in mind. Our developer, after trying + to use more than 1 Gradle dependency in the backend realized, that not storing user data in a database is a good thing, actually. Very marketable. +

-

- Powered by an incredibly abstract, high level language, our backend is built from the ground up with privacy in mind. Our developer, after trying - to use more than 1 Gradle dependency in the backend realized, that not storing user data in a database is a good thing, actually. Very marketable. -

+
-
- -

,,You make soup in a big bowl. You serve it in a smaller bowl. And then you convey it, using a spoon, to your mouth. But what is the spoon? Simply a smaller bowl still"

-

-user 'autophage' on tumblr

+

,,You make soup in a big bowl. You serve it in a smaller bowl. And then you convey it, using a spoon, to your mouth. But what is the spoon? Simply a smaller bowl still"

+

-user 'autophage' on tumblr

+
- -
- - diff --git a/kiszolgalo/src/main/resources/admin.html b/kiszolgalo/src/main/resources/admin.html index 17b8cd5..b5e085c 100644 --- a/kiszolgalo/src/main/resources/admin.html +++ b/kiszolgalo/src/main/resources/admin.html @@ -57,7 +57,7 @@ }) .then(data => { - document.getElementById("messages").innerHTML = data + ''; + document.getElementById("messages").innerHTML = data + ''; console.log(data.body) }) diff --git a/kiszolgalo/src/main/resources/style.css b/kiszolgalo/src/main/resources/style.css index 217c109..8e8cd8a 100644 --- a/kiszolgalo/src/main/resources/style.css +++ b/kiszolgalo/src/main/resources/style.css @@ -21,10 +21,10 @@ body { display: flex; margin: auto; text-align: center; - box-sizing: border-box; - justify-content: center;*/ + box-sizing: border-box;*/ + justify-content: center; flex-direction: column; - height: 93vh; + height: 80vh; overflow-y: scroll; flex-grow: 8 @@ -153,8 +153,6 @@ footer { padding: 10px; background: #212121; bottom: 0; - - background: green; } .navbar a {