-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #16 from woogles-io/housekeeping
Housekeeping
- Loading branch information
Showing
9 changed files
with
195 additions
and
113 deletions.
There are no files selected for viewing
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,62 @@ | ||
name: Build and Deploy | ||
|
||
on: | ||
push: | ||
branches: | ||
- "*" | ||
|
||
permissions: | ||
packages: write | ||
|
||
jobs: | ||
build_socket: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Setup Go | ||
uses: actions/setup-go@v5 | ||
with: | ||
go-version: ">=1.22" | ||
|
||
- name: Build | ||
run: cd cmd/socketsrv && go build | ||
|
||
deploy_socket_docker: | ||
runs-on: ubuntu-latest | ||
if: ${{ github.ref == 'refs/heads/master' }} | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
|
||
- name: Log in to the container registry | ||
uses: docker/login-action@v3 | ||
with: | ||
registry: ghcr.io | ||
username: domino14 | ||
password: ${{ secrets.GITHUB_TOKEN }} | ||
|
||
- name: Build and Tag Docker Image | ||
run: > | ||
docker build --build-arg BUILD_HASH=${GITHUB_SHA} | ||
--build-arg BUILD_DATE=$(date -Iseconds -u) | ||
-t ghcr.io/woogles-io/liwords-socket:${GITHUB_REF_NAME}-gh${GITHUB_RUN_NUMBER} | ||
- name: Push Docker Image to registry | ||
run: docker push ghcr.io/woogles-io/liwords-socket:${GITHUB_REF_NAME}-gh${GITHUB_RUN_NUMBER} | ||
|
||
- name: Discord notification | ||
env: | ||
DISCORD_WEBHOOK: ${{ secrets.DISCORD_WEBHOOK }} | ||
DISCORD_EMBEDS: '[ { | ||
"fields": [ | ||
{ "name": "Repository", "value": "[${{github.event.repository.name}}](${{github.event.repository.clone_url}})", "inline": true }, | ||
{ "name": "Branch", "value": "[${{github.ref_name}}](https://github.com/${{github.repository}}/tree/${{github.ref_name}})", "inline": true }, | ||
{ "name": "Tag", "value": "ghcr.io/woogles-io/liwords-socket:${{github.ref_name}}-gh${{github.run_number}}"} | ||
], | ||
"color":1127128 | ||
} ]' | ||
uses: Ilshidur/action-discord@master | ||
with: | ||
args: "" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
FROM golang:alpine as build-env | ||
FROM golang:alpine AS build-env | ||
|
||
RUN mkdir /opt/program | ||
WORKDIR /opt/program | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
# liwords-socket | ||
The websocket server for liwords | ||
|
||
See the README at https://github.com/domino14/liwords for more info about how this works. | ||
See the README at https://github.com/woogles-io/liwords for more info about how this works. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,33 +1,48 @@ | ||
module github.com/domino14/liwords-socket | ||
module github.com/woogles-io/liwords-socket | ||
|
||
go 1.21 | ||
|
||
toolchain go1.21.3 | ||
go 1.23.0 | ||
|
||
require ( | ||
github.com/dgrijalva/jwt-go v3.2.0+incompatible | ||
github.com/domino14/liwords v0.1.3 | ||
github.com/gorilla/websocket v1.5.0 | ||
github.com/golang-jwt/jwt/v5 v5.2.1 | ||
github.com/gorilla/websocket v1.5.3 | ||
github.com/namsral/flag v1.7.4-pre | ||
github.com/nats-io/nats.go v1.31.0 | ||
github.com/rs/zerolog v1.31.0 | ||
google.golang.org/protobuf v1.31.0 | ||
github.com/nats-io/nats.go v1.37.0 | ||
github.com/rs/zerolog v1.33.0 | ||
github.com/woogles-io/liwords v0.2.1 | ||
google.golang.org/protobuf v1.34.2 | ||
) | ||
|
||
require ( | ||
github.com/aead/chacha20 v0.0.0-20180709150244-8b13a72661da // indirect | ||
github.com/domino14/macondo v0.8.6 // indirect | ||
github.com/google/uuid v1.4.0 // indirect | ||
github.com/klauspost/compress v1.17.2 // indirect | ||
github.com/lithammer/shortuuid v3.0.0+incompatible // indirect | ||
github.com/domino14/macondo v0.9.8 // indirect | ||
github.com/domino14/word-golib v0.2.0 // indirect | ||
github.com/fsnotify/fsnotify v1.7.0 // indirect | ||
github.com/google/uuid v1.6.0 // indirect | ||
github.com/hashicorp/hcl v1.0.0 // indirect | ||
github.com/klauspost/compress v1.17.9 // indirect | ||
github.com/lithammer/shortuuid/v4 v4.0.0 // indirect | ||
github.com/magiconair/properties v1.8.7 // indirect | ||
github.com/mattn/go-colorable v0.1.13 // indirect | ||
github.com/mattn/go-isatty v0.0.20 // indirect | ||
github.com/nats-io/nkeys v0.4.6 // indirect | ||
github.com/mitchellh/mapstructure v1.5.0 // indirect | ||
github.com/nats-io/nkeys v0.4.7 // indirect | ||
github.com/nats-io/nuid v1.0.1 // indirect | ||
github.com/samber/lo v1.38.1 // indirect | ||
github.com/twitchtv/twirp v8.1.3+incompatible // indirect | ||
golang.org/x/crypto v0.14.0 // indirect | ||
golang.org/x/exp v0.0.0-20231006140011-7918f672742d // indirect | ||
golang.org/x/sys v0.13.0 // indirect | ||
github.com/pelletier/go-toml/v2 v2.2.3 // indirect | ||
github.com/sagikazarmark/locafero v0.6.0 // indirect | ||
github.com/sagikazarmark/slog-shim v0.1.0 // indirect | ||
github.com/samber/lo v1.47.0 // indirect | ||
github.com/sourcegraph/conc v0.3.0 // indirect | ||
github.com/spf13/afero v1.11.0 // indirect | ||
github.com/spf13/cast v1.7.0 // indirect | ||
github.com/spf13/pflag v1.0.5 // indirect | ||
github.com/spf13/viper v1.19.0 // indirect | ||
github.com/subosito/gotenv v1.6.0 // indirect | ||
go.uber.org/multierr v1.11.0 // indirect | ||
golang.org/x/crypto v0.26.0 // indirect | ||
golang.org/x/exp v0.0.0-20240823005443-9b4947da3948 // indirect | ||
golang.org/x/sys v0.24.0 // indirect | ||
golang.org/x/text v0.17.0 // indirect | ||
gopkg.in/ini.v1 v1.67.0 // indirect | ||
gopkg.in/yaml.v3 v3.0.1 // indirect | ||
lukechampine.com/frand v1.4.2 // indirect | ||
) |
Oops, something went wrong.