-
Notifications
You must be signed in to change notification settings - Fork 312
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[mainfest] add docker-compose deploy
- Loading branch information
Showing
9 changed files
with
1,346 additions
and
0 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,71 @@ | ||
name: build docker_compose | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
- 'feature-**' | ||
paths: | ||
- 'manifests/deepflow-docker-compose/**' | ||
tags: | ||
- '*' | ||
workflow_dispatch: | ||
inputs: | ||
ref: | ||
description: "Why trigger?" | ||
required: true | ||
type: string | ||
# release: | ||
# branches: | ||
# - main | ||
# - release-* | ||
|
||
jobs: | ||
build_docker_compose: | ||
name: build docker_compose | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
fetch-depth: 0 | ||
|
||
- uses: manyuanrong/[email protected] | ||
with: | ||
endpoint: "oss-accelerate.aliyuncs.com" | ||
access-key-id: "${{ secrets.ALIYUN_OSS_ACCESS_KEY }}" | ||
access-key-secret: "${{ secrets.ALIYUN_OSS_SECRETS_KEY }}" | ||
|
||
- name: set env | ||
run: | | ||
echo "IMAGE_TAG_PREFIX=${{ github.ref_name }}"|sed 's|=main$|=latest|' >> $GITHUB_ENV | ||
echo "IMAGE_TAG=$(git rev-list --count HEAD)" >> $GITHUB_ENV | ||
- name: upload docker-compose | ||
run: | | ||
cd manifests | ||
tar -czvf deepflow-docker-compose.tar deepflow-docker-compose | ||
ossutil cp -rf deepflow-docker-compose.tar oss://deepflow-ce/pkg/docker-compose/${{ env.IMAGE_TAG_PREFIX }}/linux/deepflow-docker-compose.tar | ||
- name: upload docker-compose stable artifacts | ||
if: "startsWith(github.ref, 'refs/tags/')" | ||
run: | | ||
cd manifests | ||
tar -czvf deepflow-docker-compose.tar deepflow-docker-compose | ||
ossutil cp -rf deepflow-docker-compose.tar oss://deepflow-ce/pkg/docker-compose/stable/linux/deepflow-docker-compose.tar | ||
# - name: Prepare for upload package | ||
# shell: bash | ||
# run: | | ||
# sha256sum dist/* > deepflow-agent.sha256sum.txt | ||
|
||
# - name: Release and upload packages | ||
# uses: softprops/action-gh-release@v1 | ||
# if: startsWith(github.ref, 'refs/tags/') | ||
# env: | ||
# GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
# with: | ||
# files: | | ||
# deepflow-agent.sha256sum.txt | ||
# dist/* |
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,16 @@ | ||
# DeepFlow STANDALONE mode docker-compose deployment package | ||
|
||
## Usage | ||
|
||
```console | ||
unset DOCKER_HOST_IP | ||
DOCKER_HOST_IP="10.1.2.3" # FIXME: Deploy the environment machine IP | ||
wget https://deepflow-ce.oss-cn-beijing.aliyuncs.com/pkg/docker-compose/stable/linux/deepflow-docker-compose.tar | ||
tar -zxf deepflow-docker-compose.tar | ||
sed -i "s|FIX_ME_ALLINONE_HOST_IP|$DOCKER_HOST_IP|g" deepflow-docker-compose/docker-compose.yaml | ||
docker-compose -f deepflow-docker-compose/docker-compose.yaml up -d | ||
``` | ||
|
||
## License | ||
|
||
[Apache 2.0 License](../../LICENSE). |
Oops, something went wrong.