From 081b4b279ae41e46bae87e18baf3961cad9f15bd Mon Sep 17 00:00:00 2001 From: FloatingGhost Date: Sat, 11 Jun 2022 17:34:13 +0100 Subject: [PATCH] only test release --- .woodpecker/.lint.yml | 2 +- .woodpecker/.release.yml | 11 ++++++----- .woodpecker/.test.yml | 4 ++-- rel/files/bin/pleroma_ctl | 6 ++---- 4 files changed, 11 insertions(+), 12 deletions(-) diff --git a/.woodpecker/.lint.yml b/.woodpecker/.lint.yml index 0bac90d73..d4f6576a3 100644 --- a/.woodpecker/.lint.yml +++ b/.woodpecker/.lint.yml @@ -7,4 +7,4 @@ pipeline: - mix format --check-formatted when: event: - - push + - tag diff --git a/.woodpecker/.release.yml b/.woodpecker/.release.yml index 253dd8071..45ec8ed24 100644 --- a/.woodpecker/.release.yml +++ b/.woodpecker/.release.yml @@ -6,7 +6,7 @@ pipeline: amd64-glibc: when: event: - - tag + - push group: release image: elixir:1.13 @@ -24,7 +24,7 @@ pipeline: - export PLEROMA_BUILD_BRANCH=$CI_COMMIT_BRANCH - mix release --path release - zip akkoma-$CI_COMMIT_BRANCH-${platform}.zip -r release - - rclone copy akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/ + - rclone copyto akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/$CI_COMMIT_BRANCH/akkoma-${platform}.zip amd64-musl: when: @@ -47,7 +47,7 @@ pipeline: - export PLEROMA_BUILD_BRANCH=${CI_COMMIT_BRANCH} - mix release --path release - zip akkoma-$CI_COMMIT_BRANCH-${platform}.zip -r release - - rclone copy akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/ + - rclone copyto akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/$CI_COMMIT_BRANCH/akkoma-${platform}.zip arm64-glibc: when: @@ -70,7 +70,8 @@ pipeline: - export PLEROMA_BUILD_BRANCH=$CI_COMMIT_BRANCH - mix release --path release - zip akkoma-$CI_COMMIT_BRANCH-${platform}.zip -r release - - rclone copy akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/ + - rclone copyto akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/$CI_COMMIT_BRANCH/akkoma-${platform}.zip + arm64-musl: when: @@ -93,4 +94,4 @@ pipeline: - export PLEROMA_BUILD_BRANCH=${CI_COMMIT_BRANCH} - mix release --path release - zip akkoma-$CI_COMMIT_BRANCH-${platform}.zip -r release - - rclone copy akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/ + - rclone copyto akkoma-$CI_COMMIT_BRANCH-${platform}.zip scaleway:akkoma-updates/$CI_COMMIT_BRANCH/akkoma-${platform}.zip diff --git a/.woodpecker/.test.yml b/.woodpecker/.test.yml index cef743643..e06a4d54e 100644 --- a/.woodpecker/.test.yml +++ b/.woodpecker/.test.yml @@ -10,7 +10,7 @@ pipeline: image: pleromaforkci/ci-base:${ELIXIR_VERSION} when: event: - - push + - tag environment: MIX_ENV: test commands: @@ -24,7 +24,7 @@ pipeline: image: pleromaforkci/ci-base:${ELIXIR_VERSION} when: event: - - push + - tag environment: MIX_ENV: test POSTGRES_DB: pleroma_test diff --git a/rel/files/bin/pleroma_ctl b/rel/files/bin/pleroma_ctl index 87c486514..648ca405e 100755 --- a/rel/files/bin/pleroma_ctl +++ b/rel/files/bin/pleroma_ctl @@ -5,8 +5,6 @@ detect_flavour() { arch="$(uname -m)" if [ "$arch" = "x86_64" ]; then arch="amd64" - elif [ "$arch" = "armv7l" ]; then - arch="arm" elif [ "$arch" = "aarch64" ]; then arch="arm64" else @@ -77,13 +75,13 @@ update() { done RELEASE_ROOT=$(dirname "$SCRIPTPATH") - uri="https://git.pleroma.social" + uri="https://akkoma-updates.s3-website.fr-par.scw.cloud" project_id="2" project_branch="${BRANCH:-$(detect_branch)}" flavour="${FLAVOUR:-$(detect_flavour)}" tmp="${TMP_DIR:-/tmp}" artifact="$tmp/pleroma.zip" - full_uri="${FULL_URI:-${uri}/api/v4/projects/${project_id}/jobs/artifacts/${project_branch}/download?job=${flavour}}" + full_uri="${FULL_URI:-${uri}/${project_branch}/akkoma-${flavour}}.zip" echo "Downloading the artifact from ${full_uri} to ${artifact}" curl "$full_uri" -o "${artifact}" echo "Unpacking ${artifact} to ${tmp}"