Skip to content
Closed
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Dockerfile
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
ARG BASE
ARG BASE=eclipse-temurin:17-jdk-jammy
FROM ${BASE}

ENV IN_DOCKER=1
Expand Down
5 changes: 3 additions & 2 deletions deploy/docker/docker-compose.yml
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
# Use for running an Appsmith, during development.
# docker-compose.yml - Graviton-Compatible Setup

version: "3"

services:
appsmith:
image: index.docker.io/appsmith/appsmith-ce:release
image: appsmith/appsmith-ce:graviton # ✅ Use the ARM64-compatible image tag
Comment thread
coderabbitai[bot] marked this conversation as resolved.
Outdated
container_name: appsmith
ports:
- "8080:80"
Expand All @@ -13,3 +13,4 @@ services:
APPSMITH_ENCRYPTION_SALT: abcd
volumes:
- ./stacks:/appsmith-stacks

115 changes: 115 additions & 0 deletions deploy/docker/fs/opt/bin/index.js

Large diffs are not rendered by default.

37 changes: 37 additions & 0 deletions deploy/docker/fs/opt/bin/restore-from-s3.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
#!/usr/bin/env node

const { execSync } = require("child_process");
const path = require("path");
const fs = require("fs");
const os = require("os"); // 👈 for cross-platform temp path

(async () => {
const args = process.argv.slice(2);
const s3Url = args[0];

if (!s3Url || !s3Url.startsWith("s3://")) {
console.error("❌ Please provide a valid S3 URL");
process.exit(1);
}

console.log(`🧪 [FAKE MODE] Pretending to download from S3: ${s3Url}`);

// Cross-platform safe temp file path
const localFile = path.join(os.tmpdir(), "backup.tar.gz");

try {
// Simulate backup download
fs.writeFileSync(localFile, "fake backup content");

// Simulate restore call
console.log(`🧪 [FAKE MODE] Calling: node index.js restore ${localFile}`);
execSync(`echo Simulated mongorestore --gzip --archive=${localFile}`, {
stdio: "inherit"
});

console.log("✅ Fake restore completed successfully.");
} catch (err) {
console.error("❌ Restore simulation failed:", err);
process.exit(1);
}
})();