question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Issue with docker deployment

See original GitHub issue

NOTE: I am new in docker thing and maven projects (I am an android developer)

I’ve been trying javalin, and following this tutorial, and met with an error

Failed to execute goal org.apache.maven.plugins:maven-deploy-plugin:2.7:deploy (default-deploy) on project my-javalin: Failed to deploy artifacts/metadata: Cannot access your-snapshot-repo-url with type default using the available connector factories: BasicRepositoryConnectorFactory: Cannot access your-snapshot-repo-url using the registered transporter factories: WagonTransporterFactory: Unsupported transport protocol -> [Help 1]

Here’s my pom.xml

<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
    <modelVersion>4.0.0</modelVersion>

    <groupId>com.mygroup</groupId>
    <artifactId>my-javalin</artifactId>
    <version>1.0-SNAPSHOT</version>

    <!-- library dependencies -->
    <dependencies>
        <dependency>
            <groupId>io.javalin</groupId>
            <artifactId>javalin</artifactId>
            <version>3.1.0</version>
        </dependency>

        <dependency>
            <groupId>org.slf4j</groupId>
            <artifactId>slf4j-simple</artifactId>
            <version>1.7.26</version>
        </dependency>


    </dependencies>

    <distributionManagement>
        <repository>
            <id>repo</id>
            <name>Internal release</name>
            <url>your-snapshot-repo-url</url>
        </repository>
    </distributionManagement>

    <build>
        <plugins>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-compiler-plugin</artifactId>
                <version>2.3.2</version>
                <configuration>
                    <source>1.8</source>
                    <target>1.8</target>
                </configuration>
            </plugin>
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-shade-plugin</artifactId>
                <version>3.1.0</version>
                <executions>
                    <!-- Run shade goal on package phase -->
                    <execution>
                        <phase>package</phase>
                        <goals>
                            <goal>shade</goal>
                        </goals>
                        <configuration>
                            <shadedArtifactAttached>true</shadedArtifactAttached>
                            <transformers>
                                <!-- add Main-Class to manifest file -->
                                <transformer
                                        implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
                                    <mainClass>HelloWorld</mainClass>
                                </transformer>
                            </transformers>
                        </configuration>
                    </execution>
                </executions>
            </plugin>

            <plugin>
                <groupId>com.spotify</groupId>
                <artifactId>dockerfile-maven-plugin</artifactId>
                <version>1.3.6</version>
                <executions>
                    <execution>
                        <id>default</id>
                        <goals>
                            <goal>build</goal>
                            <goal>push</goal>
                        </goals>
                    </execution>
                </executions>
                <configuration>
                    <repository>localhost:5000/javalin</repository>
                    <tag>${project.version}</tag>
                    <buildArgs>
                        <JAR_FILE>${project.build.finalName}-shaded.jar</JAR_FILE>
                    </buildArgs>
                </configuration>
            </plugin>

        </plugins>
    </build>


</project>

I think it happened because I didn’t give snapshot-repo-url (line#32). I didn’t see any replacement for that placeholder in the above mentioned article.

So, what should I replace with your-snapshot-repo-url ?

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (4 by maintainers)

github_iconTop GitHub Comments

2reactions
tipsycommented, Jun 27, 2019

I’m not very familiar with Docker, but I’ve tagged the question, so hopefully someone else can answer it.

0reactions
tipsycommented, Jul 18, 2019

Going to close this since it’s been inactive for two weeks. Feel free to keep writing in the issue though.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Note these ops issues before you deploy with Docker containers
Difficulty visualizing what actually happens when you connect Docker containers to build componentized applications leads to inefficient data ...
Read more >
Top 5 challenges with deploying docker containers in production
Docker containers make app development easier. But deploying them in production can be hard. · Controlling the complexity of extremely dense, ...
Read more >
Deploy your app - Docker Documentation
Learn how to deploy your application. ... Let us know what you think by creating an issue in the Docker Docs GitHub repository....
Read more >
Docker Deployment - How to Deploy a Web app With Docker?
Docker solves this problem by placing apps in virtual Containers that all run on the same operating system. Each container contains all the...
Read more >
How to Debug and Fix Common Docker Issues - DigitalOcean
Unfortunately, problems may arise when building your image and integrating all of the layers that your app needs, especially if you're new to ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found