Skip to content

Commit

Permalink
Conditionally include the build link as an environment variable only …
Browse files Browse the repository at this point in the history
…if it is available.
  • Loading branch information
tizzo committed Oct 13, 2016
1 parent efbbac6 commit d055021
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/Container.js
Original file line number Diff line number Diff line change
Expand Up @@ -190,13 +190,15 @@ Container.prototype.create = Promise.promisify(function(done) {
Env: [
`COMMIT_REF=${this.build.commit.ref}`,
`BUILD_ID=${this.build.id}`,
`BUILD_DOMAIN=${this.build.links.build}`,
`SRC_DIR=${SRC_DIR}`,
`ASSET_DIR=${ASSET_DIR}`,
`PWD=${SRC_DIR}`,
`PROBO_ENVIRONMENT=TRUE`,
],
};
if (this.build.links && this.build.links.build) {
createOptions.Env.push(`BUILD_DOMAIN=${this.build.links.build}`);
}
var startOptions = {
PortBindings: commandInfo.portBindings,
Binds: self.binds,
Expand Down

0 comments on commit d055021

Please sign in to comment.