-
Notifications
You must be signed in to change notification settings - Fork 124
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(namadillo): namadillo docker setup
- Loading branch information
1 parent
7d36081
commit ec5e0a8
Showing
2 changed files
with
31 additions
and
0 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
FROM rust:1.79 as builder | ||
WORKDIR /app | ||
RUN apt update && apt install -y nodejs npm clang pkg-config libssl-dev protobuf-compiler curl | ||
RUN npm install -g yarn | ||
RUN rustup target add wasm32-unknown-unknown | ||
RUN curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh -s -- -y | ||
COPY .yarnrc.yml tsconfig.base.json package.json yarn.lock . | ||
COPY ./.yarn ./.yarn | ||
COPY ./packages ./packages | ||
COPY ./scripts ./scripts | ||
COPY ./apps/namadillo/package.json ./apps/namadillo/package.json | ||
RUN yarn | ||
WORKDIR /app/apps/namadillo | ||
COPY ./apps/namadillo . | ||
RUN yarn | ||
RUN yarn build | ||
|
||
FROM nginx:alpine | ||
COPY --from=builder /app/apps/namadillo/dist /usr/share/nginx/html | ||
COPY ./docker/namadillo.conf /etc/nginx/conf.d/default.conf |
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,11 @@ | ||
server { | ||
listen 80; | ||
server_name localhost; | ||
location / { | ||
root /usr/share/nginx/html; | ||
index index.html index.htm; | ||
try_files $uri $uri/ $uri.html /index.html; | ||
} | ||
gzip on; | ||
gzip_types text/plain text/css application/javascript application/json application/vnd.ms-fontobject application/xml+rss application/atom+xml font/opentype font/ttf image/svg+xml; | ||
} |