Skip to content

Commit

Permalink
enable livekit plugin; fixed dockerfile (#8910)
Browse files Browse the repository at this point in the history
Co-authored-by: rithviknishad <mail@rithviknishad.dev>
  • Loading branch information
tellmeY18 and rithviknishad authored Oct 24, 2024
1 parent 7eee0ff commit a636843
Show file tree
Hide file tree
Showing 5 changed files with 47 additions and 24 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,4 @@ build
.dockerignore
Dockerfile
.git
apps
4 changes: 3 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,6 @@ REACT_CARE_API_URL=https://careapi.ohc.network
# Dev envs
ESLINT_NO_DEV_ERRORS=true
CARE_CDN_URL="https://egov-s3-facility-10bedicu.s3.amazonaws.com https://egov-s3-patient-data-10bedicu.s3.amazonaws.com http://localhost:4566"
REACT_ALLOWED_LOCALES="en,hi,ta,ml,mr,kn"
REACT_ALLOWED_LOCALES="en,hi,ta,ml,mr,kn"

REACT_ENABLED_APPS="ohcnetwork/care_livekit_fe@main"
7 changes: 4 additions & 3 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,17 @@ WORKDIR /app

ENV NODE_OPTIONS="--max-old-space-size=4096"

RUN if [ "$(uname -m)" = "aarch64" ] || [ "$(uname -m)" = "arm64" ]; then apt-get update && apt-get install -y python3-dev make g++; fi
RUN apt-get update && apt-get install -y git

RUN if [ "$(uname -m)" = "aarch64" ] || [ "$(uname -m)" = "arm64" ]; then apt-get install -y python3-dev make g++; fi


COPY package.json package-lock.json ./

RUN npm install

COPY . .

RUN npm run setup

RUN npm run build


Expand Down
45 changes: 32 additions & 13 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions scripts/setup-care-apps.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// eslint-disable-next-line @typescript-eslint/no-var-requires
const { execSync } = require("child_process");
const { execSync, spawnSync } = require("child_process");
// eslint-disable-next-line @typescript-eslint/no-var-requires
const fs = require("fs");
// eslint-disable-next-line @typescript-eslint/no-var-requires
Expand Down Expand Up @@ -33,12 +33,12 @@ const installApp = (app) => {
const appDir = path.join(appsDir, app.package.split("/")[1]);

console.log(`Cloning ${app.package}...`);
execSync(
`npx -y gitget ${app.package}${app.branch ? `#${app.branch}` : ""} apps/${app.package.split("/")[1]} `,
{
stdio: "inherit",
},
);

const cloneUrl = `https://github.com/${app.package.replace("github:", "")}.git`;
const branchOption = app.branch ? ["--branch", app.branch] : [];

spawnSync("git", ["clone", ...branchOption, cloneUrl, appDir]);

// Create a care-package.lock file
fs.writeFileSync(
path.join(appDir, "care-package.lock"),
Expand Down

0 comments on commit a636843

Please sign in to comment.