Skip to content

Commit f05aa48

Browse files
author
helen
authored
Merge pull request #58 from jwcesign/main
feat: add ack node image list
2 parents 1506aec + e3ad041 commit f05aa48

File tree

4 files changed

+18
-21
lines changed

4 files changed

+18
-21
lines changed

config/config.go

Lines changed: 0 additions & 19 deletions
This file was deleted.

docs/nodeimage/README.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
# AlibabaCloud Images Used by AlibabaCloud ACK
2+
3+
Currently, we cannot directly query the relationship between image aliases and image IDs, so we will maintain this information in the `image.json` file.
4+
5+
You can find the corresponding images in the [official documentation](https://help.aliyun.com/zh/ack/ack-managed-and-ack-dedicated/user-guide/overview-of-os-images).

docs/nodeimage/image.json

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
{
2+
"ContainerOS": {
3+
"amd64": "lifsea_3_x64_10G_containerd_1_6_28_alibase_20240705.vhd",
4+
"arm64": ""
5+
},
6+
"AlibabaCloudLinux3": {
7+
"amd64": "aliyun_3_x64_20G_alibase_20240528.vhd",
8+
"arm64": "aliyun_3_arm64_20G_alibase_20240528.vhd"
9+
}
10+
}

pkg/cloudprovider/cloudprovider.go

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,6 @@ import (
4040
"sigs.k8s.io/karpenter/pkg/scheduling"
4141
"sigs.k8s.io/karpenter/pkg/utils/resources"
4242

43-
"github.com/cloudpilot-ai/karpenter-provider-alicloud/config"
4443
"github.com/cloudpilot-ai/karpenter-provider-alicloud/pkg/apis"
4544
"github.com/cloudpilot-ai/karpenter-provider-alicloud/pkg/apis/v1alpha1"
4645
cloudproviderevents "github.com/cloudpilot-ai/karpenter-provider-alicloud/pkg/cloudprovider/events"
@@ -49,6 +48,8 @@ import (
4948
"github.com/cloudpilot-ai/karpenter-provider-alicloud/pkg/utils"
5049
)
5150

51+
const CloudProviderName = "alibabacloud"
52+
5253
var _ cloudprovider.CloudProvider = (*CloudProvider)(nil)
5354

5455
type CloudProvider struct {
@@ -229,7 +230,7 @@ func (c *CloudProvider) IsDrifted(ctx context.Context, nodeClaim *karpv1.NodeCla
229230

230231
// Name returns the CloudProvider implementation name.
231232
func (c *CloudProvider) Name() string {
232-
return config.CloudName
233+
return CloudProviderName
233234
}
234235

235236
func (c *CloudProvider) GetSupportedNodeClasses() []status.Object {

0 commit comments

Comments
 (0)