-
Notifications
You must be signed in to change notification settings - Fork 144
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #13 from maxmcd/docker-web-client
Docker web client
- Loading branch information
Showing
4 changed files
with
45 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,14 @@ | ||
version: '3.3' | ||
services: | ||
app: | ||
build: . | ||
base: | ||
build: | ||
context: . | ||
dockerfile: Dockerfile | ||
image: maxmcd/webtty-node-go | ||
web-client: | ||
build: | ||
context: . | ||
dockerfile: ./web-client/Dockerfile | ||
image: maxmcd/webtty-client | ||
ports: | ||
- 8080:80 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
FROM maxmcd/webtty-node-go:latest as builder | ||
|
||
COPY . . | ||
RUN go get -v . \ | ||
&& cd ./web-client \ | ||
&& npm install \ | ||
&& npm run build | ||
|
||
FROM nginx:alpine | ||
|
||
RUN echo "application/wasm wasm" >> /etc/mime.types \ | ||
&& sed -i -e 's/wmlc;/wmlc;\n application\/wasm wasm;\n/g' /etc/nginx/mime.types | ||
|
||
COPY --from=builder \ | ||
/go/src/github.com/maxmcd/webtty/web-client/dist \ | ||
/usr/share/nginx/html | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters