Skip to content

Commit

Permalink
Merge branch 'master' of github.com:gucio321/tic-tac-go
Browse files Browse the repository at this point in the history
  • Loading branch information
gucio321 committed Nov 16, 2022
2 parents 103a80d + 3d5c9c8 commit a2aa854
Show file tree
Hide file tree
Showing 3 changed files with 28 additions and 3 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/golangci-lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ jobs:
go-version: '1.18.x'
- uses: actions/checkout@v3
- name: golangci-lint
uses: golangci/[email protected].0
uses: golangci/[email protected].1
with:
# Optional: version of golangci-lint to use in form of v1.2 or v1.2.3 or `latest` to use the latest version
version: v1.45.0
Expand Down
17 changes: 15 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,9 +1,22 @@
FROM golang:latest
FROM docker.io/library/golang:1.19.3-buster

RUN apt-get update

# install dependencies required to run giu application
RUN apt-get install -y libgtk-3-dev libasound2-dev libxxf86vm-dev

# set workidr
WORKDIR /app

# move all the stuff into working directory
ADD . /app

# go-get pakcages (I recommend using go's vendoring-mode since it makes modules downloading super-fast
# as they are in fact already downloaded and stored by previous command)
RUN go get -d ./...

CMD go run github.com/gucio321/tic-tac-go/cmd/terminal-game
# pre-build binaries to make running them faster
RUN go build github.com/gucio321/tic-tac-go/cmd/giu-game

# define command to run
CMD go run github.com/gucio321/tic-tac-go/cmd/giu-game
12 changes: 12 additions & 0 deletions docker-compose.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
version: "3"

services:
app:
build: .
environment:
- DISPLAY=${DISPLAY}
volumes:
- /tmp/.X11-unix:/tmp/.X11-unix
security_opt:
- label:type:container_runtime_t
network_mode: bridge

0 comments on commit a2aa854

Please sign in to comment.