Skip to content

Commit

Permalink
ci: Do not deploy to PackageCloud
Browse files Browse the repository at this point in the history
Pave the way for deploying .deb and .rpm packages to
packages.freedom.press. Remove the code that deploys to PackageCloud
once we tag a commit with `v<semver>`.

Refs #291
  • Loading branch information
apyrgio committed Mar 27, 2023
1 parent 8a7d52b commit 7613941
Showing 1 changed file with 0 additions and 149 deletions.
149 changes: 0 additions & 149 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -54,28 +54,6 @@ aliases:
cp /caches/container.tar.gz share/
cp /caches/image-id.txt share/
- &deploy-packagecloud
command: |
VERSION=$(cat share/version.txt)
echo "PACKAGE_TYPE is ${PACKAGE_TYPE}"
echo "PACKAGECLOUD_DISTRO is ${PACKAGECLOUD_DISTRO}"
echo "VERSION is ${VERSION}"
echo ""
if [[ "${PACKAGE_TYPE}" == "deb" ]]; then
echo "pushing: deb_dist/dangerzone_${VERSION}-1_all.deb"
package_cloud push "firstlookmedia/code/${PACKAGECLOUD_DISTRO}" "deb_dist/dangerzone_${VERSION}-1_all.deb"
echo ""
echo "pushing: deb_dist/dangerzone_${VERSION}-1.dsc"
package_cloud push "firstlookmedia/code/${PACKAGECLOUD_DISTRO}" "deb_dist/dangerzone_${VERSION}-1.dsc"
elif [[ "${PACKAGE_TYPE}" == "rpm" ]]; then
echo "pushing: dist/dangerzone-${VERSION}-1.noarch.rpm"
package_cloud push "firstlookmedia/code/${PACKAGECLOUD_DISTRO}" "dist/dangerzone-${VERSION}-1.noarch.rpm"
echo ""
echo "pushing: dist/dangerzone-${VERSION}-1.src.rpm"
package_cloud push "firstlookmedia/code/${PACKAGECLOUD_DISTRO}" "dist/dangerzone-${VERSION}-1.src.rpm"
fi
jobs:
run-lint:
docker:
Expand Down Expand Up @@ -425,100 +403,6 @@ jobs:
- run: *copy-image
- run: *build-rpm

deploy-fedora:
docker:
- image: fedora:36
resource_class: medium+
steps:
- run: *install-dependencies-rpm
- checkout
- restore_cache: *restore-cache
- run: *copy-image
- run: *build-rpm
- run:
name: Install packagecloud.io
command: |
dnf module install -y ruby:2.7 # requires ruby 2.7
dnf --allowerasing -y distro-sync
dnf install -y ruby-devel
gem install package_cloud
- run:
name: Deploy fedora/37
environment:
PACKAGE_TYPE: "rpm"
PACKAGECLOUD_DISTRO: "fedora/37"
<<: *deploy-packagecloud
- run:
name: Deploy fedora/36
environment:
PACKAGE_TYPE: "rpm"
PACKAGECLOUD_DISTRO: "fedora/36"
<<: *deploy-packagecloud

deploy-debian:
docker:
- image: debian:bullseye
resource_class: medium+
steps:
- run: *install-dependencies-deb
- checkout
- restore_cache: *restore-cache
- run: *copy-image
- run: *build-deb
- run:
name: Install packagecloud.io
command: |
apt-get install -y ruby-dev rubygems
gem install -N rake
gem install -N package_cloud
- run:
name: Deploy debian/bullseye
environment:
PACKAGE_TYPE: "deb"
PACKAGECLOUD_DISTRO: "debian/bullseye"
<<: *deploy-packagecloud
- run:
name: Deploy debian/bookworm
environment:
PACKAGE_TYPE: "deb"
PACKAGECLOUD_DISTRO: "debian/bookworm"
<<: *deploy-packagecloud

deploy-ubuntu:
docker:
- image: ubuntu:22.04
resource_class: medium+
steps:
- run: *install-dependencies-deb
- checkout
- restore_cache: *restore-cache
- run: *copy-image
- run: *build-deb
- run:
name: Install packagecloud.io
command: |
apt-get install -y ruby-dev rubygems
gem install -N rake
gem install -N package_cloud
- run:
name: Deploy ubuntu/kinetic
environment:
PACKAGE_TYPE: "deb"
PACKAGECLOUD_DISTRO: "ubuntu/kinetic"
<<: *deploy-packagecloud
- run:
name: Deploy ubuntu/jammy
environment:
PACKAGE_TYPE: "deb"
PACKAGECLOUD_DISTRO: "ubuntu/jammy"
<<: *deploy-packagecloud
- run:
name: Deploy ubuntu/focal
environment:
PACKAGE_TYPE: "deb"
PACKAGECLOUD_DISTRO: "ubuntu/focal"
<<: *deploy-packagecloud

workflows:
version: 2

Expand Down Expand Up @@ -571,36 +455,3 @@ workflows:
- build-fedora-36:
requires:
- build-container-image

build-and-deploy:
jobs:
- build-container-image:
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
- deploy-ubuntu:
requires:
- build-container-image
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
- deploy-debian:
requires:
- build-container-image
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/
- deploy-fedora:
requires:
- build-container-image
filters:
tags:
only: /^v.*/
branches:
ignore: /.*/

0 comments on commit 7613941

Please sign in to comment.