dokku-compose 0.6.5 → 0.6.6

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.
Files changed (2) hide show
  1. package/dist/index.js +8 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -162,6 +162,9 @@ function createRunner(opts = {}) {
162
162
  },
163
163
  async query(...args) {
164
164
  const { stdout } = await execDokku(args);
165
+ if (process.env.DOKKU_COMPOSE_DEBUG && args[0]?.includes("builder-dockerfile")) {
166
+ console.error(`[debug] query ${args.join(" ")} => ${stdout.length} bytes`);
167
+ }
165
168
  return stdout.trim();
166
169
  },
167
170
  async check(...args) {
@@ -187,9 +190,13 @@ function createContext(runner) {
187
190
  runner,
188
191
  query(...args) {
189
192
  const key = args.join("\0");
190
- if (!cache.has(key)) {
193
+ const cached = cache.has(key);
194
+ if (!cached) {
191
195
  cache.set(key, runner.query(...args));
192
196
  }
197
+ if (process.env.DOKKU_COMPOSE_DEBUG && args[0]?.includes("builder-dockerfile")) {
198
+ console.error(`[debug] ctx.query(${args.join(" ")}) cached=${cached}`);
199
+ }
193
200
  return cache.get(key);
194
201
  },
195
202
  check(...args) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "dokku-compose",
3
- "version": "0.6.5",
3
+ "version": "0.6.6",
4
4
  "description": "Docker Compose for Dokku — declare your entire server in a single YAML file.",
5
5
  "main": "dist/index.js",
6
6
  "exports": "./dist/index.js",