Skip to content

Commit

Permalink
add docker release ci and proxy service
Browse files Browse the repository at this point in the history
  • Loading branch information
cokemine committed Jan 19, 2023
1 parent 34a198f commit e40d517
Show file tree
Hide file tree
Showing 2 changed files with 52 additions and 0 deletions.
39 changes: 39 additions & 0 deletions .github/workflows/docker.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,39 @@
name: Docker Release Staging

on:
push:
branches-ignore:
- "renovate/**"
workflow_dispatch:

jobs:
release:
runs-on: ubuntu-latest
steps:
- name: Login to DockerHub
uses: docker/login-action@v2
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Checkout
uses: actions/checkout@v3
with:
submodules: recursive

- name: Set up QEMU
uses: docker/setup-qemu-action@v2

- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v2

- name: Build dockerfile
working-directory: ./frontend
env:
DOCKER_USERNAME: ${{ secrets.DOCKER_USERNAME }}
run: |
docker buildx build \
--platform=linux/amd64,linux/arm64 \
--output "type=image,push=true" \
--file ./Dockerfile . \
--tag $(echo "${DOCKER_USERNAME}" | tr '[:upper:]' '[:lower:]')/bird-lg-go:latest
13 changes: 13 additions & 0 deletions service/bird-lg-proxy.service
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[Unit]
Description=Bird-lg-proxy
Documentation=https://github.com/xddxdd/bird-lg-go
After=network.target

[Service]
EnvironmentFile=/usr/local/bird-lg/config.conf
ExecStart=/usr/local/bird-lg/proxy
ExecReload=/bin/kill -HUP $MAINPID
Restart=on-failure

[Install]
WantedBy=multi-user.target

0 comments on commit e40d517

Please sign in to comment.