Skip to content

Commit 2bb1fd9

Browse files
authored
fix: Move acncli to hack and update error message (#748)
* fix: update acncli error message * fix: acncnli move to hack
1 parent 2e2efa7 commit 2bb1fd9

File tree

14 files changed

+28
-18
lines changed

14 files changed

+28
-18
lines changed

Makefile

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -80,7 +80,7 @@ CNI_NET_DIR = cni/network/plugin
8080
CNI_IPAM_DIR = cni/ipam/plugin
8181
CNI_IPAMV6_DIR = cni/ipam/pluginv6
8282
CNI_TELEMETRY_DIR = cni/telemetry/service
83-
ACNCLI_DIR = acncli
83+
ACNCLI_DIR = hack/acncli
8484
TELEMETRY_CONF_DIR = telemetry
8585
CNS_DIR = cns/service
8686
CNMS_DIR = cnms/service
@@ -171,9 +171,9 @@ azure-npm: $(NPM_BUILD_DIR)/azure-npm$(EXE_EXT) npm-archive
171171
endif
172172

173173
ifeq ($(GOOS),linux)
174-
all-binaries: acncli azure-cnm-plugin azure-cni-plugin azure-cns azure-cnms azure-npm
174+
all-binaries: azure-cnm-plugin azure-cni-plugin azure-cns azure-cnms azure-npm
175175
else
176-
all-binaries: acncli azure-cnm-plugin azure-cni-plugin azure-cns acncli
176+
all-binaries: azure-cnm-plugin azure-cni-plugin azure-cns
177177
endif
178178

179179
ifeq ($(GOOS),linux)
@@ -252,11 +252,13 @@ all-binaries-platforms:
252252
export GOOS=linux; make all-binaries
253253
export GOOS=windows; make all-binaries
254254

255-
# CNI Manager
256-
.PHONY: azure-cni-manager
257-
azure-cni-manager: all-binaries
258-
docker build -f ./acncli/Dockerfile --build-arg VERSION=$(VERSION) -t $(AZURE_CNI_IMAGE):$(VERSION) .
259255

256+
.PHONY: hack
257+
hack: acncli
258+
259+
.PHONY: hack-images
260+
hack-images:
261+
docker build -f ./hack/acncli/Dockerfile --build-arg VERSION=$(VERSION) -t $(AZURE_CNI_IMAGE):$(VERSION) .
260262

261263
# Build the Azure CNM plugin image, installable with "docker plugin install".
262264
.PHONY: azure-vnet-plugin-image
@@ -397,10 +399,12 @@ cnm-archive:
397399
# Create a CNM archive for the target platform.
398400
.PHONY: acncli-archive
399401
acncli-archive:
402+
ifeq ($(GOOS),linux)
400403
mkdir -p $(ACNCLI_BUILD_DIR)
401404
chmod 0755 $(ACNCLI_BUILD_DIR)/acn$(EXE_EXT)
402405
cd $(ACNCLI_BUILD_DIR) && $(ARCHIVE_CMD) $(ACNCLI_ARCHIVE_NAME) acn$(EXE_EXT)
403406
chown $(BUILD_USER):$(BUILD_USER) $(ACNCLI_BUILD_DIR)/$(ACNCLI_ARCHIVE_NAME)
407+
endif
404408

405409

406410
# Create a CNS archive for the target platform.

hack/README.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
# NOTICE:
2+
3+
## **Tools in this directory are provided as is with no SLA, and not for production use.** They are purely experiments or hackathon projects that have no home.
4+
5+
### Thanks,
6+
### Azure Container Networking Dev Team
File renamed without changes.
File renamed without changes.
File renamed without changes.

acncli/cmd/install.go renamed to hack/acncli/cmd/install.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ import (
44
"fmt"
55
"strings"
66

7-
c "github.com/Azure/azure-container-networking/acncli/api"
8-
i "github.com/Azure/azure-container-networking/acncli/installer"
7+
c "github.com/Azure/azure-container-networking/hack/acncli/api"
8+
i "github.com/Azure/azure-container-networking/hack/acncli/installer"
99
"github.com/spf13/cobra"
1010
"github.com/spf13/viper"
1111
)

acncli/cmd/logs.go renamed to hack/acncli/cmd/logs.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package cmd
33
import (
44
"fmt"
55

6-
c "github.com/Azure/azure-container-networking/acncli/api"
6+
c "github.com/Azure/azure-container-networking/hack/acncli/api"
77
"github.com/nxadm/tail"
88
"github.com/spf13/cobra"
99
"github.com/spf13/viper"
File renamed without changes.

acncli/cmd/root.go renamed to hack/acncli/cmd/root.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ package cmd
33
import (
44
"fmt"
55

6-
c "github.com/Azure/azure-container-networking/acncli/api"
6+
c "github.com/Azure/azure-container-networking/hack/acncli/api"
77
"github.com/spf13/cobra"
88
"github.com/spf13/viper"
99
)
File renamed without changes.

0 commit comments

Comments
 (0)