Skip to content

Trouble using rules_docker and the next.js example #947

Closed Answered by pwalker
pwalker asked this question in Q&A
Discussion options

You must be logged in to vote

OK, big LOL on this one. Just after I typed this all up, I realized it was right in front of me. In this line of the output with the workdir, it doesn't look like I'm passing the start argument to the next CLI:

Running './node_modules/.bin/next ' in /tmp/js_run_devserver-GEEsib/__main__/apps/alpha

I changed my container_image rule to include it, and it seems to work!

container_image(
    name = "image",
    architecture = "amd64",  # or arm64

    # Since js_binary depends on bash we have to bring in a base image that has bash
    base = "@debian_amd64//image",  # or "@debian_arm64//image", if you are on an arm machine
    # This is going to be /{root of js_image_layer}/{package_name()}/…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by pwalker
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
1 participant