Lock TechDocs generation to specific container version.

Signed-off-by: Eric Peterson <ericpeterson@spotify.com>
This commit is contained in:
Eric Peterson
2021-09-29 15:42:36 +02:00
parent cbc0a83184
commit e92f0f728b
3 changed files with 13 additions and 3 deletions
+6
View File
@@ -0,0 +1,6 @@
---
'@backstage/techdocs-common': patch
---
Locks the version of the default docker image used to generate TechDocs. As of
this changelog entry, it is v0.3.2!
+1
View File
@@ -256,6 +256,7 @@ export class TechdocsGenerator implements GeneratorBase {
config: Config;
scmIntegrations: ScmIntegrationRegistry;
});
static readonly defaultDockerImage = 'spotify/techdocs:v0.3.2';
// (undocumented)
static fromConfig(
config: Config,
@@ -37,9 +37,11 @@ import {
GeneratorRunOptions,
} from './types';
const defaultDockerImage = 'spotify/techdocs';
export class TechdocsGenerator implements GeneratorBase {
/**
* The default docker image used to generate cnotent.
*/
public static readonly defaultDockerImage = 'spotify/techdocs:v0.3.2';
private readonly logger: Logger;
private readonly containerRunner: ContainerRunner;
private readonly options: GeneratorConfig;
@@ -124,7 +126,8 @@ export class TechdocsGenerator implements GeneratorBase {
break;
case 'docker':
await this.containerRunner.runContainer({
imageName: this.options.dockerImage ?? defaultDockerImage,
imageName:
this.options.dockerImage ?? TechdocsGenerator.defaultDockerImage,
args: ['build', '-d', '/output'],
logStream,
mountDirs,