forked from asbru-cm/asbru-cm
-
Notifications
You must be signed in to change notification settings - Fork 0
/
.travis.yml
104 lines (102 loc) · 4.22 KB
/
.travis.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
os: linux
dist: bionic
language: perl
services:
- docker
env:
global:
- CHANGELOG_NAME=Asbru-CM Team
- CHANGELOG_EMAIL=contact@asbru-cm.net
- PRODUCT=asbru-cm
jobs:
- OS=debian DIST=stretch PACKAGE=deb PACKAGECLOUD=true
- OS=debian DIST=buster PACKAGE=deb EXECUTE_BUILD_DOCS=true PACKAGECLOUD=true
- OS=debian DIST=bullseye PACKAGE=deb PACKAGECLOUD=true
- OS=ubuntu DIST=xenial PACKAGE=deb PACKAGECLOUD=true
- OS=ubuntu DIST=bionic PACKAGE=deb PACKAGECLOUD=true
- OS=ubuntu DIST=focal PACKAGE=deb PACKAGECLOUD=true
- OS=ubuntu DIST=jammy PACKAGE=deb REPACK_DEB=yes PACKAGECLOUD=true
- OS=fedora DIST=34 PACKAGE=rpm PACKAGECLOUD=true
- OS=fedora DIST=35 PACKAGE=rpm PACKAGECLOUD=true
- OS=fedora DIST=36 PACKAGE=rpm PACKAGECLOUD=true
- OS=fedora DIST=37 PACKAGE=rpm DOCKER_REPO=asbru/asbru-cm PACKAGECLOUD=true
- OS=el DIST=7 PACKAGE=rpm PACKAGECLOUD=true
- OS=el DIST=8 PACKAGE=rpm PACKAGECLOUD=true
- OS=linuxmint DIST=tara PACKAGE=deb DOCKER_IMAGE=ubuntu-bionic PACKAGECLOUD=true
- OS=linuxmint DIST=tessa PACKAGE=deb DOCKER_IMAGE=ubuntu-bionic PACKAGECLOUD=true
- OS=linuxmint DIST=tina PACKAGE=deb DOCKER_IMAGE=ubuntu-bionic PACKAGECLOUD=true
- OS=linuxmint DIST=tricia PACKAGE=deb DOCKER_IMAGE=ubuntu-bionic PACKAGECLOUD=true
- OS=linuxmint DIST=ulyana PACKAGE=deb DOCKER_IMAGE=ubuntu-focal PACKAGECLOUD=false
- OS=linuxmint DIST=ulyssa PACKAGE=deb DOCKER_IMAGE=ubuntu-focal PACKAGECLOUD=false
- OS=linuxmint DIST=uma PACKAGE=deb DOCKER_IMAGE=ubuntu-focal PACKAGECLOUD=false
- OS=linuxmint DIST=una PACKAGE=deb DOCKER_IMAGE=ubuntu-focal PACKAGECLOUD=false
- OS=linuxmint DIST=vanessa PACKAGE=deb DOCKER_IMAGE=ubuntu-jammy PACKAGECLOUD=false
- OS=pop DIST=focal PACKAGE=deb DOCKER_IMAGE=ubuntu-focal PACKAGECLOUD=false
- OS=pop DIST=jammy PACKAGE=deb REPACK_DEB=yes DOCKER_IMAGE=ubuntu-jammy PACKAGECLOUD=false
- OS=elementary DIST=odin PACKAGE=deb DOCKER_IMAGE=ubuntu-focal PACKAGECLOUD=false
before_install:
- curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
- sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
- sudo apt-get update
- sudo apt-get -y -o Dpkg::Options::="--force-confnew" install docker-ce
install:
- sudo apt-get update
- sudo apt-get install -y git devscripts debhelper quilt python3 python3-pip python3-setuptools gpgv
- sudo pip3 install --upgrade pip
- sudo pip3 install --upgrade cloudsmith-cli
script:
- ./build.sh
- bash scripts/deploy_docs.sh
deploy:
- provider: packagecloud
skip_cleanup: true
repository: snapshots
username: ${PACKAGECLOUD_USER}
token: ${PACKAGECLOUD_TOKEN}
dist: ${OS}/${DIST}
package_glob: "build/*.{deb,rpm,dsc}"
on:
branch: master
condition: $PACKAGECLOUD = true
- provider: packagecloud
skip_cleanup: true
repository: asbru-cm
username: ${PACKAGECLOUD_USER}
token: ${PACKAGECLOUD_TOKEN}
dist: ${OS}/${DIST}
package_glob: "build/*.{deb,rpm,dsc}"
on:
tags: true
condition: $PACKAGECLOUD = true
- provider: packagecloud
skip_cleanup: true
repository: loki
username: ${PACKAGECLOUD_USER}
token: ${PACKAGECLOUD_TOKEN}
dist: ${OS}/${DIST}
package_glob: "build/*.{deb,rpm,dsc}"
on:
branch: loki
condition: $PACKAGECLOUD = true
- provider: script
skip_cleanup: true
script: scripts/deploy.sh snapshots
on:
branch: master
- provider: script
skip_cleanup: true
script: scripts/deploy.sh loki
on:
branch: loki
- provider: script
skip_cleanup: true
script: scripts/deploy.sh release
on:
tags: true
after_deploy:
# Prune old packages from packagecloud. The last 5 should be enough.
- pip install -r ./packpack/tools/requirements.txt
- python ./packpack/tools/packagecloud prune ${PACKAGECLOUD_USER}/snapshots deb ${OS} ${DIST} --keep 5
- python ./packpack/tools/packagecloud prune ${PACKAGECLOUD_USER}/snapshots rpm ${OS} ${DIST} --keep 5
- python ./packpack/tools/packagecloud prune ${PACKAGECLOUD_USER}/loki deb ${OS} ${DIST} --keep 5
- python ./packpack/tools/packagecloud prune ${PACKAGECLOUD_USER}/loki rpm ${OS} ${DIST} --keep 5