2022-06-11 16:57:12 +00:00
|
|
|
matrix:
|
|
|
|
docker_prefix:
|
|
|
|
- ""
|
|
|
|
- arm64v8/
|
|
|
|
- arm32v7/
|
|
|
|
tag:
|
|
|
|
- amd64
|
|
|
|
- arm64
|
|
|
|
- arm
|
|
|
|
|
|
|
|
include:
|
|
|
|
- tag: amd64
|
|
|
|
docker_prefix: ""
|
|
|
|
- tag: arm64
|
|
|
|
docker_prefix: arm64v8/
|
|
|
|
- tag: arm
|
|
|
|
docker_prefix: arm32v7/
|
|
|
|
|
2022-06-10 16:40:01 +00:00
|
|
|
|
2022-06-11 16:57:12 +00:00
|
|
|
pipeline:
|
|
|
|
glibc:
|
2022-06-11 15:41:15 +00:00
|
|
|
when:
|
|
|
|
event:
|
2022-06-11 16:34:13 +00:00
|
|
|
- push
|
2022-06-11 16:42:29 +00:00
|
|
|
secrets:
|
|
|
|
- SCW_ACCESS_KEY
|
|
|
|
- SCW_SECRET_KEY
|
|
|
|
- SCW_DEFAULT_ORGANIZATION_ID
|
2022-06-10 16:40:01 +00:00
|
|
|
group: release
|
2022-06-11 16:57:12 +00:00
|
|
|
image: ${docker_prefix}elixir:1.13
|
2022-06-10 16:40:01 +00:00
|
|
|
environment:
|
|
|
|
MIX_ENV: prod
|
|
|
|
commands:
|
2022-06-11 16:57:12 +00:00
|
|
|
- apt-get update && apt-get install -y cmake libmagic-dev rclone zip
|
2022-06-10 16:40:01 +00:00
|
|
|
- wget https://github.com/scaleway/scaleway-cli/releases/download/v2.5.1/scaleway-cli_2.5.1_linux_amd64
|
|
|
|
- mv scaleway-cli_2.5.1_linux_amd64 scaleway-cli
|
|
|
|
- chmod +x scaleway-cli
|
|
|
|
- ./scaleway-cli object config install type=rclone
|
|
|
|
- echo "import Mix.Config" > config/prod.secret.exs
|
2022-06-11 16:44:12 +00:00
|
|
|
- mix local.hex --force
|
|
|
|
- mix local.rebar --force
|
2022-06-10 16:40:01 +00:00
|
|
|
- mix deps.get --only prod
|
|
|
|
- mkdir release
|
|
|
|
- export PLEROMA_BUILD_BRANCH=$CI_COMMIT_BRANCH
|
|
|
|
- mix release --path release
|
2022-06-11 16:57:12 +00:00
|
|
|
- zip akkoma-$CI_COMMIT_BRANCH-${tag}.zip -r release
|
|
|
|
- rclone copyto akkoma-$CI_COMMIT_BRANCH-${tag}.zip scaleway:akkoma-updates/$CI_COMMIT_BRANCH/akkoma-${tag}.zip
|
2022-06-11 15:41:15 +00:00
|
|
|
|
2022-06-11 16:57:12 +00:00
|
|
|
musl:
|
2022-06-11 15:41:15 +00:00
|
|
|
when:
|
|
|
|
event:
|
2022-06-11 16:17:14 +00:00
|
|
|
- tag
|
2022-06-11 15:41:15 +00:00
|
|
|
|
|
|
|
group: release
|
2022-06-11 16:57:12 +00:00
|
|
|
image: ${docker_prefix}elixir:1.13-alpine
|
2022-06-11 15:41:15 +00:00
|
|
|
environment:
|
|
|
|
MIX_ENV: prod
|
|
|
|
commands:
|
2022-06-11 16:57:12 +00:00
|
|
|
- apk add git gcc g++ musl-dev make cmake file-dev rclone wget zip
|
2022-06-11 15:41:15 +00:00
|
|
|
- wget https://github.com/scaleway/scaleway-cli/releases/download/v2.5.1/scaleway-cli_2.5.1_linux_amd64
|
|
|
|
- mv scaleway-cli_2.5.1_linux_amd64 scaleway-cli
|
|
|
|
- chmod +x scaleway-cli
|
|
|
|
- ./scaleway-cli object config install type=rclone
|
|
|
|
- echo "import Mix.Config" > config/prod.secret.exs
|
|
|
|
- mix deps.get --only prod
|
|
|
|
- mkdir release
|
|
|
|
- export PLEROMA_BUILD_BRANCH=${CI_COMMIT_BRANCH}
|
|
|
|
- mix release --path release
|
2022-06-11 16:57:12 +00:00
|
|
|
- zip akkoma-$CI_COMMIT_BRANCH-${tag}.zip -r release
|
|
|
|
- rclone copyto akkoma-$CI_COMMIT_BRANCH-${tag}.zip scaleway:akkoma-updates/$CI_COMMIT_BRANCH/akkoma-${tag}.zip
|