dockering hard
This commit is contained in:
parent
89e7770f06
commit
e14335bdff
17
Dockerfile
Normal file
17
Dockerfile
Normal file
|
@ -0,0 +1,17 @@
|
||||||
|
FROM node:14-stretch AS build
|
||||||
|
WORKDIR /build/
|
||||||
|
COPY package.json yarn.lock ./
|
||||||
|
RUN yarn install --frozen-lockfile
|
||||||
|
COPY . .
|
||||||
|
RUN yarn build
|
||||||
|
|
||||||
|
FROM node:14-stretch AS prod
|
||||||
|
WORKDIR /app/
|
||||||
|
RUN apt-get update -y
|
||||||
|
RUN apt-get install -y ffmpeg
|
||||||
|
COPY --from=build /build/package.json /build/yarn.lock ./
|
||||||
|
COPY --from=build /build/dist ./dist
|
||||||
|
COPY assets ./assets
|
||||||
|
RUN yarn install --production --frozen-lockfile
|
||||||
|
|
||||||
|
CMD ["yarn", "start"]
|
10
docker-compose.yml
Normal file
10
docker-compose.yml
Normal file
|
@ -0,0 +1,10 @@
|
||||||
|
version: '3'
|
||||||
|
services:
|
||||||
|
app:
|
||||||
|
build: .
|
||||||
|
restart: unless-stopped
|
||||||
|
ports:
|
||||||
|
- "6969:6969"
|
||||||
|
volumes:
|
||||||
|
# the directory where the transcoded videos are "cached"
|
||||||
|
- ./temp:/app/tmp
|
|
@ -16,5 +16,8 @@
|
||||||
"@types/fluent-ffmpeg": "^2.1.18",
|
"@types/fluent-ffmpeg": "^2.1.18",
|
||||||
"express": "^4.17.1",
|
"express": "^4.17.1",
|
||||||
"fluent-ffmpeg": "^2.1.2"
|
"fluent-ffmpeg": "^2.1.2"
|
||||||
|
},
|
||||||
|
"devDependencies": {
|
||||||
|
"typescript": "^4.3.5"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -439,6 +439,11 @@ type-is@~1.6.17, type-is@~1.6.18:
|
||||||
media-typer "0.3.0"
|
media-typer "0.3.0"
|
||||||
mime-types "~2.1.24"
|
mime-types "~2.1.24"
|
||||||
|
|
||||||
|
typescript@^4.3.5:
|
||||||
|
version "4.3.5"
|
||||||
|
resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.3.5.tgz#4d1c37cc16e893973c45a06886b7113234f119f4"
|
||||||
|
integrity sha512-DqQgihaQ9cUrskJo9kIyW/+g0Vxsk8cDtZ52a3NGh0YNTfpUSArXSohyUGnvbPazEPLu398C0UxmKSOrPumUzA==
|
||||||
|
|
||||||
unpipe@1.0.0, unpipe@~1.0.0:
|
unpipe@1.0.0, unpipe@~1.0.0:
|
||||||
version "1.0.0"
|
version "1.0.0"
|
||||||
resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec"
|
resolved "https://registry.yarnpkg.com/unpipe/-/unpipe-1.0.0.tgz#b2bf4ee8514aae6165b4817829d21b2ef49904ec"
|
||||||
|
|
Loading…
Reference in a new issue