1 Star 0 Fork 3

chengym/alertmanager-webhook

加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
文件
克隆/下载
.gitlab-ci.yml 1.28 KB
一键复制 编辑 原始数据 按行查看 历史
Neo Chan 提交于 2021-09-02 16:49 . 修改JDK版本
cache:
untracked: true
stages:
- build
- test
- deploy
build-job:
image: maven:3.8.2-openjdk-17
stage: build
tags:
- docker
script:
- mvn clean package -Dmaven.test.skip=true
- ls target/*.jar
artifacts:
name: "$CI_PROJECT_NAME"
paths:
- target/*.jar
test-job:
image: maven:3.8.2-openjdk-17
stage: test
variables:
GIT_STRATEGY: none
tags:
- docker
script:
- mvn test
deploy-job:
stage: deploy
variables:
GIT_STRATEGY: none
HOST: 192.168.30.14
environment:
name: development
url: https://api.netkiller.cn
only:
- development
tags:
- shell
before_script:
# - DOCKER_HOST=unix:///var/run/docker.sock mvn clean install docker:build
- mvn docker:build -DpushImage
# - mvn docker:push
- rm -rf *.sql.gz
- mysqldump -hmysql.netkiller.cn test | gzip > test.$(date -u +%Y-%m-%d.%H:%M:%S).sql.gz
artifacts:
name: "$CI_PROJECT_NAME"
paths:
- ./*.sql.gz
script:
- scp src/main/docker/docker-compose.yaml www@$HOST:/opt/netkiller.cn/api.netkiller.cn/
- ssh www@$HOST "sudo docker-compose -f /opt/netkiller.cn/api.netkiller.cn/docker-compose.yaml up"
- ssh www@$HOST "sudo docker-compose -f /opt/netkiller.cn/api.netkiller.cn/docker-compose.yaml restart"
Loading...
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
Java
1
https://gitee.com/inspurming/alertmanager-webhook.git
[email protected]:inspurming/alertmanager-webhook.git
inspurming
alertmanager-webhook
alertmanager-webhook
master

搜索帮助