Tiny UI library for Preact https://git.dany.dev/dsluijk/teenyui
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

46 lines
1.1 KiB

  1. # Use the NodeJS image as builder
  2. FROM node:lts AS builder
  3. # Create the workspace
  4. RUN mkdir -p /usr/src/app/example
  5. WORKDIR /usr/src/app
  6. # Copy over the package, and install the dependencies
  7. COPY package.json /usr/src/app
  8. COPY example/package.json /usr/src/app/example
  9. RUN yarn
  10. WORKDIR /usr/src/app/example
  11. RUN yarn
  12. WORKDIR /usr/src/app
  13. # Copy over the other files.
  14. COPY src /usr/src/app/src
  15. COPY theme /usr/src/app/theme
  16. COPY rollup.config.js /usr/src/app
  17. COPY tsconfig.json /usr/src/app
  18. # Build the application
  19. RUN yarn build
  20. # Switch to the example folder
  21. WORKDIR /usr/src/app/example
  22. # Copy over the other files.
  23. COPY example/.sassrc /usr/src/app/example
  24. COPY example/tsconfig.json /usr/src/app/example
  25. COPY example/src /usr/src/app/example/src
  26. # Build the example
  27. RUN yarn build
  28. # The actual server, this builds the final image
  29. FROM nginx:alpine
  30. # Copy the nginx configuration
  31. COPY nginx.conf /etc/nginx/nginx.conf
  32. # Copy the output of the builder
  33. COPY --from=builder /usr/src/app/example/dist /usr/share/nginx/html
  34. RUN chown nginx:nginx /usr/share/nginx/html/ -R
  35. EXPOSE 80