https://pulumi.com logo
Title
d

dazzling-sundown-39670

04/19/2021, 6:27 PM
Trying to build a docker image and I'm getting this error:
Error: No 'docker' command available on PATH:
. I do have
docker
in my path so I'm not sure what it's complaining about
m

millions-furniture-75402

04/19/2021, 6:42 PM
how are you trying to build a docker image?
d

dazzling-sundown-39670

04/19/2021, 6:48 PM
@millions-furniture-75402 this is my code:
import * as awsx from '@pulumi/awsx';
import * as docker from '@pulumi/docker';

const buildOptions: docker.DockerBuild = {
  context: '..',
  cacheFrom: true,
};

export const repository = new awsx.ecr.Repository('microservices', {
  lifeCyclePolicyArgs: {
    rules: [
      {
        description: 'Keep 10 latest images',
        maximumNumberOfImages: 10,
        selection: 'any',
      },
    ],
  },
});

export const image = repository.buildAndPushImage(buildOptions);
Used it many times before so I'm not sure what's wrong
m

millions-furniture-75402

04/19/2021, 6:49 PM
Are you using the same version of
@pulumi/docker
?
d

dazzling-sundown-39670

04/19/2021, 6:55 PM
@millions-furniture-75402 I was using version 3.0 in this project which was much newer so I downgraded to 2.10 now but I'm seeing the same error
m

millions-furniture-75402

04/19/2021, 6:55 PM
Have you tried all the same dependencies of another project that works, and a new terminal? Same issue?
Have you ensured a working project still works?
d

dazzling-sundown-39670

04/19/2021, 8:05 PM
I don't really run the others locally but I can try
No it's the same problem 🤔
I wonder why
Could it be that updated the pulumi cli?
Downgraded to 2.25.2 but no luck
Restarted my whole computer and it worked 😛