Skip to content

Commit

Permalink
docs: add openim cluster helm chart (#1291)
Browse files Browse the repository at this point in the history
* docs: add openim cluster helm chart

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* docs: add openim scripts deployment system

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* docs: add all openim helm chart deployment

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* docs: add all openim helm chart deployment

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim install scripts docs

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim kubernetes deployment

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim kubernetes deployment

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim kubernetes deployment

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim kubernetes deployment

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* fix: openim images version

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* fix: make image

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim helm charts

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim helm charts

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

* feat: add openim config docs

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>

---------

Signed-off-by: Xinwei Xiong(cubxxw) <3293172751nss@gmail.com>
  • Loading branch information
cubxxw committed Oct 30, 2023
1 parent 726f14f commit a4b28c9
Show file tree
Hide file tree
Showing 184 changed files with 5,657 additions and 1,647 deletions.
9 changes: 8 additions & 1 deletion .env
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,19 @@ MINIO_ENDPOINT=http://172.28.0.1:10005

# Base URL for the application programming interface (API).
# Default: API_URL=http://172.28.0.1:10002
API_URL=http://127.0.0.1:10002
API_URL=http://172.28.0.1:10002

# Directory path for storing data files or related information.
# Default: DATA_DIR=./
DATA_DIR=./

# Choose the appropriate image address, the default is GITHUB image,
# you can choose docker hub, for Chinese users can choose Ali Cloud
# export IMAGE_REGISTRY="ghcr.io/openimsdk"
# export IMAGE_REGISTRY="openim"
# export IMAGE_REGISTRY="registry.cn-hangzhou.aliyuncs.com/openimsdk"
IMAGE_REGISTRY=ghcr.io/openimsdk

# ======================================
# ========= Network Configuration ======
# ======================================
Expand Down
79 changes: 65 additions & 14 deletions .github/workflows/docker-buildx.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,6 +54,19 @@ jobs:
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}

- name: Log in to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}

- name: Log in to AliYun Docker Hub
uses: docker/login-action@v3
with:
registry: registry.cn-hangzhou.aliyuncs.com
username: ${{ secrets.ALIREGISTRY_USERNAME }}
password: ${{ secrets.ALIREGISTRY_TOKEN }}

################################################
# build/
# └── docker
Expand Down Expand Up @@ -89,7 +102,10 @@ jobs:
id: meta1
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-api
images: |
ghcr.io/openimsdk/openim-api
openim/openim-api
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-api
- name: Build and push Docker image for openim-api
uses: docker/build-push-action@v5
Expand All @@ -107,7 +123,10 @@ jobs:
id: meta2
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-cmdutils
images: |
ghcr.io/openimsdk/openim-cmdutils
openim/openim-cmdutils
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-cmdutils
- name: Build and push Docker image for openim-cmdutils
uses: docker/build-push-action@v5
Expand All @@ -125,7 +144,10 @@ jobs:
id: meta3
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-crontask
images: |
ghcr.io/openimsdk/openim-crontask
openim/openim-crontask
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-crontask
- name: Build and push Docker image for openim-crontask
uses: docker/build-push-action@v5
Expand All @@ -143,7 +165,10 @@ jobs:
id: meta4
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-msggateway
images: |
ghcr.io/openimsdk/openim-msggateway
openim/openim-msggateway
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-msggateway
- name: Build and push Docker image for openim-msggateway
uses: docker/build-push-action@v5
Expand All @@ -161,7 +186,10 @@ jobs:
id: meta5
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-msgtransfer
images: |
ghcr.io/openimsdk/openim-msgtransfer
openim/openim-msgtransfer
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-msgtransfer
- name: Build and push Docker image for openim-msgtransfer
uses: docker/build-push-action@v5
Expand All @@ -179,7 +207,10 @@ jobs:
id: meta6
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-push
images: |
ghcr.io/openimsdk/openim-push
openim/openim-push
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-push
- name: Build and push Docker image for openim-push
uses: docker/build-push-action@v5
Expand All @@ -197,7 +228,10 @@ jobs:
id: meta7
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-auth
images: |
ghcr.io/openimsdk/openim-rpc-auth
openim/openim-rpc-auth
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-auth
- name: Build and push Docker image for openim-rpc-auth
uses: docker/build-push-action@v5
Expand All @@ -215,7 +249,10 @@ jobs:
id: meta8
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-conversation
images: |
ghcr.io/openimsdk/openim-rpc-conversation
openim/openim-rpc-conversation
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-conversation
- name: Build and push Docker image for openim-rpc-conversation
uses: docker/build-push-action@v5
Expand All @@ -233,7 +270,10 @@ jobs:
id: meta9
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-friend
images: |
ghcr.io/openimsdk/openim-rpc-friend
openim/openim-rpc-friend
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-friend
- name: Build and push Docker image for openim-rpc-friend
uses: docker/build-push-action@v5
Expand All @@ -251,7 +291,10 @@ jobs:
id: meta10
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-group
images: |
ghcr.io/openimsdk/openim-rpc-group
openim/openim-rpc-group
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-group
- name: Build and push Docker image for openim-rpc-group
uses: docker/build-push-action@v5
Expand All @@ -269,7 +312,10 @@ jobs:
id: meta11
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-msg
images: |
ghcr.io/openimsdk/openim-rpc-msg
openim/openim-rpc-msg
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-msg
- name: Build and push Docker image for openim-rpc-msg
uses: docker/build-push-action@v5
Expand All @@ -287,7 +333,10 @@ jobs:
id: meta12
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-third
images: |
ghcr.io/openimsdk/openim-rpc-third
openim/openim-rpc-third
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-third
- name: Build and push Docker image for openim-rpc-third
uses: docker/build-push-action@v5
Expand All @@ -305,7 +354,10 @@ jobs:
id: meta13
uses: docker/metadata-action@v5.0.0
with:
images: ghcr.io/openimsdk/openim-rpc-user
images: |
ghcr.io/openimsdk/openim-rpc-user
openim/openim-rpc-user
registry.cn-hangzhou.aliyuncs.com/openimsdk/openim-rpc-user
- name: Build and push Docker image for openim-rpc-user
uses: docker/build-push-action@v5
Expand All @@ -318,4 +370,3 @@ jobs:
labels: ${{ steps.meta13.outputs.labels }}
cache-from: type=local,src=/tmp/.buildx-cache
cache-to: type=local,dest=/tmp/.buildx-cache

