Skip to content

Commit

Permalink
feat: 同时将镜像推送到国内阿里仓库,解决镜像下载问题 (opsre#225)
Browse files Browse the repository at this point in the history
  • Loading branch information
eryajf authored Jun 21, 2023
1 parent 24bfdb5 commit 3a70895
Show file tree
Hide file tree
Showing 3 changed files with 24 additions and 8 deletions.
20 changes: 19 additions & 1 deletion .github/workflows/docker-image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -63,4 +63,22 @@ jobs:
# 给清单打上多个标签
tags: |
${{ secrets.DOCKERHUB_USERNAME }}/go-ldap-admin-server:latest
${{ secrets.DOCKERHUB_USERNAME }}/go-ldap-admin-server:${{ steps.date.outputs.today }}
${{ secrets.DOCKERHUB_USERNAME }}/go-ldap-admin-server:${{ steps.date.outputs.today }}
# 镜像推送到 阿里云仓库
- name: Login to the Ali Registry
uses: docker/login-action@v2
with:
registry: registry.cn-hangzhou.aliyuncs.com
username: ${{ secrets.ALIHUB_USERNAME }}
password: ${{ secrets.ALIHUB_TOKEN }}

- name: Build and push to Ali
uses: docker/build-push-action@v3
with:
context: .
push: true
platforms: linux/amd64,linux/arm64
tags: |
registry.cn-hangzhou.aliyuncs.com/${{ secrets.ALIHUB_USERNAME }}/go-ldap-admin-server:${{ env.GITHUB_REF_NAME }}
registry.cn-hangzhou.aliyuncs.com/${{ secrets.ALIHUB_USERNAME }}/go-ldap-admin-server:latest
2 changes: 0 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,6 @@
[![HitCount](https://views.whatilearened.today/views/github/eryajf/go-ldap-admin.svg)](https://github.com/eryajf/go-ldap-admin)
[![GitHub license](https://img.shields.io/github/license/eryajf/go-ldap-admin)](https://github.com/eryajf/go-ldap-admin/blob/main/LICENSE)
[![Commits](https://img.shields.io/github/commit-activity/m/eryajf/go-ldap-admin?color=ffff00)](https://github.com/eryajf/go-ldap-admin/commits/main)
[![pre-commit](https://img.shields.io/badge/pre--commit-enabled-brightgreen?logo=pre-commit)](https://github.com/pre-commit/pre-commit)


<p> 🌉 基于Go+Vue实现的openLDAP后台管理项目 🌉</p>

Expand Down
10 changes: 5 additions & 5 deletions docs/docker-compose/docker-compose.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ networks:

services:
mysql:
image: dockerproxy.com/mysql/mysql-server:5.7
image: registry.cn-hangzhou.aliyuncs.com/ali_eryajf/mysql-server:5.7
container_name: go-ldap-admin-mysql # 指定容器名称,如果不设置此参数,则由系统自动生成
hostname: go-ldap-admin-mysql
restart: always # 设置容器自启模式
Expand All @@ -27,7 +27,7 @@ services:
- go-ldap-admin

openldap:
image: dockerproxy.com/osixia/openldap:1.4.0
image: registry.cn-hangzhou.aliyuncs.com/ali_eryajf/openldap:1.4.0
container_name: go-ldap-admin-openldap
hostname: go-ldap-admin-openldap
restart: always
Expand All @@ -47,7 +47,7 @@ services:
- go-ldap-admin

phpldapadmin:
image: dockerproxy.com/osixia/phpldapadmin:0.9.0
image: registry.cn-hangzhou.aliyuncs.com/ali_eryajf/phpldapadmin:0.9.0
container_name: go-ldap-admin-phpldapadmin
hostname: go-ldap-admin-phpldapadmin
restart: always
Expand All @@ -67,7 +67,7 @@ services:
- go-ldap-admin

go-ldap-admin-server:
image: dockerproxy.com/eryajf/go-ldap-admin-server
image: registry.cn-hangzhou.aliyuncs.com/ali_eryajf/go-ldap-admin-server
container_name: go-ldap-admin-server
hostname: go-ldap-admin-server
restart: always
Expand All @@ -88,7 +88,7 @@ services:
- go-ldap-admin

go-ldap-admin-ui:
image: dockerproxy.com/eryajf/go-ldap-admin-ui
image: registry.cn-hangzhou.aliyuncs.com/ali_eryajf/go-ldap-admin-ui
container_name: go-ldap-admin-ui
hostname: go-ldap-admin-ui
restart: always
Expand Down

0 comments on commit 3a70895

Please sign in to comment.