fix undefined error for docker registry

This commit is contained in:
Philipp Kunz 2016-06-26 05:21:24 +02:00
parent a2a7544797
commit ab6b447d55
2 changed files with 5 additions and 3 deletions

5
dist/npmci.env.js vendored
View File

@ -9,12 +9,13 @@ exports.buildStage = process.env.CI_BUILD_STAGE;
exports.dockerFilesBuilt = []; exports.dockerFilesBuilt = [];
exports.dockerFiles = []; exports.dockerFiles = [];
exports.config = { exports.config = {
dockerRegistry: exports.dockerRegistry, dockerRegistry: undefined,
dockerFilesBuilt: exports.dockerFilesBuilt, dockerFilesBuilt: exports.dockerFilesBuilt,
dockerFiles: exports.dockerFiles, dockerFiles: exports.dockerFiles,
project: undefined project: undefined
}; };
exports.configStore = function () { exports.configStore = function () {
exports.config.dockerRegistry = exports.dockerRegistry;
plugins.smartfile.memory.toFsSync(JSON.stringify(exports.config), paths.NpmciPackageConfig); plugins.smartfile.memory.toFsSync(JSON.stringify(exports.config), paths.NpmciPackageConfig);
}; };
var configLoad = function () { var configLoad = function () {
@ -43,4 +44,4 @@ var configLoad = function () {
}; };
configLoad(); configLoad();
//# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIm5wbWNpLmVudi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsUUFBTyxnQkFBZ0IsQ0FBQyxDQUFBO0FBQ3hCLElBQVksT0FBTyxXQUFNLGlCQUFpQixDQUFDLENBQUE7QUFDM0MsSUFBWSxLQUFLLFdBQU0sZUFBZSxDQUFDLENBQUE7QUFDdkMsNEJBQXNCLGFBQWEsQ0FBQyxDQUFBO0FBSXBDLEVBQUUsQ0FBQSxDQUFDLE9BQU8sQ0FBQyxHQUFHLENBQUMsYUFBYSxDQUFDO0lBQUMsWUFBSSxHQUFHLElBQUkscUJBQU8sQ0FBQyxPQUFPLENBQUMsR0FBRyxDQUFDLGFBQWEsQ0FBQyxDQUFDO0FBRWpFLGtCQUFVLEdBQVUsT0FBTyxDQUFDL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dGhzLk5wbWNpUGFja2FnZUNvbmZpZyxcImpzb25cIikpO1xuICAgIH1cbiAgICBjYXRjaChlcnIpe1xuICAgICAgICBjb25maWdTdG9yZSgpO1xuICAgICAgICBwbHVnaW5zLmJlYXV0eWxvZy5sb2coXCJjb25maWcgaW5pdGlhbGl6ZWQhXCIpO1xuICAgIH1cblxuICAgIC8vIHByb2plY3QgY29uZmlnXG4gICAgdHJ5IHtcbiAgICAgICAgaWYoIWNvbmZpZy5wcm9qZWN0KXtcbiAgICAgICAgICAgIGNvbmZpZy5wcm9qZWN0ID0gcGx1Z2lucy5zbWFydGZpbGUuZnMudG9PYmplY3RTeW5jKHBhdGhzLk5wbWNpUHJvamVjdERpcixcIm5wbWNpLmpzb25cIik7XG4gICAgICAgICAgICBwbHVnaW5zLmJlYXV0eWxvZy5vayhcInByb2plY3QgY29uZmlnIGZvdW5kIVwiKTtcbiAgICAgICAgfTtcbiAgICB9XG4gICAgY2F0Y2goZXJyKXtcbiAgICAgICAgY29uZmlnLnByb2plY3QgPSB7fTtcbiAgICAgICAgcGx1Z2lucy5iZWF1dHlsb2cubG9nKFwibm8gcHJvamVjdCBjb25maWcgZm91bmQsIHNvIHByb2NlZWRpbmcgd2l0aCBkZWZhdWx0IGJlaGF2aW91ciFcIik7XG4gICAgfVxuICAgIFxuICAgIGNvbmZpZy5kb2NrZXJSZWdpc3RyeSA/IGRvY2tlclJlZ2lzdHJ5ID0gY29uZmlnLmRvY2tlclJlZ2lzdHJ5IDogdm9pZCgwKTtcbiAgICBjb25maWcuZG9ja2VyRmlsZXNCdWlsdCA/IGRvY2tlckZpbGVzQnVpbHQgPSBjb25maWcuZG9ja2VyRmlsZXNCdWlsdCA6IHZvaWQoMCk7XG59XG5jb25maWdMb2FkKCk7Il19 //# sourceMappingURL=data:application/json;charset=utf8;base64,eyJ2ZXJzaW9uIjozLCJzb3VyY2VzIjpbIm5wbWNpLmVudi50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FB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nLnByb2plY3QgPSB7fTtcbiAgICAgICAgcGx1Z2lucy5iZWF1dHlsb2cubG9nKFwibm8gcHJvamVjdCBjb25maWcgZm91bmQsIHNvIHByb2NlZWRpbmcgd2l0aCBkZWZhdWx0IGJlaGF2aW91ciFcIik7XG4gICAgfVxuICAgIFxuICAgIGNvbmZpZy5kb2NrZXJSZWdpc3RyeSA/IGRvY2tlclJlZ2lzdHJ5ID0gY29uZmlnLmRvY2tlclJlZ2lzdHJ5IDogdm9pZCgwKTtcbiAgICBjb25maWcuZG9ja2VyRmlsZXNCdWlsdCA/IGRvY2tlckZpbGVzQnVpbHQgPSBjb25maWcuZG9ja2VyRmlsZXNCdWlsdCA6IHZvaWQoMCk7XG59XG5jb25maWdMb2FkKCk7Il19

View File

@ -14,13 +14,14 @@ export let dockerRegistry; // will be set by npmci.prepare
export let dockerFilesBuilt:Dockerfile[] = []; export let dockerFilesBuilt:Dockerfile[] = [];
export let dockerFiles:Dockerfile[] = []; export let dockerFiles:Dockerfile[] = [];
export let config = { export let config = {
dockerRegistry: dockerRegistry, dockerRegistry: undefined, // this will be set later on store
dockerFilesBuilt: dockerFilesBuilt, dockerFilesBuilt: dockerFilesBuilt,
dockerFiles: dockerFiles, dockerFiles: dockerFiles,
project: undefined project: undefined
}; };
export let configStore = () => { export let configStore = () => {
config.dockerRegistry = dockerRegistry;
plugins.smartfile.memory.toFsSync( plugins.smartfile.memory.toFsSync(
JSON.stringify(config), JSON.stringify(config),
paths.NpmciPackageConfig paths.NpmciPackageConfig