@kithinji/pod 1.0.18 → 1.0.19

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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kithinji/pod",
3
- "version": "1.0.18",
3
+ "version": "1.0.19",
4
4
  "description": "",
5
5
  "bin": {
6
6
  "pod": "./dist/main.js"
@@ -101,6 +101,7 @@ async function restructureProject(cwd: string, projectName: string) {
101
101
 
102
102
  async function createDockerfile(cwd: string, projectName: string) {
103
103
  const dockerfilePath = path.join(cwd, projectName, "Dockerfile");
104
+ const dockerignorePath = path.join(cwd, projectName, ".dockerignore");
104
105
 
105
106
  const dockerfile = `FROM node:18-alpine
106
107
 
@@ -115,9 +116,69 @@ COPY . .
115
116
  EXPOSE 8080
116
117
 
117
118
  CMD ["npm", "run", "dev"]
119
+ `;
120
+
121
+ const dockerignore = `# Dependencies
122
+ node_modules
123
+ npm-debug.log
124
+ yarn-error.log
125
+ package-lock.json
126
+ yarn.lock
127
+
128
+ # Environment files
129
+ .env
130
+ .env.*
131
+
132
+ # Git
133
+ .git
134
+ .gitignore
135
+
136
+ # IDE
137
+ .vscode
138
+ .idea
139
+ *.swp
140
+ *.swo
141
+ *~
142
+
143
+ # OS
144
+ .DS_Store
145
+ Thumbs.db
146
+
147
+ # Testing
148
+ coverage
149
+ .nyc_output
150
+ *.test.js
151
+ *.spec.js
152
+ __tests__
153
+
154
+ # Build files
155
+ dist
156
+ build
157
+ .next
158
+ .nuxt
159
+
160
+ # Logs
161
+ logs
162
+ *.log
163
+
164
+ # Documentation
165
+ README.md
166
+ docs
167
+ *.md
168
+
169
+ # Docker
170
+ Dockerfile
171
+ .dockerignore
172
+ docker-compose*.yml
173
+
174
+ # Misc
175
+ .cache
176
+ tmp
177
+ temp
118
178
  `;
119
179
 
120
180
  await fs.writeFile(dockerfilePath, dockerfile);
181
+ await fs.writeFile(dockerignorePath, dockerignore);
121
182
  }
122
183
 
123
184
  async function setupProduction(
package/src/main.ts CHANGED
@@ -28,7 +28,7 @@ import { dockerize } from "./docker";
28
28
 
29
29
  const program = new Command();
30
30
 
31
- program.name("pod").description("Pod cli tool").version("1.0.18");
31
+ program.name("pod").description("Pod cli tool").version("1.0.19");
32
32
 
33
33
  program
34
34
  .command("new <name>")