-
Notifications
You must be signed in to change notification settings - Fork 119
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
7 changed files
with
124 additions
and
7 deletions.
There are no files selected for viewing
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,30 @@ | ||
name: goreleaser | ||
on: | ||
# Trigger the workflow on push or pull request, | ||
# but only if a semver tag is created. | ||
push: | ||
tags: | ||
- v*.*.* | ||
jobs: | ||
goreleaser: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- | ||
name: Checkout | ||
uses: actions/checkout@v1 | ||
- | ||
name: Set up Go | ||
uses: actions/setup-go@v1 | ||
with: | ||
go-version: 1.14.x | ||
- | ||
name: Login to DockerHub Registry | ||
run: echo ${{ secrets.DOCKER_PASSWORD }} | docker login -u ${{ secrets.DOCKER_USERNAME }} --password-stdin | ||
- | ||
name: Run goreleaser | ||
uses: goreleaser/goreleaser-action@v1 | ||
with: | ||
version: latest | ||
args: release --rm-dist --skip-validate | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |
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,39 @@ | ||
env: | ||
- GO111MODULE=on | ||
- CGO_ENABLED=0 | ||
- RELEASE_BUILDS=dist/niltalk_darwin_amd64/niltalk dist/niltalk_linux_amd64/niltalk dist/niltalk_windows_amd64/niltalk.exe | ||
|
||
builds: | ||
- binary: niltalk | ||
goos: | ||
- linux | ||
- darwin | ||
- windows | ||
goarch: | ||
- amd64 | ||
ldflags: | ||
- -s -w -X "main.buildString={{ .Tag }} ({{ .ShortCommit }} {{ .Date }})" | ||
hooks: | ||
# stuff binaries with static assets. | ||
post: make pack-releases | ||
|
||
archives: | ||
- format: tar.gz | ||
files: | ||
- README.md | ||
- LICENSE | ||
|
||
dockers: | ||
- | ||
goos: linux | ||
goarch: amd64 | ||
goarm: '' | ||
binaries: | ||
- niltalk | ||
image_templates: | ||
- "kailashnadh/niltalk:latest" | ||
- "kailashnadh/niltalk:{{ .Tag }}" | ||
skip_push: false | ||
dockerfile: Dockerfile | ||
extra_files: | ||
- config.toml.sample |
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,5 @@ | ||
FROM alpine:latest AS deploy | ||
WORKDIR /niltalk | ||
COPY niltalk . | ||
COPY config.toml.sample config.toml | ||
ENTRYPOINT [ "./niltalk" ] |
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
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 |
---|---|---|
@@ -0,0 +1,30 @@ | ||
# NOTE: This docker-compose.yml is meant to be just an example guideline | ||
# on how you can achieve the same. It is not intented to run out of the box | ||
# and you must edit the below configurations to suit your needs. | ||
|
||
version: "3.7" | ||
|
||
services: | ||
redis: | ||
image: redis:alpine | ||
networks: | ||
- niltalk | ||
volumes: | ||
- niltalk-data | ||
restart: unless-stopped | ||
|
||
niltalk: | ||
image: kailashnadh/niltalk:latest | ||
ports: | ||
- "9000:9000" | ||
networks: | ||
- niltalk | ||
depends_on: | ||
- redis | ||
restart: unless-stopped | ||
|
||
networks: | ||
niltalk: | ||
|
||
volumes: | ||
niltalk-data: |