Skip to content

Commit

Permalink
fix: Huge test
Browse files Browse the repository at this point in the history
  • Loading branch information
Randsw committed Oct 31, 2023
1 parent 166dc0c commit 25ea6b2
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 2 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -19,8 +19,6 @@ jobs:
fetch-depth: 0
- name: Configure git to trust the workspace despite the different owner
run: git config --global --add safe.directory $(realpath .)
- name: Test
run: git describe --abbrev=0 --tags --always
- name: Docker meta
id: meta
uses: docker/metadata-action@v5
Expand All @@ -41,6 +39,8 @@ jobs:
registry: ghcr.io
username: ${{ github.actor }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Test
run: ls -lah
- name: Build image and push to GitHub Container Registry
uses: docker/build-push-action@v5
with:
Expand Down
5 changes: 5 additions & 0 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,11 @@ RUN go mod download

COPY . .

RUN ls -lah

RUN make test

RUN make pwd
# Build
RUN make build

Expand Down
4 changes: 4 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ TAG := $(shell git describe --abbrev=0 --tags --always)
HASH := $(shell git rev-parse HEAD)
DATE := $(shell date +%Y-%m-%d.%H:%M:%S)
PWD := $(shell pwd)
LIST := $(shell ls -lah)

LDFLAGS := -w -X github.com/randsw/kubeinfo/handlers.hash=$(HASH) \
-X github.com/randsw/kubeinfo/handlers.tag=$(TAG) \
Expand All @@ -18,4 +19,7 @@ build: setup_git
CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go build -ldflags "$(LDFLAGS)" -a -o kubeinfo main.go

test:
echo ${LIST}

pwd:
echo ${PWD}

0 comments on commit 25ea6b2

Please sign in to comment.