Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

getting jibMaven dependencies: unable to stat file C:\\demos\\my-demo\\pom.xml\r: #1159

Closed
dkirrane opened this issue Oct 15, 2018 · 5 comments
Labels
build/jib kind/bug Something isn't working

Comments

@dkirrane
Copy link

Trying out the skaffold-jib support but hitting the following:

$ skaffold dev
Cleaning up...
Error: release: "my-demo" not found
Cleanup complete in 4.9536661s
time="2018-10-15T10:51:34+01:00" level=fatal msg="watching files for artifact nexus-mycompany.com/my-demo: listing files: listing files: getting jibMaven dependencies: unable to stat file C:\\demos\\my-demo\\pom.xml\r: CreateFile C:\\demos\\my-demo\\pom.xml\r: The filename, directory name, or volume label syntax is incorrect."

Expected behavior

Build, deploy and

Actual behavior

Information

  • Skaffold version: version: v0.16.0
  • Operating system: Windows 10 running from latest GitBash terminal
  • Contents of skaffold.yaml:
apiVersion: skaffold/v1alpha4
kind: Config

build:
  artifacts:
  - image: nexus-mycompany.com/my-demo
    jibMaven: 
      profile: prod
  tagPolicy:
      gitCommit: {}

deploy:
  helm:
    releases:
    - name: my-demo
      chartPath: helm
      valuesFiles:
        - values.yaml
      wait: true
      namespace: default
      version: "1.0"

Steps to reproduce the behavior

  1. create simple spring boot 2 app (version 2.0.5.RELEASE)
  2. added jib maven plugin to pom.xml
            <plugin>
                <groupId>com.google.cloud.tools</groupId>
                <artifactId>jib-maven-plugin</artifactId>
                <version>0.9.11</version>
            </plugin>
  1. skaffold dev
@dgageot dgageot added kind/bug Something isn't working build/jib labels Oct 15, 2018
@dgageot
Copy link
Contributor

dgageot commented Oct 15, 2018

ping @GoogleContainerTools/java-tools

@briandealwis
Copy link
Member

C:\\demos\\my-demo\\pom.xml\r ← looks like a carriage return has been appended!

@coollog
Copy link
Contributor

coollog commented Oct 15, 2018

Ah yes, since we only split the Maven dep listing on \n, on Windows, the Java line endings may be \r\n. Options include:

  • Having windows users set line ending to \n via for e.g., -Dline.separator=$'\n'
  • Changing out dep list processing to first replace all \r\n with \n

@loosebazooka
Copy link
Member

loosebazooka commented Oct 15, 2018

Shouldn't golang's readline handle this correctly?
I would think we go with option 2 in some form, but just handle windows correctly on the go side.

@briandealwis
Copy link
Member

I'll take this — I have to fix #1152 for the same thing.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
build/jib kind/bug Something isn't working
Projects
None yet
Development

No branches or pull requests

5 participants