Skip to content

Commit

Permalink
🧱 - Enhanced Cross-Platform Compatibility and Docker Environment Setup (
Browse files Browse the repository at this point in the history
#374)

Co-authored-by: Matan Mashraki <[email protected]>
  • Loading branch information
YonLiud and planecore authored Aug 2, 2024
1 parent 29016a1 commit a10bc45
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 3 deletions.
6 changes: 6 additions & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
node_modules
.git
.gitignore
.dockerignore
Dockerfile
README.md
20 changes: 20 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
FROM node:22

ENV ENVIRONMENT=development

WORKDIR /usr/src/app

COPY package.json yarn.lock ./

COPY . .

RUN yarn install --verbose

RUN yarn rename-dev-configs

EXPOSE 8081

# To start the app after building it using `docker build -t better-rail-app .` with docker
# run: `docker run -it -p 8081:8081 better-rail-app yarn start`

# CMD ["yarn", "start"]
2 changes: 1 addition & 1 deletion android/gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@
# Specifies the JVM arguments used for the daemon process.
# The setting is particularly useful for tweaking memory settings.
# Default value: -Xmx512m -XX:MaxMetaspaceSize=256m
org.gradle.jvmargs=-Xmx2048m -XX:MaxMetaspaceSize=512m
org.gradle.jvmargs=-Xmx1024m -XX:MaxMetaspaceSize=256m

# When configured, Gradle will run in incubating parallel mode.
# This option should only be used with decoupled projects. More details, visit
Expand Down
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,10 @@
"storybook": "start-storybook -p 9001 -c ./storybook",
"test": "jest",
"adb": "adb reverse tcp:9090 tcp:9090 && adb reverse tcp:3000 tcp:3000 && adb reverse tcp:9001 tcp:9001 && adb reverse tcp:8081 tcp:8081",
"postinstall": "patch-package; node ./bin/postInstall;",
"postinstall": "patch-package && node ./bin/postInstall",
"build-ios": "react-native bundle --entry-file index.js --platform ios --dev false --bundle-output ios/main.jsbundle --assets-dest ios",
"build-android": "react-native bundle --platform android --dev false --entry-file index.js --bundle-output android/app/src/main/assets/index.android.bundle --assets-dest android/app/src/main/res",
"rename-dev-configs": "cp ios/GoogleService-Info.development.plist ios/GoogleService-Info.plist; cp android/app/google-services.development.json android/app/google-services.json"
"rename-dev-configs": "cp ios/GoogleService-Info.development.plist ios/GoogleService-Info.plist && cp android/app/google-services.development.json android/app/google-services.json"
},
"dependencies": {
"@expo/react-native-action-sheet": "4.0.1",
Expand Down

0 comments on commit a10bc45

Please sign in to comment.