diff options
author | terminaldweller <thabogre@gmail.com> | 2022-07-07 03:00:57 +0000 |
---|---|---|
committer | terminaldweller <thabogre@gmail.com> | 2022-07-07 03:00:57 +0000 |
commit | 8a034aa4f10bfbc317fde0cf6ee3a0f2b5642d52 (patch) | |
tree | d171d983dff76afedcb3cd3a92afc9224b03239c | |
parent | Merge branch 'rss' (diff) | |
download | blog-8a034aa4f10bfbc317fde0cf6ee3a0f2b5642d52.tar.gz blog-8a034aa4f10bfbc317fde0cf6ee3a0f2b5642d52.zip |
a branch for bun which currently doesnt work because bun cant run a real programbun
-rw-r--r-- | Dockerfile | 12 | ||||
-rw-r--r-- | docker-compose-test.yaml | 4 | ||||
-rwxr-xr-x | server.js | 2 |
3 files changed, 12 insertions, 6 deletions
@@ -1,12 +1,18 @@ -FROM alpine:3.15 AS certbuilder +# vi: ft=Dockerfile +FROM alpine:3.16 AS certbuilder RUN apk add openssl WORKDIR /certs RUN openssl req -nodes -new -x509 -subj="/C=US/ST=Denial/L=springfield/O=Dis/CN=localhost" -keyout server.key -out server.cert -FROM node:lts-alpine3.15 +FROM debian:bullseye-slim +RUN apt update && apt-get install -y bash curl unzip +RUN curl https://bun.sh/install | bash +# COPY /root/.bun/bin/bun /usr/bin/ +ENV PATH="/root/.bun/bin:${PATH}" COPY --from=certbuilder /certs/ /certs COPY ./package.* /server/ -RUN cd /server && npm install --production +WORKDIR /server +RUN /root/.bun/bin/bun install COPY ./css /server/css/ COPY ./views /server/views/ COPY ./static /server/static/ diff --git a/docker-compose-test.yaml b/docker-compose-test.yaml index fceb9b9..8596ac8 100644 --- a/docker-compose-test.yaml +++ b/docker-compose-test.yaml @@ -1,7 +1,7 @@ version: "3.7" services: - blog: - image: blog + bunblog: + image: bunblog build: context: . networks: @@ -1,4 +1,4 @@ -#!/usr/bin/env node +#!/root/.bun/bin/bun "use strict"; const express = require("express"); |