Skip to content

Commit

Permalink
ready
Browse files Browse the repository at this point in the history
  • Loading branch information
masipcat committed Mar 6, 2024
1 parent a72c33d commit 1f35750
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 9 deletions.
14 changes: 6 additions & 8 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,19 +18,17 @@ jobs:
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3

# - name: Login to Docker Hub
# uses: docker/login-action@v3
# with:
# username: ${{ secrets.DOCKERHUB_USERNAME }}
# password: ${{ secrets.DOCKERHUB_TOKEN }}
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKERHUB_USERNAME }}
password: ${{ secrets.DOCKERHUB_TOKEN }}

- name: Build and push
run: |
export VERSION=$(cat Dockerfile | grep 'wg_go_tag=' | grep -Eo '[0-9]+\.[0-9]+\.[0-9]+')
docker buildx create \
--name container \
--driver=docker-container
make buildx_container
TAG=$VERSION make build_and_push
TAG=latest make build_and_push
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
@@ -1,7 +1,12 @@
.PHONY: build_and_push
.PHONY: builx_container build_and_push

DOCKER_REGISTRY ?= masipcat/wireguard-go

builx_container:
docker buildx create \
--name container \
--driver=docker-container

build_and_push:
docker buildx build \
--tag ${DOCKER_REGISTRY}:${TAG} \
Expand Down

0 comments on commit 1f35750

Please sign in to comment.