Fixing earthfile
This commit is contained in:
parent
3ab6fc97e9
commit
012d0fe823
17
Dockerfile
17
Dockerfile
@ -1,17 +0,0 @@
|
||||
FROM node:12
|
||||
|
||||
LABEL maintainer="Fabian Stamm <dev@fabianstamm.de>"
|
||||
|
||||
RUN mkdir -p /usr/src/app
|
||||
WORKDIR /usr/src/app
|
||||
|
||||
RUN npm config set registry https://npm.hibas123.de
|
||||
|
||||
COPY ["package.json", "tsconfig.json", "/usr/src/app/"]
|
||||
|
||||
RUN npm install
|
||||
COPY src/ /usr/src/app/src
|
||||
COPY public/ /usr/src/app/public
|
||||
|
||||
EXPOSE 3000/tcp
|
||||
CMD ["npm", "run", "start"]
|
18
Earthfile
Normal file
18
Earthfile
Normal file
@ -0,0 +1,18 @@
|
||||
VERSION 0.7
|
||||
FROM node:lts-alpine3.18
|
||||
WORKDIR /build
|
||||
|
||||
docker-multi:
|
||||
BUILD --platform linux/amd64 --platform linux/arm64 +docker
|
||||
|
||||
docker:
|
||||
COPY package.json tsconfig.json .
|
||||
COPY src ./src
|
||||
COPY public ./public
|
||||
RUN yarn install
|
||||
RUN yarn build
|
||||
WORKDIR /build
|
||||
ENTRYPOINT ["node", "lib/index.js"]
|
||||
ARG EARTHLY_TARGET_TAG
|
||||
ARG TAG=$EARTHLY_TARGET_TAG
|
||||
SAVE IMAGE --push docker.hibas123.de/screenshare:$TAG
|
@ -1,7 +1,9 @@
|
||||
{
|
||||
"name": "ScreenSharingThing",
|
||||
"packageManager": "yarn@3.1.1",
|
||||
"version": "0.1.0",
|
||||
"scripts": {
|
||||
"build": "tsc",
|
||||
"dev": "ts-node src/index.ts"
|
||||
},
|
||||
"devDependencies": {
|
||||
|
19
public/design.html
Normal file
19
public/design.html
Normal file
@ -0,0 +1,19 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1">
|
||||
<title>Simple Screen Sharing</title>
|
||||
<link href="./styles.css" rel="stylesheet">
|
||||
</head>
|
||||
<body class="desktop">
|
||||
<div class="container">
|
||||
<div class="video">
|
||||
VIDEO
|
||||
</div>
|
||||
<div class="chat">
|
||||
CHAT
|
||||
</div>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
21
public/styles.css
Normal file
21
public/styles.css
Normal file
@ -0,0 +1,21 @@
|
||||
.desktop .container {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr auto;
|
||||
grid-template-rows: 1fr;
|
||||
grid-template-areas: "video chat";
|
||||
}
|
||||
|
||||
.mobile .container {
|
||||
display: grid;
|
||||
grid-template-columns: 1fr;
|
||||
grid-template-rows: auto 1fr;
|
||||
grid-template-areas: "video" "chat";
|
||||
}
|
||||
|
||||
.video {
|
||||
grid-area: video;
|
||||
}
|
||||
|
||||
.chat {
|
||||
grid-area: chat;
|
||||
}
|
@ -1,5 +1,6 @@
|
||||
{
|
||||
"compilerOptions": {
|
||||
"outDir": "lib",
|
||||
"target": "es2016" /* Set the JavaScript language version for emitted JavaScript and include compatible library declarations. */,
|
||||
"module": "commonjs" /* Specify what module code is generated. */,
|
||||
"moduleResolution": "node" /* Specify how the compiler resolves module names. */,
|
||||
|
Loading…
Reference in New Issue
Block a user