All Questions
Tagged with npm-scripts docker
19 questions
0
votes
0
answers
730
views
I have in my microservice problem with nx
I am facing next error in deploying storybook its monorepo which needs to publish some packages into nexus also deploy storybook but in deploying one of the service here is design it shows this error ...
2
votes
1
answer
16k
views
failed to solve: failed to compute cache key: failed to calculate checksum of ref . . . "/app/build": not found
I was trying to dockerize a project by running docker compose up but this error is shown.
Here is the Dockerfile
FROM node:gallium-alpine3.18 as build
WORKDIR /app
COPY package.json .
COPY package-...
3
votes
0
answers
1k
views
yarn scripts local bin missing in PATH when installed outside of cwd
I have a docker container with yarn v1.22.19 installed. A .yarnrc file includes the line --modules-folder /node_modules to lift node_modules to the container's root directory. This is a workaround for ...
0
votes
1
answer
101
views
NPM scripts not running sequentially
I'm writing e2e tests with Supertest for my NestJS application and I have a "test:e2e" script which looks like this:
"test:e2e": "nerdctl compose up && dotenv -e .env....
1
vote
0
answers
461
views
Elegant Dotenv Preloading w/ package.json knex scripts
I am trying to find a more elegant way to preload my dotenv variables when running knex commands in my package.json scripts.
I was able to find a working solution here but it seems more convoluted ...
4
votes
1
answer
2k
views
pass variable to npm command string (not the script run by npm command) [duplicate]
Is it possible to pass an argument to the npm command string? The info might be somewhere in docs, but brief digging didn't get me any results, moreover, it is probably beneficial to the large ...
0
votes
1
answer
660
views
Docker stop all containers command in an NPM script?
When I run docker stop $(docker ps -a -q) to stop all Docker containers. It works fine. It stops all running containers.
But if I add to an NPM script, like:
package.json
"scripts": {
&...
0
votes
3
answers
3k
views
Can't run official Docker tutorial container: npm ERR! missing script: start
I'm trying to go through this part 2 of Docker's tutorial.
Here is my issue:
After creating successfully an image for the app, I try the command line (sudo) docker run --publish 8000:8080 --detach --...
3
votes
1
answer
8k
views
How can I pass docker environment variables to an npm script?
As the title says...As a noobie I've given this a good attempt but can't seem to figure it out.
I have a dockerfile
FROM node:12
WORKDIR /app
COPY . /app
RUN npm config set registry https://registry....
0
votes
1
answer
939
views
npm script is unable to find file in workdir in a docker container
This is my Dockerfile:
FROM node:12
WORKDIR /app
COPY . /app
RUN npm install
EXPOSE 3000
CMD ["npm", "start"]
This is the npm script in my package.json
"start": "...
0
votes
0
answers
285
views
Nodemon -L not working using npm script from package.json on Docker
I am trying to set up a development environment on docker. I am running code that I made from this project.
I have seem several answers on stack-overflow but none of them solves my issue.
My package....
0
votes
1
answer
2k
views
Run grunt from node:13:7 docker image?
I have this entry in my docker-compose.yml:
npm:
image: node:13.7
container_name: npm
volumes:
- ./src:/var/www/html
working_dir: /var/www/html
entrypoint: ['npm']
And I ...
0
votes
1
answer
1k
views
Docker-compose pass environment variable to docker container and into npm start
Having spent far too long on this, and read copious reference material on docker and many many stack overflow articles I have to admit defeat and ask the panel for help
What I want to achieve is to ...
0
votes
0
answers
983
views
Docker image unable to run postinstall script with error [email protected]~postinstall: cannot run in wd [email protected] node symLink.js (wd=/build)
I am building an docker image. My docker file is pretty simple as shown below:-
FROM node:10.15.3
RUN mkdir /build
WORKDIR /build
COPY package.json .
COPY . .
RUN ["npm", "install"]
EXPOSE ...
3
votes
4
answers
3k
views
Nodemon not working using npm script from package.json on Docker
I'm working with NodeJS and Nodemon on Docker. When I try to run my NodeJS app using nodemon command directly in docker compose file, it runs.
Like this (working): [docker-compose]
command: nodemon ...