diff --git a/hw12_13_14_15_calendar/integration-tests.output b/hw12_13_14_15_calendar/integration-tests.output index 2a5be6e..68fcf66 100644 --- a/hw12_13_14_15_calendar/integration-tests.output +++ b/hw12_13_14_15_calendar/integration-tests.output @@ -1,32 +1,10 @@ -docker-compose -f deployments/docker-compose.yml up -d --build && \ - API_HOST=http://localhost:8888 ginkgo ./integration-tests && \ - docker-compose -f deployments/docker-compose.yml down -Step 1/8 : FROM golang:1.14-alpine - ---> 0223ac8ea40d -Step 2/8 : RUN apk update - ---> Using cache - ---> 939d8313abf6 -Step 3/8 : ENV GO111MODULE=on CGO_ENABLED=0 GOOS=linux - ---> Using cache - ---> 64eb44d83ba8 -Step 4/8 : WORKDIR /build - ---> Using cache - ---> 87b7c58f74fe -Step 5/8 : RUN go get 'github.com/pressly/goose/cmd/goose' - ---> Using cache - ---> 37c8932f986d -Step 6/8 : RUN mkdir -p /opt/db - ---> Using cache - ---> 709d7c2c4467 -Step 7/8 : COPY ./migrations /opt/db/migrations - ---> Using cache - ---> fce54de0a0d6 -Step 8/8 : ENTRYPOINT /go/bin/goose -v -dir /opt/db/migrations postgres "host=$DB_HOST port=$DB_PORT user=$DB_USER password=$DB_PASSWORD dbname=$DB_NAME sslmode=disable" up - ---> Using cache - ---> 2a8b144dc191 - -Successfully built 2a8b144dc191 -Successfully tagged deployments_migrator:latest +make integration-tests +docker-compose -f deployments/docker-compose.yml -f deployments/docker-compose.test.yml up -d --build && \ + API_HOST=http://localhost:8888 ginkgo ./integration-tests && \ + docker-compose -f deployments/docker-compose.yml -f deployments/docker-compose.test.yml down +WARNING: The POSTGRES_USER variable is not set. Defaulting to a blank string. +Creating network "deployments_default" with the default driver +Building queue Step 1/3 : FROM rabbitmq:3-management ---> 9dd69c24b09f Step 2/3 : RUN apt-get update @@ -38,6 +16,7 @@ Step 3/3 : RUN apt-get install -y netcat Successfully built 4dedbc3ea806 Successfully tagged deployments_queue:latest +Building calendar_sender Step 1/14 : FROM golang:1.14-alpine AS builder ---> 0223ac8ea40d Step 2/14 : RUN apk update @@ -56,34 +35,60 @@ Step 6/14 : RUN go mod download ---> Using cache ---> f2f881fd4fdb Step 7/14 : COPY . . - ---> e55eb0908cde + ---> Using cache + ---> c018e3e1decb Step 8/14 : ARG MAIN_FILE_PATH - ---> Running in 9f14e3803cf2 -Removing intermediate container 9f14e3803cf2 - ---> f930a425e3b3 + ---> Using cache + ---> c5a8b9b7216f Step 9/14 : RUN go build -o main $MAIN_FILE_PATH - ---> Running in 55d1350fe5c7 -Removing intermediate container 55d1350fe5c7 - ---> ebb1e38b5aff + ---> Using cache + ---> 7dc857d21e0c Step 10/14 : RUN chmod +x main - ---> Running in dfdba8581174 -Removing intermediate container dfdba8581174 - ---> 74593cba1344 + ---> Using cache + ---> c7d5e14bf29d Step 11/14 : FROM scratch - ---> + ---> Step 12/14 : COPY --from=builder /build/main / ---> Using cache - ---> 2fac9a18f714 + ---> 7006fab2c329 Step 13/14 : EXPOSE 8081 ---> Using cache - ---> 9a23c2b2318e + ---> b64dfa29f5bf Step 14/14 : ENTRYPOINT ["/main"] ---> Using cache - ---> a988a0f8f1f9 + ---> 574afba64b53 -Successfully built a988a0f8f1f9 -Successfully tagged deployments_calendar:latest +Successfully built 574afba64b53 +Successfully tagged deployments_calendar_sender:latest +Building migrator +Step 1/8 : FROM golang:1.14-alpine + ---> 0223ac8ea40d +Step 2/8 : RUN apk update + ---> Using cache + ---> 939d8313abf6 +Step 3/8 : ENV GO111MODULE=on CGO_ENABLED=0 GOOS=linux + ---> Using cache + ---> 64eb44d83ba8 +Step 4/8 : WORKDIR /build + ---> Using cache + ---> 87b7c58f74fe +Step 5/8 : RUN go get 'github.com/pressly/goose/cmd/goose' + ---> Using cache + ---> 37c8932f986d +Step 6/8 : RUN mkdir -p /opt/db + ---> Using cache + ---> 709d7c2c4467 +Step 7/8 : COPY ./migrations /opt/db/migrations + ---> Using cache + ---> fce54de0a0d6 +Step 8/8 : ENTRYPOINT /go/bin/goose -v -dir /opt/db/migrations postgres "host=$DB_HOST port=$DB_PORT user=$DB_USER password=$DB_PASSWORD dbname=$DB_NAME sslmode=disable" up + ---> Using cache + ---> 2a8b144dc191 + +Successfully built 2a8b144dc191 +Successfully tagged deployments_migrator:latest +Building calendar Step 1/14 : FROM golang:1.14-alpine AS builder ---> 0223ac8ea40d Step 2/14 : RUN apk update @@ -102,34 +107,33 @@ Step 6/14 : RUN go mod download ---> Using cache ---> f2f881fd4fdb Step 7/14 : COPY . . - ---> 2825fe9f9822 + ---> Using cache + ---> c018e3e1decb Step 8/14 : ARG MAIN_FILE_PATH - ---> Running in 38b5cd118b5a -Removing intermediate container 38b5cd118b5a - ---> 6e195a637345 + ---> Using cache + ---> c5a8b9b7216f Step 9/14 : RUN go build -o main $MAIN_FILE_PATH - ---> Running in b044cf97ed1a -Removing intermediate container b044cf97ed1a - ---> 2f79776ae929 + ---> Using cache + ---> 6fe1758526a0 Step 10/14 : RUN chmod +x main - ---> Running in cb3849850f78 -Removing intermediate container cb3849850f78 - ---> b9cc19548077 + ---> Using cache + ---> 34beafe8ea5b Step 11/14 : FROM scratch - ---> + ---> Step 12/14 : COPY --from=builder /build/main / ---> Using cache - ---> e20e97826935 + ---> 2fac9a18f714 Step 13/14 : EXPOSE 8081 ---> Using cache - ---> dcd21bfb36cc + ---> 9a23c2b2318e Step 14/14 : ENTRYPOINT ["/main"] ---> Using cache - ---> e8c54c1c3744 + ---> a988a0f8f1f9 -Successfully built e8c54c1c3744 -Successfully tagged deployments_calendar_scheduler:latest +Successfully built a988a0f8f1f9 +Successfully tagged deployments_calendar:latest +Building calendar_scheduler Step 1/14 : FROM golang:1.14-alpine AS builder ---> 0223ac8ea40d Step 2/14 : RUN apk update @@ -148,51 +152,70 @@ Step 6/14 : RUN go mod download ---> Using cache ---> f2f881fd4fdb Step 7/14 : COPY . . - ---> 0b632b8b2b1d + ---> Using cache + ---> c018e3e1decb Step 8/14 : ARG MAIN_FILE_PATH - ---> Running in 6c19e6b41c64 -Removing intermediate container 6c19e6b41c64 - ---> 38dd545c8936 + ---> Using cache + ---> c5a8b9b7216f Step 9/14 : RUN go build -o main $MAIN_FILE_PATH - ---> Running in a87c83becfca -Removing intermediate container a87c83becfca - ---> 5bdf3d96a4a6 + ---> Using cache + ---> 2f5d86796704 Step 10/14 : RUN chmod +x main - ---> Running in cab719bc7494 -Removing intermediate container cab719bc7494 - ---> f774a1eb2ed1 + ---> Using cache + ---> 67bff6d26489 Step 11/14 : FROM scratch - ---> + ---> Step 12/14 : COPY --from=builder /build/main / ---> Using cache - ---> 7006fab2c329 + ---> e20e97826935 Step 13/14 : EXPOSE 8081 ---> Using cache - ---> b64dfa29f5bf + ---> dcd21bfb36cc Step 14/14 : ENTRYPOINT ["/main"] ---> Using cache - ---> 574afba64b53 + ---> e8c54c1c3744 -Successfully built 574afba64b53 -Successfully tagged deployments_calendar_sender:latest +Successfully built e8c54c1c3744 +Successfully tagged deployments_calendar_scheduler:latest +Creating deployments_queue_1 ... done +Creating deployments_db_1 ... done +Creating deployments_calendar_1 ... done +Creating deployments_migrator_1 ... done +Creating deployments_calendar_scheduler_1 ... done +Creating deployments_calendar_sender_1 ... done Running Suite: Tests Suite ========================== -Random Seed: 1600037016 -Will run 8 of 8 specs +Random Seed: 1600038253 +Will run 8 of 8 specs -• [SLOW TEST:10.025 seconds] +••••••• +------------------------------ +• [SLOW TEST:10.014 seconds] Sender -/Users/gremlin/education/otus/golang/otus-go/otus-golang-hw/hw12_13_14_15_calendar/integration-tests/sender_test.go:12 +/Users/gremlin/education/otus/golang/otus-go/otus-golang-hw/hw12_13_14_15_calendar/integration-tests/sender_test.go:12 Event - /Users/gremlin/education/otus/golang/otus-go/otus-golang-hw/hw12_13_14_15_calendar/integration-tests/sender_test.go:13 + /Users/gremlin/education/otus/golang/otus-go/otus-golang-hw/hw12_13_14_15_calendar/integration-tests/sender_test.go:13 should receive event - /Users/gremlin/education/otus/golang/otus-go/otus-golang-hw/hw12_13_14_15_calendar/integration-tests/sender_test.go:14 ------------------------------- -••••••• -Ran 8 of 8 Specs in 10.184 seconds -SUCCESS! -- 8 Passed | 0 Failed | 0 Pending | 0 Skipped + /Users/gremlin/education/otus/golang/otus-go/otus-golang-hw/hw12_13_14_15_calendar/integration-tests/sender_test.go:14 +------------------------------ + +Ran 8 of 8 Specs in 10.205 seconds +SUCCESS! -- 8 Passed | 0 Failed | 0 Pending | 0 Skipped PASS -Ginkgo ran 1 suite in 11.667739329s +Ginkgo ran 1 suite in 11.265731675s Test Suite Passed +WARNING: The POSTGRES_USER variable is not set. Defaulting to a blank string. +Stopping deployments_calendar_sender_1 ... done +Stopping deployments_calendar_scheduler_1 ... done +Stopping deployments_calendar_1 ... done +Stopping deployments_db_1 ... done +Stopping deployments_queue_1 ... done +Removing deployments_calendar_sender_1 ... done +Removing deployments_calendar_scheduler_1 ... done +Removing deployments_migrator_1 ... done +Removing deployments_calendar_1 ... done +Removing deployments_db_1 ... done +Removing deployments_queue_1 ... done +Removing network deployments_default \ No newline at end of file