public DescriptorDigest pushManifest(ManifestTemplate manifestTemplate, String imageTag)
      throws IOException, RegistryException {
    if (isBearerAuth(authorization.get()) && readOnlyBearerAuth) {
      throw new IllegalStateException("push may fail with pull-only bearer auth token");
    }

    return callRegistryEndpoint(
        new ManifestPusher(
            registryEndpointRequestProperties, manifestTemplate, imageTag, eventHandlers));
  }
Pushes the image manifest for a specific tag.

@param manifestTemplate the image manifest
@param imageTag the tag to push on
@return the digest of the pushed image
@throws IOException if communicating with the endpoint fails
@throws RegistryException if communicating with the endpoint fails
jib-core/src/main/java/com/google/cloud/tools/jib/registry/RegistryClient.java