Skip to content

Commit

Permalink
Add docker build
Browse files Browse the repository at this point in the history
  • Loading branch information
dustinsoftware committed Mar 23, 2019
1 parent 1e17606 commit d60d9a7
Show file tree
Hide file tree
Showing 3 changed files with 39 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
.git/
node_modules/
dist/
*.generated.js
9 changes: 9 additions & 0 deletions .github/main.workflow
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
workflow "Build, Test" {
on = "push"
resolves = ["Docker build"]
}

action "Docker build" {
uses = "actions/docker/cli@master"
args = "build . -f Dockerfile.mono"
}
26 changes: 26 additions & 0 deletions Dockerfile.mono
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
FROM node:10 AS node-build

COPY . /app

WORKDIR /app/src/React.Core

RUN npm i
RUN npm run build

WORKDIR /app/src/React.Core/babel-legacy

RUN npm i
RUN npm run build

WORKDIR /app/src/React.Sample.Webpack.CoreMvc

RUN npm i
RUN npm run build

FROM mono:latest AS mono

COPY . /app

COPY --from=node-build /app/src/React.Core/Resources /app/src/React.Core/Resources

RUN mono --version

0 comments on commit d60d9a7

Please sign in to comment.