drbh
commited on
Commit
Β·
0b1afcf
1
Parent(s):
6f5b644
feat: add docker and hf config
Browse files- Dockerfile +42 -0
- README.md +10 -40
Dockerfile
ADDED
@@ -0,0 +1,42 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
# Simple Remix app Dockerfile
|
2 |
+
FROM node:20-alpine
|
3 |
+
|
4 |
+
# Install basic dependencies
|
5 |
+
RUN apk add --no-cache curl tini
|
6 |
+
|
7 |
+
WORKDIR /app
|
8 |
+
|
9 |
+
# Create non-root user for security
|
10 |
+
RUN addgroup -g 1001 -S nodejs && \
|
11 |
+
adduser -S remix -u 1001
|
12 |
+
|
13 |
+
# Copy package files
|
14 |
+
COPY package*.json ./
|
15 |
+
|
16 |
+
# Install ALL dependencies (needed for build)
|
17 |
+
RUN npm ci && npm cache clean --force
|
18 |
+
|
19 |
+
# Copy application code
|
20 |
+
COPY --chown=remix:nodejs . .
|
21 |
+
|
22 |
+
# Build the Remix app
|
23 |
+
RUN npm run build
|
24 |
+
|
25 |
+
# Remove dev dependencies after build
|
26 |
+
RUN npm prune --production && npm cache clean --force
|
27 |
+
|
28 |
+
# Switch to non-root user
|
29 |
+
USER remix
|
30 |
+
|
31 |
+
# Expose port 3000
|
32 |
+
EXPOSE 3000
|
33 |
+
|
34 |
+
# Health check
|
35 |
+
HEALTHCHECK --interval=30s --timeout=10s --start-period=30s --retries=3 \
|
36 |
+
CMD curl -f http://localhost:3000 || exit 1
|
37 |
+
|
38 |
+
# Use tini for proper signal handling
|
39 |
+
ENTRYPOINT ["/sbin/tini", "--"]
|
40 |
+
|
41 |
+
# Start the application
|
42 |
+
CMD ["npm", "start"]
|
README.md
CHANGED
@@ -1,40 +1,10 @@
|
|
1 |
-
|
2 |
-
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
-
|
11 |
-
```
|
12 |
-
|
13 |
-
## Deployment
|
14 |
-
|
15 |
-
First, build your app for production:
|
16 |
-
|
17 |
-
```sh
|
18 |
-
npm run build
|
19 |
-
```
|
20 |
-
|
21 |
-
Then run the app in production mode:
|
22 |
-
|
23 |
-
```sh
|
24 |
-
npm start
|
25 |
-
```
|
26 |
-
|
27 |
-
Now you'll need to pick a host to deploy it to.
|
28 |
-
|
29 |
-
### DIY
|
30 |
-
|
31 |
-
If you're familiar with deploying Node applications, the built-in Remix app server is production-ready.
|
32 |
-
|
33 |
-
Make sure to deploy the output of `npm run build`
|
34 |
-
|
35 |
-
- `build/server`
|
36 |
-
- `build/client`
|
37 |
-
|
38 |
-
## Styling
|
39 |
-
|
40 |
-
This template comes with [Tailwind CSS](https://tailwindcss.com/) already configured for a simple default starting experience. You can use whatever css framework you prefer. See the [Vite docs on css](https://vitejs.dev/guide/features.html#css) for more information.
|
|
|
1 |
+
---
|
2 |
+
title: HugeX Connector Explore
|
3 |
+
emoji: π
|
4 |
+
colorFrom: blue
|
5 |
+
colorTo: purple
|
6 |
+
sdk: docker
|
7 |
+
pinned: false
|
8 |
+
license: mit
|
9 |
+
app_port: 3000
|
10 |
+
---
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|