Skip to content

Commit

Permalink
ci: add build workflow #10
Browse files Browse the repository at this point in the history
  • Loading branch information
gbuskey committed Nov 17, 2023
1 parent ada1dfa commit 7365e7f
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 2 deletions.
49 changes: 49 additions & 0 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,49 @@
name: CI

on:
pull_request:
branches:
- main
push:
branches:
- main

jobs:
test:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '>=1.21'
- run: make test

lint:
runs-on: ubuntu-latest

permissions:
contents: read

steps:
- uses: actions/checkout@v4
- uses: actions/setup-go@v4
with:
go-version: '>=1.21'
cache: false
env:
GO111MODULE: off

- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: v1.54

- run: make megalint

build-image:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4
- run: make docker-image
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,6 @@ RUN make clean && make linux

FROM scratch

COPY --from=builder /build/bin/server /usr/local/bin/server
COPY --from=builder /build/bin/epr-server /usr/local/bin/epr-server

CMD /usr/local/bin/server
CMD /usr/local/bin/epr-server

0 comments on commit 7365e7f

Please sign in to comment.