Compare commits
3 Commits
dceb5d6572
...
2cf9e25b59
Author | SHA1 | Date |
---|---|---|
Edwin | 2cf9e25b59 | |
Edwin | 9ff3d850c9 | |
Edwin | b4a1373559 |
|
@ -21,3 +21,4 @@ __pycache__/
|
|||
/debian/files
|
||||
/debian/.debhelper/
|
||||
/debian/debhelper-build-stamp
|
||||
/pyceo.tar.gz
|
||||
|
|
5
Makefile
5
Makefile
|
@ -31,4 +31,7 @@ clean:
|
|||
rm -rf venv
|
||||
rm -rf debian/{ceo,ceod,ceo-common,tmp}
|
||||
|
||||
.PHONY: build docs clean venv install
|
||||
package:
|
||||
podman run -it --rm -v "$$PWD":"$$PWD" -w "$$PWD" --security-opt label=disable debian:bullseye bash package.sh
|
||||
|
||||
.PHONY: build docs clean venv install package
|
||||
|
|
60
PACKAGING.md
60
PACKAGING.md
|
@ -9,56 +9,30 @@ Make sure your GPG key is in /srv/debian/gpg on potassium-benzoate. See
|
|||
[here](https://wiki.csclub.uwaterloo.ca/Debian_Repository#Step_1:_Add_to_Uploaders)
|
||||
for instructions.
|
||||
|
||||
Make sure you are in the `csc-mirror` group too.
|
||||
|
||||
## Creating the package
|
||||
Use Docker/Podman to avoid screwing up your main system.
|
||||
For example, to create a package for bullseye (replace `podman` with `docker` in all instances below if you're using Docker):
|
||||
```sh
|
||||
podman run -it --name pyceo-packaging -v "$PWD":"$PWD" -w "$PWD" debian:bullseye bash
|
||||
```
|
||||
**Important**: Make sure to use a container image for the same distribution which you're packaging.
|
||||
Make sure you have Podman installed.
|
||||
|
||||
Update `VERSION.txt` to the next version, `debian/changelog` with the new changes and do a git commit.
|
||||
|
||||
Run `make package` to build the package and create the tarball `pyceo.tar.gz` in the repo root.
|
||||
|
||||
**Important**: Make sure the container image for the same distribution which you're packaging.
|
||||
For example, if you're creating a package for bullseye, you should be using the debian:bullseye
|
||||
Docker image (this is because the virtualenv symlinks python to the OS' version of python).
|
||||
Docker image (this is because the virtualenv symlinks python to the OS' version of python). Also make
|
||||
sure that all of the packages in the 'Build-Depends' section in debian/control are installed in the container.
|
||||
|
||||
Here are some of the prerequisites you'll need to build the deb files
|
||||
(run this inside the container):
|
||||
At some point before actually uploading, you'll need to the sign the package. On the extracted tarball,
|
||||
run the following while placing your key ID after the `-k` argument, e.g.
|
||||
```sh
|
||||
apt update
|
||||
apt install -y devscripts debhelper git-buildpackage vim
|
||||
```
|
||||
Make sure to also install all of the packages in the 'Build-Depends' section in debian/control.
|
||||
|
||||
Update VERSION.txt to the next version, and do a git commit.
|
||||
|
||||
Now run `dch -i` and edit the changelog.
|
||||
|
||||
Now you will build a signed package. Place your key ID after the `-k` argument, e.g.
|
||||
```sh
|
||||
gbp buildpackage --git-upstream-branch=master -k8E5568ABB0CF96BC367806ED127923BE10DA48DC
|
||||
```
|
||||
This will create a bunch of files (deb, dsc, tar.gz, etc.) in the parent directory.
|
||||
|
||||
Now do another git commit (since you edited the changelog file).
|
||||
|
||||
To clean the packages:
|
||||
```sh
|
||||
rm ../*.{xz,gz,dsc,build,buildinfo,changes,deb}
|
||||
debsign -k8E5568ABB0CF96BC367806ED127923BE10DA48DC *.changes
|
||||
```
|
||||
|
||||
## Uploading the package
|
||||
Inside the container, go up one directory, and create a tarball with all the package files:
|
||||
Upload the tarball to a CSC machine, e.g.
|
||||
```
|
||||
cd ..
|
||||
tar zcvf pyceo.tar.gz *.{xz,gz,dsc,build,buildinfo,changes,deb}
|
||||
```
|
||||
Outside of the container (i.e. on your personal machine), copy the tarball out of the
|
||||
container into your current directory, e.g.
|
||||
```
|
||||
podman cp pyceo-packaging:/home/max/repos/pyceo.tar.gz .
|
||||
```
|
||||
(Replace `/home/max/repos` by the directory in the container with the tarball.)
|
||||
Now upload the tarball to a CSC machine, e.g.
|
||||
```
|
||||
scp pyceo.tar.gz mannitol:~/
|
||||
scp pyceo.tar.gz mannitol:~
|
||||
```
|
||||
SSH into that machine and extract the tarball into a separate directory:
|
||||
```
|
||||
|
@ -73,7 +47,7 @@ At this point, you will need a dupload.conf file. Ask someone on syscom for a co
|
|||
Now upload the package to potassium-benzoate:
|
||||
```
|
||||
kinit
|
||||
dupload *.changes
|
||||
dupload --to debian.csclub *.changes
|
||||
```
|
||||
|
||||
Now SSH into potassium-benzoate and run the following:
|
||||
|
|
|
@ -1 +1 @@
|
|||
1.0.23
|
||||
1.0.24
|
||||
|
|
|
@ -1,3 +1,16 @@
|
|||
ceo (1.0.24-bullseye1) bullseye; urgency=high
|
||||
|
||||
* Add support for using number in member terms renwewal API
|
||||
* Sort group member listing by WatIAM ID
|
||||
* Add more logging for Cloudstack
|
||||
* Use LDAP instead of NSS
|
||||
* Fix shadowExpire deserialization
|
||||
* Fix email formatting bug in ClubWebHostingService
|
||||
* Check if mail_local_addresses exists in UWLDAP entry
|
||||
* Remove override_dh_systemd_start
|
||||
|
||||
-- Edwin <e42zhang@csclub.uwaterloo.ca> Sun, 23 Oct 2022 00:00:00 +0000
|
||||
|
||||
ceo (1.0.23-bullseye1) bullseye; urgency=high
|
||||
|
||||
* Fix some bugs in ClubWebHostingService.
|
||||
|
|
|
@ -6,7 +6,8 @@ Standards-Version: 4.3.0
|
|||
Vcs-Git: https://git.csclub.uwaterloo.ca/public/pyceo.git
|
||||
Vcs-Browser: https://git.csclub.uwaterloo.ca/public/pyceo
|
||||
Uploaders: Max Erenberg <merenber@csclub.uwaterloo.ca>,
|
||||
Raymond Li <raymo@csclub.uwaterloo.ca>
|
||||
Raymond Li <raymo@csclub.uwaterloo.ca>,
|
||||
Edwin <e42zhang@csclub.uwaterloo.ca>
|
||||
Build-Depends: debhelper (>= 12.1.1),
|
||||
python3-dev (>= 3.7),
|
||||
python3-venv (>= 3.7),
|
||||
|
|
|
@ -1 +1 @@
|
|||
extend-diff-ignore = "^(venv/|docs/.+\.\d$|dist/|.+\.egg-info/|build/|\.vscode/|\.idea/)|__pycache__/|(^|/)\..+"
|
||||
extend-diff-ignore = "^(venv/|docs/.+\.\d$|dist/|.+\.egg-info/|build/|\.vscode/|\.idea/|pyceo\.tar\.gz)|__pycache__/|(^|/)\..+"
|
||||
|
|
|
@ -0,0 +1,5 @@
|
|||
#!/bin/sh
|
||||
|
||||
apt update && apt install -y git-buildpackage debhelper libkrb5-dev libpq-dev libaugeas0 python3-dev python3-venv scdoc
|
||||
gbp buildpackage --git-export-dir=/tmp/build --git-upstream-branch=master --no-sign
|
||||
tar zcvf pyceo.tar.gz -C /tmp/build .
|
Loading…
Reference in New Issue