Skip to content

Commit

Permalink
feat: samba
Browse files Browse the repository at this point in the history
  • Loading branch information
snowdream committed Jun 7, 2024
1 parent 4a3ee78 commit 8ae2845
Show file tree
Hide file tree
Showing 5 changed files with 69 additions and 73 deletions.
2 changes: 1 addition & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ Dockerfile
build.sh
README.md
LICENSE
.github
.github
104 changes: 49 additions & 55 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,61 +3,55 @@ name: CI Main
on:
push:
branches:
- main
- main
tags:
- '*'
- "*"
workflow_dispatch:
jobs:
buildx:
runs-on: ubuntu-latest
steps:
-
name: Checkout
uses: actions/[email protected]
with:
# [Required] Access token with `workflow` scope.
token: ${{ secrets.WORKFLOW_SECRET }}
-
name: Run GitHub Actions Version Updater
uses: saadmk11/[email protected]
with:
# [Required] Access token with `workflow` scope.
token: ${{ secrets.WORKFLOW_SECRET }}
-
# Add support for more platforms with QEMU (optional)
# https://github.com/docker/setup-qemu-action
name: Set up QEMU
uses: docker/setup-qemu-action@v3
-
name: Set up Docker Buildx
uses: docker/[email protected]
-
name: Login to DockerHub
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_PASSWORD }}
-
name: Login to GitHub Container Registry
uses: docker/[email protected]
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
-
name: Build and push
uses: docker/[email protected]
with:
context: .
platforms: linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/riscv64,linux/s390x
push: true
tags: |
snowdreamtech/alpine:latest
snowdreamtech/alpine:3.20.0
snowdreamtech/alpine:3.20
snowdreamtech/alpine:3
ghcr.io/snowdreamtech/alpine:latest
ghcr.io/snowdreamtech/alpine:3.20.0
ghcr.io/snowdreamtech/alpine:3.20
ghcr.io/snowdreamtech/alpine:3
buildx:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/[email protected]
with:
# [Required] Access token with `workflow` scope.
token: ${{ secrets.WORKFLOW_SECRET }}
- name: Run GitHub Actions Version Updater
uses: saadmk11/[email protected]
with:
# [Required] Access token with `workflow` scope.
token: ${{ secrets.WORKFLOW_SECRET }}
- # Add support for more platforms with QEMU (optional)
# https://github.com/docker/setup-qemu-action
name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Set up Docker Buildx
uses: docker/[email protected]
- name: Login to DockerHub
uses: docker/[email protected]
with:
username: ${{ secrets.DOCKER_HUB_USERNAME }}
password: ${{ secrets.DOCKER_HUB_PASSWORD }}
- name: Login to GitHub Container Registry
uses: docker/[email protected]
with:
registry: ghcr.io
username: ${{ github.repository_owner }}
password: ${{ secrets.GITHUB_TOKEN }}
- name: Build and push
uses: docker/[email protected]
with:
context: .
platforms: linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/riscv64,linux/s390x
push: true
tags: |
snowdreamtech/samba:latest
snowdreamtech/samba:4.19.6-r0
snowdreamtech/samba:4.19.6
snowdreamtech/samba:4.19
snowdreamtech/samba:4.19
ghcr.io/snowdreamtech/samba:latest
ghcr.io/snowdreamtech/samba:4.19.6-r0
ghcr.io/snowdreamtech/samba:4.19.6
ghcr.io/snowdreamtech/samba:4.19
ghcr.io/snowdreamtech/samba:4.19
4 changes: 2 additions & 2 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
FROM alpine:3.20.0
FROM snowdreamtech/alpine:3.20.0

LABEL maintainer="snowdream <[email protected]>"

RUN apk add --no-cache tzdata
RUN apk add --no-cache samba
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,24 +1,24 @@
# Alpine
# Samba

[![Alpine](http://dockeri.co/image/snowdreamtech/alpine)](https://hub.docker.com/r/snowdreamtech/alpine)
[![Samba](http://dockeri.co/image/snowdreamtech/samba)](https://hub.docker.com/r/snowdreamtech/samba)

Docker Image packaging for Alpine. (amd64, arm32v6, arm32v7, arm64v8, i386, ppc64le,riscv64, s390x)
Docker Image packaging for Samba. (amd64, arm32v6, arm32v7, arm64v8, i386, ppc64le,riscv64, s390x)

# Run

```bash
docker run --rm snowdreamtech/alpine:latest
docker run snowdreamtech/samba:latest
```

```bash
docker run -e TZ=Asia/Shanghai --rm snowdreamtech/alpine:latest
docker run -e TZ=Asia/Shanghai snowdreamtech/samba:latest
```

# Development

```bash
docker buildx create --use --name build --node build --driver-opt network=host
docker buildx build -t snowdreamtech/alpine --platform=linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/riscv64,linux/s390x . --push
docker buildx build -t snowdreamtech/samba --platform=linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/riscv64,linux/s390x . --push
```

## Reference
Expand All @@ -31,7 +31,7 @@ docker buildx build -t snowdreamtech/alpine --platform=linux/386,linux/amd64,lin
1. [Faster Multi-Platform Builds: Dockerfile Cross-Compilation Guide](https://www.docker.com/blog/faster-multi-platform-builds-dockerfile-cross-compilation-guide/)
1. [docker/buildx](https://github.com/docker/buildx)

## Contact (备注:alpine)
## Contact (备注:samba)

* Email: [email protected]
* QQ: 3217680847
Expand Down
18 changes: 10 additions & 8 deletions build.sh
Original file line number Diff line number Diff line change
@@ -1,17 +1,19 @@
#!/bin/sh

DOCKER_HUB_PROJECT=snowdreamtech/alpine
DOCKER_HUB_PROJECT=snowdreamtech/samba

GITHUB_PROJECT=ghcr.io/snowdreamtech/alpine
GITHUB_PROJECT=ghcr.io/snowdreamtech/samba

docker buildx build --platform=linux/386,linux/amd64,linux/arm/v6,linux/arm/v7,linux/arm64,linux/ppc64le,linux/riscv64,linux/s390x \
-t ${DOCKER_HUB_PROJECT}:latest \
-t ${DOCKER_HUB_PROJECT}:3.20.0 \
-t ${DOCKER_HUB_PROJECT}:3.20 \
-t ${DOCKER_HUB_PROJECT}:3 \
-t ${DOCKER_HUB_PROJECT}:4.19.6-r0 \
-t ${DOCKER_HUB_PROJECT}:4.19.6 \
-t ${DOCKER_HUB_PROJECT}:4.19 \
-t ${DOCKER_HUB_PROJECT}:4.19 \
-t ${GITHUB_PROJECT}:latest \
-t ${GITHUB_PROJECT}:3.20.0 \
-t ${GITHUB_PROJECT}:3.20 \
-t ${GITHUB_PROJECT}:3 \
-t ${GITHUB_PROJECT}:4.19.6-r0 \
-t ${GITHUB_PROJECT}:4.19.6 \
-t ${GITHUB_PROJECT}:4.19 \
-t ${GITHUB_PROJECT}:4.19 \
. \
--push

0 comments on commit 8ae2845

Please sign in to comment.