Skip to content

Commit

Permalink
CI: publish deb pkgs to repository (#131)
Browse files Browse the repository at this point in the history
  • Loading branch information
FelicianoTech authored Feb 13, 2022
1 parent e9cb95d commit c3bdf53
Showing 1 changed file with 34 additions and 0 deletions.
34 changes: 34 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,15 @@ workflows:
paths:
- "dist"
context: main
- deb-publish:
requires:
- gor/release
filters:
branches:
ignore: /.*/
tags:
# Simplified SemVer regex
only: /^v\d+\.\d+\.\d+$/

jobs:
test:
Expand Down Expand Up @@ -180,3 +189,28 @@ jobs:
echo ""
exit 1
fi
deb-publish:
docker:
- image: cimg/base:current
steps:
- attach_workspace:
at: .
- add_ssh_keys
- run: |
echo 'pkg.atl.revidian.net ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBE16slz1okRPeUhxIpzBCn9rHqjk51ylxEYlYXvblswcxOQ0rPyAX6N8Bd2pnsh99xce/jaX2KJHPLPCc+zAXTg= root@li361-16' >> ~/.ssh/known_hosts
- run: |
ssh [email protected] "mkdir ~/incoming/sonar-${CIRCLE_TAG}"
scp ./dist/*.deb [email protected]:incoming/sonar-${CIRCLE_TAG}/
# Ubuntu 20.04 Focal
ssh [email protected] "aptly repo add ftech-ubuntu-focal ~/incoming/sonar-${CIRCLE_TAG}/"
ssh [email protected] "aptly snapshot create ftech-ubuntu-focal--sonar-${CIRCLE_TAG} from repo ftech-ubuntu-focal"
ssh [email protected] "aptly publish switch focal filesystem:ftech:/ubuntu ftech-ubuntu-focal--sonar-${CIRCLE_TAG}"
# Ubuntu 21.10 Impish
ssh [email protected] "aptly repo add ftech-ubuntu-impish ~/incoming/sonar-${CIRCLE_TAG}/"
ssh [email protected] "aptly snapshot create ftech-ubuntu-impish--sonar-${CIRCLE_TAG} from repo ftech-ubuntu-impish"
ssh [email protected] "aptly publish switch impish filesystem:ftech:/ubuntu ftech-ubuntu-impish--sonar-${CIRCLE_TAG}"
ssh [email protected] "rm -r ~/incoming/sonar-${CIRCLE_TAG}"

0 comments on commit c3bdf53

Please sign in to comment.