Skip to content

Commit

Permalink
squash pipeline fixing
Browse files Browse the repository at this point in the history
  • Loading branch information
YannikBramkamp committed Feb 22, 2021
1 parent 5576685 commit fda7a16
Show file tree
Hide file tree
Showing 8 changed files with 20 additions and 7 deletions.
5 changes: 4 additions & 1 deletion .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ jobs:
with:
go-version: 1.15

- name: Lint
run: make lintci

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
Expand All @@ -24,7 +27,7 @@ jobs:
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: release --rm-dist --snapshot --skip-publish -f build/ci/.goreleaser_root.yml
args: release --rm-dist --snapshot --skip-publish -f build/ci/.goreleaser_privileged.yml

test:
runs-on: ubuntu-20.04
Expand Down
4 changes: 4 additions & 0 deletions .github/workflows/release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,3 +17,7 @@ jobs:
- run: curl -sL https://git.io/goreleaser | bash -s -- --config build/ci/.goreleaser.yml --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_USER_TOKEN }}

- run: curl -sL https://git.io/goreleaser | bash -s -- --config build/ci/.goreleaser_privileged.yml --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.RELEASE_USER_TOKEN }}
4 changes: 2 additions & 2 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,15 @@ lintci:
docker run --rm \
-v $(CURDIR):/app \
-w /app \
-e GOLANGCI_ADDITIONAL_YML=/app/build/package/ci/.golangci.yml \
-e GOLANGCI_ADDITIONAL_YML=/app/build/ci/.golangci.yml \
quay.io/mittwald/golangci-lint:0.0.8 \
golangci-lint run -v --fix ./...

lint:
docker run --rm \
-v $(shell go env GOPATH):/go \
-v ${CURDIR}:/app -w /app \
-e GOLANGCI_ADDITIONAL_YML=/app/build/package/ci/.golangci.yml \
-e GOLANGCI_ADDITIONAL_YML=/app/build/ci/.golangci.yml \
quay.io/mittwald/golangci-lint:0.0.8 \
golangci-lint run -v --fix ./...

Expand Down
1 change: 1 addition & 0 deletions build/ci/.golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,6 @@
run:
skip-dirs:
- test/
- dist/
timeout: 10m

2 changes: 1 addition & 1 deletion build/ci/.goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
before:
hooks:
- go mod download
- make lintci

builds:
-
env:
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
before:
hooks:
- go mod download
- make lintci

builds:
-
env:
Expand Down Expand Up @@ -43,7 +43,7 @@ dockers:
- quay.io/mittwald/brudi_root:stable
binaries:
- brudi
dockerfile: build/docker/Dockerfile_root
dockerfile: build/docker/Dockerfile_privileged
goos: linux
goarch: amd64
goarm: ''
File renamed without changes.
7 changes: 6 additions & 1 deletion test/pkg/source/xfstest/xfs_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,9 @@ func (xfsTestSuite *XFSTestSuite) TestBasicXFSDump() {

err = os.Remove(dumpName)
xfsTestSuite.Require().NoError(err)

err = os.Remove(dirName)
xfsTestSuite.Require().NoError(err)
}

func (xfsTestSuite *XFSTestSuite) TestXFSDumpRestic() {
Expand All @@ -79,7 +82,7 @@ func (xfsTestSuite *XFSTestSuite) TestXFSDumpRestic() {

dirName := fmt.Sprintf("%s/testdir", mountPoint)

os.Mkdir(dirName, 744)
err = os.Mkdir(dirName, 744)
xfsTestSuite.Require().NoError(err)

err = source.DoBackupForKind(ctx, "xfsdump", false, true, false)
Expand All @@ -95,6 +98,8 @@ func (xfsTestSuite *XFSTestSuite) TestXFSDumpRestic() {
xfsTestSuite.Require().NoError(err)
err = os.Remove(dumpName)
xfsTestSuite.Require().NoError(err)
err = os.Remove(dirName)
xfsTestSuite.Require().NoError(err)
}

func TestXFSTestSuite(t *testing.T) {
Expand Down

0 comments on commit fda7a16

Please sign in to comment.