deploy-stack 0.9.4 → 0.9.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/src/utils/generator.js
CHANGED
|
@@ -69,6 +69,24 @@ export async function generateTemplates(targetDir, config) {
|
|
|
69
69
|
await fs.appendFile(targetGitignore, appendIgnore);
|
|
70
70
|
}
|
|
71
71
|
}
|
|
72
|
+
|
|
73
|
+
// 6. Create .dockerignore to keep images lean and secure
|
|
74
|
+
const dockerignorePath = path.join(targetDir, '.dockerignore');
|
|
75
|
+
if (!fsSync.existsSync(dockerignorePath)) {
|
|
76
|
+
const dockerignoreContent = `
|
|
77
|
+
.git/
|
|
78
|
+
.github/
|
|
79
|
+
terraform/
|
|
80
|
+
.env
|
|
81
|
+
README.md
|
|
82
|
+
node_modules/
|
|
83
|
+
npm-debug.log
|
|
84
|
+
__pycache__/
|
|
85
|
+
*.pyc
|
|
86
|
+
.DS_Store
|
|
87
|
+
`.trim();
|
|
88
|
+
await fs.writeFile(dockerignorePath, dockerignoreContent);
|
|
89
|
+
}
|
|
72
90
|
}
|
|
73
91
|
|
|
74
92
|
function getGitignoreContent(framework) {
|
|
@@ -10,7 +10,7 @@ RUN groupadd -g 1001 appgroup && \
|
|
|
10
10
|
COPY requirements.txt .
|
|
11
11
|
|
|
12
12
|
# Patch core python packaging tools to resolve CVEs
|
|
13
|
-
RUN pip install --upgrade pip setuptools wheel jaraco.context
|
|
13
|
+
RUN pip install --upgrade pip setuptools wheel jaraco.context msgpack
|
|
14
14
|
RUN pip install --no-cache-dir -r requirements.txt gunicorn
|
|
15
15
|
|
|
16
16
|
# Copy code with explicit ownership
|