Skip to content

Commit

Permalink
fix: create docker context for buildx to work with TLS (#312)
Browse files Browse the repository at this point in the history
  • Loading branch information
Jacob Wejendorp committed Jul 14, 2022
1 parent 35ce7c8 commit f123001
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 3 deletions.
5 changes: 4 additions & 1 deletion dist/index.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/index.js.map

Large diffs are not rendered by default.

6 changes: 5 additions & 1 deletion src/buildx.ts
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,17 @@ export async function stop(builderName: string): Promise<void> {
async function createBuilder(name: string): Promise<void> {
startGroup(`🔨 Creating a new builder instance`);

const context = 'builders';
await exec('docker', ['context', 'create', context]);

const args = [
'buildx',
'create',
'--name',
name,
'--driver',
'docker-container'
'docker-container',
context
];
await exec('docker', args);

Expand Down

0 comments on commit f123001

Please sign in to comment.