How do I get my cloud run to deploy every time I p...
# getting-started
How do I get my cloud run to deploy every time I push up a new image? Right now I am using the imageName but it doesn't deploy a new revision unless I change something else within the cloud run service. Here is what mine looks like currently.
Copy code
service, err := cloudrun.NewService(ctx, appName, &cloudrun.ServiceArgs{
			Location: pulumi.String(region),
			Project:  pulumi.String(projectID),
			Name:     pulumi.String(appName),
			Template: &cloudrun.ServiceTemplateArgs{
				Spec: &cloudrun.ServiceTemplateSpecArgs{
					Containers: cloudrun.ServiceTemplateSpecContainerArray{
							Image: appImage.ImageName,
							Ports: cloudrun.ServiceTemplateSpecContainerPortArray{
									Name:          pulumi.String("http1"),
									ContainerPort: <http://pulumi.Int|pulumi.Int>(8080),
							Resources: &cloudrun.ServiceTemplateSpecContainerResourcesArgs{
								Limits: pulumi.StringMap(map[string]pulumi.StringInput{
									"cpu":    pulumi.String("1"),
									"memory": pulumi.String("512Mi"),
					ContainerConcurrency: <http://pulumi.Int|pulumi.Int>(5),
			Traffics: cloudrun.ServiceTrafficArray{
					Percent:        <http://pulumi.Int|pulumi.Int>(100),
					LatestRevision: pulumi.Bool(true),
		}, pulumi.DependsOn([]pulumi.Resource{appImage}))
		if err != nil {
			return err
Use the image hash instead of the name. What's
in your example?
Copy code
appImage, err := docker.NewImage(ctx, appName, &docker.ImageArgs{
			ImageName: pulumi.Sprintf("", region, projectID, appName),
			Build: &docker.DockerBuildArgs{
				Context:    pulumi.String("./"),
				Dockerfile: pulumi.String("./Dockerfile"),
				Platform:   pulumi.String("linux/amd64"),
How do I get the image hash from here?
I think that worked. Thanks Anthony!