start centralizing environment gathering
This commit is contained in:
@ -1,6 +1,7 @@
|
||||
import "typings-global";
|
||||
import * as plugins from "./npmci.plugins";
|
||||
import {bash} from "./npmci.bash";
|
||||
import * as env from "./npmci.env";
|
||||
|
||||
export let build = function(commandArg){
|
||||
switch(commandArg){
|
||||
@ -15,9 +16,7 @@ export let build = function(commandArg){
|
||||
|
||||
let docker = function(){
|
||||
let done = plugins.q.defer();
|
||||
let repo = new plugins.smartstring.GitRepo(process.env.CI_BUILD_REPO);
|
||||
let dockerTag;
|
||||
plugins.shelljs.exec("docker build -t " + "registry.gitlab.com/" + repo.user + "/" + repo.repo + ":latest .");
|
||||
plugins.shelljs.exec("docker build -t " + "registry.gitlab.com/" + env.repo.user + "/" + env.repo.repo + ":latest .");
|
||||
done.resolve();
|
||||
return done.promise;
|
||||
}
|
||||
@ -25,8 +24,7 @@ let docker = function(){
|
||||
let dockerGitlab = function(){
|
||||
let done = plugins.q.defer();
|
||||
let repo = new plugins.smartstring.GitRepo(process.env.CI_BUILD_REPO);
|
||||
let dockerTag;
|
||||
plugins.shelljs.exec("docker build -t " + "registry.gitlab.com/" + repo.user + "/" + repo.repo + ":latest .");
|
||||
plugins.shelljs.exec("docker build -t " + "registry.gitlab.com/" + env.repo.user + "/" + env.repo.repo + ":latest .");
|
||||
done.resolve();
|
||||
return done.promise;
|
||||
}
|
@ -1,3 +1,8 @@
|
||||
export let env = function(){
|
||||
|
||||
};
|
||||
import "typings-global";
|
||||
import * as plugins from "./npmci.plugins";
|
||||
|
||||
import {GitRepo} from "smartstring";
|
||||
|
||||
export let repo = new GitRepo(process.env.CI_BUILD_REPO);
|
||||
export let dockerTestTag:string;
|
||||
export let dockerReleaseTag:string;
|
||||
|
Reference in New Issue
Block a user