Created
June 18, 2021 15:56
-
-
Save tylervz/4c65a392af1bbde5e8de2ac544405360 to your computer and use it in GitHub Desktop.
CircleCI Config and output for failing Micronaut Docker native build
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Picked up _JAVA_OPTIONS: -Xmx6g | |
> Task :compileJava | |
Note: Writing reflect-config.json file to destination: META-INF/native-image/thub.event.scheduler/thub-event-scheduler-cli-job/reflect-config.json | |
Note: Writing resource-config.json file to destination: META-INF/native-image/thub.event.scheduler/thub-event-scheduler-cli-job/resource-config.json | |
Note: Creating bean classes for 5 type elements | |
> Task :processResources UP-TO-DATE | |
> Task :classes | |
> Task :runnerJar | |
> Task :buildLayers | |
> Task :dockerfileNative | |
Dockerfile written to: /home/circleci/repo/build/docker/DockerfileNative | |
> Task :dockerBuildNative | |
Building image using context '/home/circleci/repo/build'. | |
Using Dockerfile '/home/circleci/repo/build/docker/DockerfileNative' | |
Using images '********************************************/thub-event-scheduler-cli-job-native:v0.1', '********************************************/thub-event-scheduler-cli-job-native:829a00546b12a8f13d335a288ee5f7ea7101cbf4'. | |
Step 1/11 : FROM ghcr.io/graalvm/graalvm-ce:java11-21.1.0 AS graalvm | |
---> 9762c6e631f0 | |
Step 2/11 : RUN gu install native-image | |
---> Using cache | |
---> fec0269f6c31 | |
Step 3/11 : WORKDIR /home/app | |
---> Using cache | |
---> 4dd27d34516e | |
Step 4/11 : COPY layers/libs /home/app/libs | |
---> Using cache | |
---> 63401826540f | |
Step 5/11 : COPY layers/resources /home/app/resources | |
---> Using cache | |
---> 90003f72f007 | |
Step 6/11 : COPY layers/application.jar /home/app/application.jar | |
---> 4ac00cc244ac | |
Step 7/11 : RUN native-image -H:Class=thub.event.scheduler.ThubEventSchedulerCliJobCommand -H:Name=application --no-fallback -cp /home/app/libs/*.jar:/home/app/resources:/home/app/application.jar | |
---> Running in bf1dbeb5eba4 | |
[application:26] classlist: 9,573.75 ms, 0.96 GB | |
[application:26] (cap): 1,104.57 ms, 0.96 GB | |
[application:26] setup: 4,832.68 ms, 0.96 GB | |
Error during callback | |
java.net.SocketTimeoutException: Read timed out | |
at com.bmuschko.gradle.docker.shaded.org.apache.hc.core5.http.impl.io.SessionInputBufferImpl.fillBuffer(SessionInputBufferImpl.java:149) | |
at com.bmuschko.gradle.docker.shaded.org.apache.hc.core5.http.impl.io.SessionInputBufferImpl.readLine(SessionInputBufferImpl.java:280) | |
at com.bmuschko.gradle.docker.shaded.org.apache.hc.core5.http.impl.io.ChunkedInputStream.getChunkSize(ChunkedInputStream.java:260) | |
at com.bmuschko.gradle.docker.shaded.org.apache.hc.core5.http.impl.io.ChunkedInputStream.nextChunk(ChunkedInputStream.java:221) | |
at com.bmuschko.gradle.docker.shaded.org.apache.hc.core5.http.impl.io.ChunkedInputStream.read(ChunkedInputStream.java:182) | |
at com.bmuschko.gradle.docker.shaded.org.apache.hc.core5.http.io.EofSensorInputStream.read(EofSensorInputStream.java:135) | |
at com.bmuschko.gradle.docker.shaded.com.fasterxml.jackson.core.json.UTF8StreamJsonParser._loadMore(UTF8StreamJsonParser.java:219) | |
at com.bmuschko.gradle.docker.shaded.com.fasterxml.jackson.core.json.UTF8StreamJsonParser._skipWSOrEnd2(UTF8StreamJsonParser.java:3005) | |
at com.bmuschko.gradle.docker.shaded.com.fasterxml.jackson.core.json.UTF8StreamJsonParser._skipWSOrEnd(UTF8StreamJsonParser.java:3000) | |
at com.bmuschko.gradle.docker.shaded.com.fasterxml.jackson.core.json.UTF8StreamJsonParser.nextToken(UTF8StreamJsonParser.java:716) | |
at com.bmuschko.gradle.docker.shaded.com.fasterxml.jackson.databind.MappingIterator.hasNextValue(MappingIterator.java:243) | |
at com.github.dockerjava.core.DefaultInvocationBuilder$JsonSink.accept(DefaultInvocationBuilder.java:314) | |
at com.github.dockerjava.core.DefaultInvocationBuilder$JsonSink.accept(DefaultInvocationBuilder.java:298) | |
at com.github.dockerjava.core.DefaultInvocationBuilder.lambda$executeAndStream$1(DefaultInvocationBuilder.java:275) | |
> Task :dockerBuildNative FAILED | |
FAILURE: Build failed with an exception. | |
* What went wrong: | |
Execution failed for task ':dockerBuildNative'. | |
> java.net.SocketTimeoutException: Read timed out | |
* Try: | |
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. | |
* Get more help at https://help.gradle.org | |
BUILD FAILED in 3m 21s | |
6 actionable tasks: 5 executed, 1 up-to-date | |
Exited with code exit status 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
version: 2.1 | |
orbs: | |
aws-ecr: circleci/aws-ecr@7.0.0 | |
gradle: circleci/gradle@2.2.0 | |
jobs: | |
test_and_push_docker_image_native: | |
description: > | |
Test and then build and push a Docker Image built with GraalVM Native Image | |
of the CLI Micronaut application | |
docker: | |
# Specify the primary container where all execution occurs | |
- image: cimg/openjdk:11.0 | |
environment: | |
# Configure the JVM and Gradle to avoid OOM errors | |
_JAVA_OPTIONS: "-Xmx4g" | |
working_directory: ~/repo | |
steps: | |
- checkout | |
# Download and cache dependencies | |
- restore_cache: | |
key: v1-gradle-wrapper-{{ checksum "gradle/wrapper/gradle-wrapper.properties" }} | |
- restore_cache: | |
key: v1-gradle-cache-{{ checksum "build.gradle" }} | |
# Clean the application before testing | |
- run: ./gradlew clean | |
# Run tests! | |
- run: | |
name: Test | |
command: ./gradlew test --stacktrace | |
when: always | |
- save_cache: | |
paths: | |
- ~/.gradle/wrapper | |
key: v1-gradle-wrapper-{{ checksum "gradle/wrapper/gradle-wrapper.properties" }} | |
- save_cache: | |
paths: | |
- ~/.gradle/caches | |
key: v1-gradle-cache-{{ checksum "build.gradle" }} | |
# Upload test results for display in Test Summary: https://circleci.com/docs/2.0/collect-test-data/ | |
- store_test_results: | |
path: build/test-results/test | |
when: always | |
- store_artifacts: # Upload test results for display in Artifacts: https://circleci.com/docs/2.0/artifacts/ | |
path: build/test-results/test | |
when: always | |
- setup_remote_docker: | |
docker_layer_caching: true | |
# Create the Docker image | |
- run: | |
no_output_timeout: "10m" | |
command: ./gradlew dockerBuildNative | |
workflows: | |
version: 2.1 | |
# This workflow only runs on commits pushed to branches other than master and deploy | |
checkout-build-test: | |
jobs: | |
- gradle/test: | |
filters: | |
branches: | |
ignore: | |
- master | |
- deploy | |
# This workflow only runs on commits pushed to master and deploy | |
build_and_push_master: | |
jobs: | |
- test_and_push_docker_image_native: | |
filters: | |
branches: | |
only: | |
# TODO: remove circleci after testing | |
- circleci | |
- master | |
- deploy |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment