упаковал всё в docker-compose

This commit is contained in:
2025-04-15 20:50:01 +03:00
parent 9312ec1f2d
commit 3245ffa10f
6 changed files with 64 additions and 11 deletions

9
lab3/consumer/Dockerfile Normal file
View File

@@ -0,0 +1,9 @@
FROM gradle:8.13-jdk21
WORKDIR /app
COPY . .
RUN gradle build --no-daemon
CMD ["gradle", "run", "--no-daemon"]

View File

@@ -10,7 +10,7 @@ public class Recv {
public static void main(String[] argv) throws Exception {
ConnectionFactory factory = new ConnectionFactory();
factory.setHost("localhost");
factory.setHost("rabbitmq");
Connection connection = factory.newConnection();
Channel channel = connection.createChannel();