Skip to content

Commit

Permalink
Copied saturn-eval frontend
Browse files Browse the repository at this point in the history
  • Loading branch information
kiriakos committed Feb 3, 2021
0 parents commit b1eefce
Show file tree
Hide file tree
Showing 40 changed files with 9,652 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
node_modules
dist
35 changes: 35 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
FROM node:13 as build

# set working directory
RUN mkdir /usr/src/app
WORKDIR /usr/src/app

RUN curl -L -o elm.gz https://github.com/elm/compiler/releases/download/0.19.1/binary-for-linux-64-bit.gz && gunzip elm.gz && chmod +x elm && mv elm /usr/local/bin/ && elm --help

# add `/usr/src/app/node_modules/.bin` to $PATH
ENV PATH /usr/src/app/node_modules/.bin:$PATH

# install and cache app dependencies
COPY package.json /usr/src/app/package.json
RUN rm -rf /root/.node-gyp

# add app
COPY . /usr/src/app
RUN npm install
RUN npm rebuild node-sass
RUN npm run package

#production stage
FROM httpd:2.4-alpine

ENV BACKEND_URL=https://focus-backend.saturn.industries

COPY --from=build /usr/src/app/dist /usr/local/apache2/htdocs

COPY devops /usr/local/apache2/devops
RUN ls -l /usr/local/apache2
RUN echo "Include devops/settie-fe*.conf" >> /usr/local/apache2/conf/httpd.conf

ENTRYPOINT ["/usr/local/apache2/devops/configure.sh"]
CMD ["httpd-foreground"]

41 changes: 41 additions & 0 deletions Dockerfile-pu
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
# build stage
# base image
FROM node:9 AS build


# set working directory
RUN mkdir /usr/src/app
WORKDIR /usr/src/app

# add `/usr/src/app/node_modules/.bin` to $PATH
ENV PATH /usr/src/app/node_modules/.bin:$PATH

# install and cache app dependencies
COPY package.json /usr/src/app/package.json
RUN rm -rf /root/.node-gyp

# NOTE: we are running with --unsafe-perm do get around an EACCESS problem
# shoud be weeded out correctly


# add app
COPY . /usr/src/app
RUN npm install --unsafe-perm
RUN npm run build

#production stage
FROM httpd:2.4-alpine

ENV BACKEND_URL=https://demo.settie-backend.cd.dsnexus.org
ENV FRONTEND_UPLOAD_PORTAL_URL=https://demo.settie-upload-portal.cd.dsnexus.org


COPY --from=build /usr/src/app/dist /usr/local/apache2/htdocs

COPY devops /usr/local/apache2/devops
RUN ls -l /usr/local/apache2
RUN echo "Include devops/settie-fe*.conf" >> /usr/local/apache2/conf/httpd.conf

ENTRYPOINT ["/usr/local/apache2/devops/configure.sh"]
CMD ["httpd-foreground"]

9 changes: 9 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
# Moved

```
npm install
npm run dev
```
Should start a hot reloading dev server


7 changes: 7 additions & 0 deletions assets/gen-icons.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
#!/bin/bash

convert saturn.png -resize 180x180 -quality 100 icons/apple-touch-icon.png
convert saturn.png -resize 32x32 -quality 100 icons/favicon-32.png
convert saturn.png -resize 16x16 -quality 100 icons/favicon-16.png
cp saturn-2.svg icons/safari-pinned-tab.svg

Binary file added assets/icons/apple-touch-icon.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/icons/favicon-16.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/icons/favicon-32.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
165 changes: 165 additions & 0 deletions assets/icons/safari-pinned-tab.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading

0 comments on commit b1eefce

Please sign in to comment.