Building a container in gopaddle may fail due to a few reasons. Some of these failures may be due to insufficient capacity allocated for the build environment or available on the Kubernetes nodes. The below list summarizes the failures seen under the Events section in the build page and the corresponding errors in the Build Logs section.
π Event: failed on preparing distribution image
π Build Logs error building image: unsupported status code 401; body: Not Authorized
π Reason for failure
This failure happens when a Build Base Image or Runtime Base Image cannot be pulled from the Docker Registry due to unathorized access or the final Distribution Docker Image cannot be pushed to the Distribution Docker Registry due to unauthorized access.
π‘ Solution
Ensure that the Docker Registries configured in the Container Build Configuration has been registered with gopaddle with correct access credentials. Say if the a Docker Private Registry is registered with gopaddle, ensure that the Username and the token provided are valid.
π Event: failed on preparing distribution image
π Build Logs error checking push permissions -- make sure you entered the correct tag name, and that you are authenticated correctly, and try again: checking push permission for "--------.dkr.ecr.ap-southeast-2.amazonaws.com/------------": DENIED: Your authorization token has expired. Reauthenticate and try again.
π Reason for failure
This failure happens when a Build Base Image or Runtime Base Image cannot be pulled from the Docker Registry due to unathorized access or the final Distribution Docker Image cannot be pushed to the Distribution Docker Registry as the registry access token expired.
π‘ Solution
Check if the Docker registry access token is still valid. If it has expired, then re-generate a new access token from the Docker hub. Edit the Registry information registered with gopaddle. Update the new token and re-build the container again.
π Event : NotReachable (failed on reaching build)
π Build Logs No errors in log
π Reason for failure
This failure can happen when the build job was terminated manually inside the Kubernetes Cluster or if the Cluster is not reachable.
π‘ Solution
Ensure the Cluster is in Running state.
π Event : failed on executing prebuild/build script
π Build Logs Build Error Logs has the error in executing the pre-build or build script
π Reason for failure
This failure can happen if the pre-build or build script had errors.
π‘ Solution
Check the Build Logs for detailed information on the script execution failure.
π Event : 0/4 nodes are available: 1 Insufficient memory, 4 Insufficient cpu.
π Build Logs No logs
π Reason for failure
This failure happens when the nodes in the Kubernetes cluster where the build is initiated doesn't have sufficient capacity to schedule the build.
π‘ Solution
Update the Build Environment capacity for the container under the Release -> Distribution -> Build Configuration details. Retry building the container once again on the same Kubernetes cluster.
π Event: OOMKilled
π Build Logs 107 Killed
π Reason for failure
This failure happens when the allocation capacity set in the Build Configuration of a container is not sufficient to complete the build process.
π‘ Solution
Update the Build Environment capacity with additional memory/cpu for the container under the Release -> Distribution -> Build Configuration details. Rebuild the container with increased capacity.
π Event: failed on ErrImagePull
π Reason for failure - 1
This failure happens when docker login to either the Build Base Image Registry or Runtime Base Image Registry or Distribution Image Registry or gopaddle Build Agent registry fails for the first time, but might succeed after a few retries.
π‘ Solution - 1
Rebuild the container until the build succeeds.
π Reason for failure - 2
Can happen when the bild process could not pull the build base image.
π‘ Solution - 2
Make sure the build base image exists in the docker hub and the docker registry containing the private build base image is registered in gopaddle.