21 changes: 21 additions & 0 deletions .github/workflows/openimci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -170,3 +170,24 @@ jobs:
- name: Print OpenIM Logs
run: sudo cat ./_output/logs/* 2>/dev/null
continue-on-error: true

openim-build-image:
name: Build OpenIM Docker Image
runs-on: ubuntu-latest
environment:
name: openim
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Go ${{ matrix.go_version }}
uses: actions/setup-go@v4
with:
go-version: ${{ matrix.go_version }}
id: go
- name: Install Task
uses: arduino/setup-task@v1
with:
version: 2.x
- name: Test Docker Build
run: |
sudo make image
14 changes: 2 additions & 12 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ tmp/
bin/
output/
_output/
deployments/charts/generated-configs/

### OpenIM Config ###
config/config.yaml
Expand All @@ -37,18 +38,7 @@ config/config.yaml
./.env

### OpenIM deploy ###
deploy/openim_demo
deploy/openim-api
deploy/openim-rpc-msg_gateway
deploy/openim-msgtransfer
deploy/openim-push
deploy/openim_timer_task
deploy/openim-rpc-user
deploy/openim-rpc-friend
deploy/openim-rpc-group
deploy/openim-rpc-msg
deploy/openim-rpc-auth
deploy/Open-IM-SDK-Core
deployments/openim-server/charts

# files used by the developer
.idea.md
Expand Down
89 changes: 12 additions & 77 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -715,83 +715,18 @@ linters:
# enable-all: true
disable-all: true
enable:
- typecheck
- asciicheck
- bodyclose
- cyclop
# - depguard
- dogsled
- dupl
- durationcheck
- errcheck
- errorlint
- exhaustive
- exportloopref
# - forbidigo
- funlen
# - gci
# - gochecknoinits
- gocognit
- goconst
- gocyclo
- godot
- godox
- gofmt
- gofumpt
- goheader
- goimports
- gomoddirectives
- gomodguard
- goprintffuncname
- gosec
- gosimple
- govet
- importas
- ineffassign
- lll
- makezero
- misspell
- nakedret
- nestif
- nilerr
- nlreturn
- noctx
- nolintlint
- paralleltest
- prealloc
- predeclared
- promlinter
- revive
- rowserrcheck
- sqlclosecheck
- staticcheck
- stylecheck
- thelper
- tparallel
- unconvert
- unparam
- unused
- wastedassign
- whitespace
- bidichk
- wastedassign
- execinquery
- nosprintfhostport
- grouper
- decorder
- errchkjson
- maintidx
#- containedctx
#- tagliatelle
#- nonamedreturns
#- nilnil
#- tenv
#- varnamelen
#- contextcheck
#- errname
#- ForceTypeAssert
#- nilassign
fast: false
- typecheck # 基本的类型检查
- gofmt # 格式检查
- govet # Go 语言的标准检查工具
- gosimple # 简化代码的建议
- misspell # 拼写错误
- staticcheck # 静态检查
- unused # 未使用的代码检查
- goimports # 检查导入是否正确排序和格式化
- godot # 注释句点检查
- bodyclose # 确保 HTTP response body 被关闭
- errcheck # 检查是否遗漏了错误返回值
fast: true

issues:
# List of regexps of issue texts to exclude, empty list by default.
Expand Down
8 changes: 4 additions & 4 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -73,9 +73,9 @@ gen:
demo:
@$(MAKE) go.demo

## versionchecker: Check version of openim. ✨
.PHONY: versionchecker
versionchecker:
## version: Check version of openim. ✨
.PHONY: version
version:
@$(MAKE) go.versionchecker

## build: Build binaries by default ✨
Expand All @@ -95,7 +95,7 @@ stop:

## restart: Restart openim ✨
.PHONY: restart
restart: clean stop build init start
restart: clean stop build init start check

## multiarch: Build binaries for multiple platforms. See option PLATFORMS. ✨
.PHONY: multiarch
Expand Down
4 changes: 2 additions & 2 deletions README-zh_CN.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p align="center">
<a href="https://www.openim.online">
<a href="https://openim.io">
<img src="./assets/logo-gif/openim-logo.gif" width="60%" height="30%"/>
</a>
</p>
Expand All @@ -23,7 +23,7 @@
<p align="center">
<a href="./README.md"><b> English </b></a> •
<a href="./README-zh_CN.md"><b> 简体中文 </b></a> •
<a href="https://www.openim.online/en"><b> Docs </b></a>
<a href="https://openim.io/en"><b> Docs </b></a>
</p>


Expand Down
Loading

0 comments on commit a4b28c9

Please sign in to comment.