Compare commits
5 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 83332decd0 | |||
| 5a8356f8e1 | |||
| 3c0d37a439 | |||
| 77444bcdac | |||
| 1f6ce384f0 |
@@ -10,44 +10,47 @@ on:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
docker:
|
docker:
|
||||||
runs-on: ubuntu-latest
|
runs-on: test:docker://debian:bullseye
|
||||||
|
#runs-on: ubuntu-latest:docker://node:16-bullseye
|
||||||
|
#runs-on: ubuntu-latest:docker://debian:bullseye
|
||||||
steps:
|
steps:
|
||||||
|
|
||||||
- name: Print version and repository
|
- name: Print version and repository
|
||||||
run: echo "Runner working on repository ${{ gitea.repository }} and on tag ${{ GITHUB_REF_NAME }} ${{ gitea.ref_name }}"
|
run: echo "Runner working on repository ${{ gitea.repository }} and on tag ${{ gitea.ref_name }}"
|
||||||
- name: Print test
|
|
||||||
run: echo "ref_name is ${{ gitea.ref_name }}"
|
|
||||||
|
|
||||||
# - name: Install Docker engine
|
- name: Install Docker engine
|
||||||
# run: |
|
run: |
|
||||||
# apt-get update
|
apt-get update
|
||||||
# apt-get -y install curl dnsutils
|
apt-get -y install curl dnsutils
|
||||||
# install -m 0755 -d /etc/apt/keyrings
|
install -m 0755 -d /etc/apt/keyrings
|
||||||
# curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg
|
curl -fsSL https://download.docker.com/linux/debian/gpg | gpg --dearmor -o /etc/apt/keyrings/docker.gpg
|
||||||
# chmod a+r /etc/apt/keyrings/docker.gpg
|
chmod a+r /etc/apt/keyrings/docker.gpg
|
||||||
# echo "deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian "$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null
|
echo "deb [arch="$(dpkg --print-architecture)" signed-by=/etc/apt/keyrings/docker.gpg] https://download.docker.com/linux/debian "$(. /etc/os-release && echo "$VERSION_CODENAME")" stable" | tee /etc/apt/sources.list.d/docker.list > /dev/null
|
||||||
# apt-get update
|
apt-get update
|
||||||
# apt-get -y install docker-ce docker-ce-cli containerd.io docker-buildx-plugin
|
apt-get -y install docker-ce docker-ce-cli containerd.io docker-buildx-plugin
|
||||||
|
|
||||||
# - name: Git clone private repo
|
- name: Print docker images
|
||||||
# uses: actions/checkout@v4
|
run: docker images
|
||||||
# with:
|
|
||||||
# repository: staffadmin/gitea-runner
|
- name: Git clone private repo
|
||||||
|
uses: actions/checkout@v4
|
||||||
|
with:
|
||||||
|
repository: ${{ gitea.repository }}
|
||||||
# persist-credentials: false
|
# persist-credentials: false
|
||||||
# ssh-strict: false
|
# ssh-strict: false
|
||||||
# token: ${{ secrets.ACCESS_TOKEN_GIT }}
|
token: ${{ secrets.ACCESS_TOKEN_GIT }}
|
||||||
# ssh-known-hosts: ${{ secrets.SSH_KNOWN_GITEA }}
|
# ssh-known-hosts: ${{ secrets.SSH_KNOWN_GITEA }}
|
||||||
|
|
||||||
# - name: Login to docker private registry
|
- name: Login to docker private registry
|
||||||
# uses: docker/login-action@v3
|
uses: docker/login-action@v3
|
||||||
# with:
|
with:
|
||||||
# registry: ${{ vars.REGISTRY_DOCKER }}
|
registry: ${{ vars.REGISTRY_DOCKER }}
|
||||||
# username: ${{ secrets.REGISTRY_DOCKER_USER }}
|
username: ${{ secrets.REGISTRY_DOCKER_USER }}
|
||||||
# password: ${{ secrets.REGISTRY_DOCKER_PASS }}
|
password: ${{ secrets.REGISTRY_DOCKER_PASS }}
|
||||||
|
|
||||||
# - name: Build and push image in registry
|
- name: Build and push image in registry
|
||||||
# uses: docker/build-push-action@v5
|
uses: docker/build-push-action@v5
|
||||||
# with:
|
with:
|
||||||
# context: .
|
context: .
|
||||||
# push: true
|
push: true
|
||||||
# tags: ${{ vars.REGISTRY_DOCKER }}/${{ vars.DOCKER_IMAGE_NAME }}:latest,${{ vars.REGISTRY_DOCKER }}/${{ vars.DOCKER_IMAGE_NAME }}:${{ GITHUB_REF_NAME }}
|
tags: ${{ vars.REGISTRY_DOCKER }}/${{ vars.DOCKER_IMAGE_NAME }}:latest,${{ vars.REGISTRY_DOCKER }}/${{ vars.DOCKER_IMAGE_NAME }}:${{ gitea.ref_name }}
|
||||||
Reference in New Issue
Block a user