Skip to content
New issue

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

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

Already on GitHub? # to your account

Error: buildx failed with: ERROR: failed to solve: dockerfile parse error on line 1: FROM requires either one or three arguments #3335

Open
rhwuHub opened this issue Jun 13, 2024 · 0 comments
Labels
bug Something isn't working

Comments

@rhwuHub
Copy link

rhwuHub commented Jun 13, 2024

Run docker/build-push-action@v5
GitHub Actions runtime token ACs
Docker info
Proxy configuration
Buildx version
Builder info
/usr/bin/docker buildx build --file ./Dockerfile --iidfile /home/runner/work/_temp/docker-actions-toolkit-FAlZHW/build-iidfile-5f972d5c25.txt --attest type=provenance,mode=max,builder-id=https://github.com/rhwuHub/action/actions/runs/9496964342 --tag registry.cn-hangzhou.aliyuncs.com/rhwu/hub:blog --metadata-file /home/runner/work/_temp/docker-actions-toolkit-FAlZHW/build-metadata-427ba9f59a.json --push .
#0 building with "builder-de9ce500-2f91-41c4-9b4b-4ed33cd97df4" instance using docker-container driver

#1 [internal] load build definition from dockerfile
#1 transferring dockerfile: 451B done
#1 DONE 0.0s
dockerfile:1

1 | >>> FROM registry.cn-hangzhou.aliyuncs.com/rhwu/hub:jdk-8 AS builder

WORKDIR /tmp

COPY . /tmp

RUN mvn package -Dmaven.test.skip=true -s /tmp/settings.xml

FROM registry.cn-hangzhou.aliyuncs.com/rhwu/hub:maven-jkd-8 as runner

WORKDIR /app

COPY --from=builder /tmp/Blog-server/target/blog.jar ./blog.jar

CMD ["java", "-agentlib:jdwp=transport=dt_socket,server=y,suspend=n,address=5005", "-jar", "/app/blog.jar"]

ERROR: failed to solve: dockerfile parse error on line 1: FROM requires either one or three arguments
Error: buildx failed with: ERROR: failed to solve: dockerfile parse error on line 1: FROM requires either one or three arguments

@rhwuHub rhwuHub added the bug Something isn't working label Jun 13, 2024
@rhwuHub rhwuHub closed this as completed Jun 13, 2024
@rhwuHub rhwuHub reopened this Jun 13, 2024
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant