Skip to content

Commit 2ff1c85

Browse files
authored
Merge branch 'apache:main' into fix-bootstrap
2 parents a765ded + 0835702 commit 2ff1c85

File tree

3 files changed

+42
-10
lines changed

3 files changed

+42
-10
lines changed

.github/workflows/build.yml

Lines changed: 39 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,39 @@
1+
# Licensed to the Apache Software Foundation (ASF) under one
2+
# or more contributor license agreements. See the NOTICE file
3+
# distributed with this work for additional information
4+
# regarding copyright ownership. The ASF licenses this file
5+
# to you under the Apache License, Version 2.0 (the
6+
# "License"); you may not use this file except in compliance
7+
# with the License. You may obtain a copy of the License at
8+
#
9+
# http://www.apache.org/licenses/LICENSE-2.0
10+
#
11+
# Unless required by applicable law or agreed to in writing,
12+
# software distributed under the License is distributed on an
13+
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
14+
# KIND, either express or implied. See the License for the
15+
# specific language governing permissions and limitations
16+
# under the License.
17+
18+
name: Test-Build
19+
20+
on: [push, pull_request]
21+
22+
concurrency:
23+
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
24+
cancel-in-progress: true
25+
26+
jobs:
27+
build:
28+
runs-on: ubuntu-22.04
29+
30+
steps:
31+
- uses: actions/checkout@v3
32+
33+
- name: Set up Go
34+
uses: actions/setup-go@v3
35+
with:
36+
go-version: 1.13
37+
- name: Run Script
38+
run: make test
39+

.travis.yml

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

cloudstack_loadbalancer.go

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ import (
2828
"github.com/xanzy/go-cloudstack/v2/cloudstack"
2929
"k8s.io/klog"
3030

31-
"k8s.io/api/core/v1"
31+
v1 "k8s.io/api/core/v1"
3232
cloudprovider "k8s.io/cloud-provider"
3333
)
3434

@@ -332,7 +332,7 @@ func (cs *CSCloud) getLoadBalancer(service *v1.Service) (*loadBalancer, error) {
332332
func (cs *CSCloud) verifyHosts(nodes []*v1.Node) ([]string, string, error) {
333333
hostNames := map[string]bool{}
334334
for _, node := range nodes {
335-
hostNames[node.Name] = true
335+
hostNames[strings.ToLower(node.Name)] = true
336336
}
337337

338338
p := cs.client.VirtualMachine.NewListVirtualMachinesParams()
@@ -352,7 +352,7 @@ func (cs *CSCloud) verifyHosts(nodes []*v1.Node) ([]string, string, error) {
352352

353353
// Check if the virtual machine is in the hosts slice, then add the corresponding ID.
354354
for _, vm := range l.VirtualMachines {
355-
if hostNames[vm.Name] {
355+
if hostNames[strings.ToLower(vm.Name)] {
356356
if networkID != "" && networkID != vm.Nic[0].Networkid {
357357
return nil, "", fmt.Errorf("found hosts that belong to different networks")
358358
}

0 commit comments

Comments
 (0)