1
.github/commands/ci-setup
vendored
1
.github/commands/ci-setup
vendored
@@ -1,6 +1,5 @@
|
|||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
set -eo pipefail
|
set -eo pipefail
|
||||||
set -x
|
|
||||||
|
|
||||||
DOKKU_DOMAIN=${DOKKU_DOMAIN:="dokku.me"}
|
DOKKU_DOMAIN=${DOKKU_DOMAIN:="dokku.me"}
|
||||||
|
|
||||||
|
|||||||
16
.github/workflows/ci.yml
vendored
16
.github/workflows/ci.yml
vendored
@@ -19,7 +19,7 @@ env:
|
|||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
check-commit:
|
check-commit:
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
outputs:
|
outputs:
|
||||||
skip: ${{ steps.check-commit.outputs.skip }}
|
skip: ${{ steps.check-commit.outputs.skip }}
|
||||||
|
|
||||||
@@ -43,7 +43,7 @@ jobs:
|
|||||||
|
|
||||||
build:
|
build:
|
||||||
name: build
|
name: build
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
needs: check-commit
|
needs: check-commit
|
||||||
if: ${{ needs.check-commit.outputs.skip != 'true' }}
|
if: ${{ needs.check-commit.outputs.skip != 'true' }}
|
||||||
outputs:
|
outputs:
|
||||||
@@ -83,7 +83,7 @@ jobs:
|
|||||||
build-image-amd64:
|
build-image-amd64:
|
||||||
name: build-image.linux/amd64
|
name: build-image.linux/amd64
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@@ -97,7 +97,7 @@ jobs:
|
|||||||
build-image-arm64:
|
build-image-arm64:
|
||||||
name: build-image.linux/arm64
|
name: build-image.linux/arm64
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: buildjet-4vcpu-ubuntu-2204-arm
|
runs-on: buildjet-4vcpu-ubuntu-2404-arm
|
||||||
timeout-minutes: 20
|
timeout-minutes: 20
|
||||||
|
|
||||||
steps:
|
steps:
|
||||||
@@ -111,7 +111,7 @@ jobs:
|
|||||||
unit-tests:
|
unit-tests:
|
||||||
name: unit.${{ matrix.index }}
|
name: unit.${{ matrix.index }}
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix: ${{fromJson(needs.build.outputs.matrix)}}
|
matrix: ${{fromJson(needs.build.outputs.matrix)}}
|
||||||
@@ -151,7 +151,7 @@ jobs:
|
|||||||
docker-deploy-tests:
|
docker-deploy-tests:
|
||||||
name: docker
|
name: docker
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
|
|
||||||
@@ -181,7 +181,7 @@ jobs:
|
|||||||
go-tests:
|
go-tests:
|
||||||
name: go.${{ matrix.index }}
|
name: go.${{ matrix.index }}
|
||||||
needs: build
|
needs: build
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
strategy:
|
strategy:
|
||||||
fail-fast: false
|
fail-fast: false
|
||||||
matrix:
|
matrix:
|
||||||
@@ -222,7 +222,7 @@ jobs:
|
|||||||
publish-test-results:
|
publish-test-results:
|
||||||
name: publish-test-results
|
name: publish-test-results
|
||||||
needs: unit-tests
|
needs: unit-tests
|
||||||
runs-on: ubuntu-22.04
|
runs-on: ubuntu-24.04
|
||||||
permissions:
|
permissions:
|
||||||
checks: write
|
checks: write
|
||||||
# the build-and-test job might be skipped, we don't need to run this job then
|
# the build-and-test job might be skipped, we don't need to run this job then
|
||||||
|
|||||||
10
tests.mk
10
tests.mk
@@ -86,7 +86,11 @@ ifneq ($(wildcard /etc/ssh/sshd_config),)
|
|||||||
ifeq ($(shell grep 22333 /etc/ssh/sshd_config),)
|
ifeq ($(shell grep 22333 /etc/ssh/sshd_config),)
|
||||||
sed --in-place "s:^Port 22:Port 22 \\nPort 22333:g" /etc/ssh/sshd_config
|
sed --in-place "s:^Port 22:Port 22 \\nPort 22333:g" /etc/ssh/sshd_config
|
||||||
endif
|
endif
|
||||||
service ssh restart
|
ifeq ($(shell grep 22333 /usr/lib/systemd/system/ssh.socket),)
|
||||||
|
sed --in-place "s:^ListenStream=22:ListenStream=22 \\nListenStream=22333:g" /usr/lib/systemd/system/ssh.socket
|
||||||
|
endif
|
||||||
|
systemctl daemon-reload
|
||||||
|
systemctl restart ssh.socket
|
||||||
endif
|
endif
|
||||||
|
|
||||||
@echo "-----> Installing SSH public key..."
|
@echo "-----> Installing SSH public key..."
|
||||||
@@ -116,9 +120,9 @@ endif
|
|||||||
prime-ssh-known-hosts:
|
prime-ssh-known-hosts:
|
||||||
@echo "-----> Intitial SSH connection to populate known_hosts..."
|
@echo "-----> Intitial SSH connection to populate known_hosts..."
|
||||||
@echo "=====> SSH $(DOKKU_DOMAIN)"
|
@echo "=====> SSH $(DOKKU_DOMAIN)"
|
||||||
ssh -o StrictHostKeyChecking=no dokku@$(DOKKU_DOMAIN) help >/dev/null
|
ssh -o StrictHostKeyChecking=no dokku@$(DOKKU_DOMAIN) help
|
||||||
@echo "=====> SSH 127.0.0.1"
|
@echo "=====> SSH 127.0.0.1"
|
||||||
ssh -o StrictHostKeyChecking=no dokku@127.0.0.1 help >/dev/null
|
ssh -o StrictHostKeyChecking=no dokku@127.0.0.1 help
|
||||||
|
|
||||||
lint-setup:
|
lint-setup:
|
||||||
@mkdir -p test-results/shellcheck tmp/shellcheck
|
@mkdir -p test-results/shellcheck tmp/shellcheck
|
||||||
|
|||||||
@@ -111,7 +111,7 @@ EOF
|
|||||||
|
|
||||||
sleep 5
|
sleep 5
|
||||||
echo "-----> Start install ${ROOT_DIR}/build/package/dokku-${architecture}.deb via dpkg"
|
echo "-----> Start install ${ROOT_DIR}/build/package/dokku-${architecture}.deb via dpkg"
|
||||||
sudo TRACE=1 dpkg -i "${ROOT_DIR}/build/package/dokku-${architecture}.deb"
|
sudo dpkg -i "${ROOT_DIR}/build/package/dokku-${architecture}.deb"
|
||||||
echo "-----> End install ${ROOT_DIR}/build/package/dokku-${architecture}.deb via dpkg"
|
echo "-----> End install ${ROOT_DIR}/build/package/dokku-${architecture}.deb via dpkg"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user