Skip to content

Commit

Permalink
Updated Indico Rock to Ubuntu 24.04 (#437)
Browse files Browse the repository at this point in the history
* Updated Indico Rock to Ubuntu 24.04

* Removed unnecessary bash package

* Testing for integration

* Removed the charm.py changes and did a proper fix for pip
  • Loading branch information
alithethird authored Aug 8, 2024
1 parent 336d5e8 commit 7516278
Showing 1 changed file with 12 additions and 22 deletions.
34 changes: 12 additions & 22 deletions indico_rock/rockcraft.yaml
Original file line number Diff line number Diff line change
@@ -1,16 +1,12 @@
# Copyright 2024 Canonical Ltd.
# See LICENSE file for licensing details.
package-repositories:
- type: apt
ppa: deadsnakes/ppa
priority: always

name: indico
summary: Indico rock
description: Indico OCI image for the Indico charm
version: "1.0"
base: ubuntu@22.04
build-base: ubuntu@22.04
base: ubuntu@24.04
build-base: ubuntu@24.04
license: Apache-2.0
platforms:
amd64:
Expand All @@ -24,7 +20,6 @@ parts:
indico:
plugin: python
build-environment:
- PARTS_PYTHON_INTERPRETER: python3.12
- UWSGI_EMBED_PLUGINS: stats_pusher_statsd
python-packages:
- setuptools
Expand All @@ -39,18 +34,15 @@ parts:
- ./autocreate
source: plugins
build-packages:
- python3.12-venv
- python3.12-dev
- build-essential
- libpq-dev
- libsasl2-dev
- libxmlsec1-dev
- pkg-config
- wget
stage-packages:
- python3.12-venv
- python3.12-dev
- bash
- python3-venv
- python3-dev
- build-essential
- ca-certificates
- git-core
Expand All @@ -71,17 +63,15 @@ parts:
stage-snaps:
- celery-prometheus-exporter/latest/edge
- gtrkiller-statsd-prometheus-exporter/latest/edge
override-prime: |
override-stage: |
mkdir -p --mode=775 $CRAFT_PART_INSTALL/srv/indico/{archive,cache,custom,etc,log,tmp}
cp $CRAFT_PART_INSTALL/lib/python3.12/site-packages/indico/web/indico.wsgi $CRAFT_PART_INSTALL/srv/indico/indico.wsgi
cp -R $CRAFT_PART_INSTALL/lib/python3.12/site-packages/indico/web/static $CRAFT_PART_INSTALL/srv/indico/
chown -R 2000:2000 $CRAFT_PART_INSTALL/srv/indico
cp /etc/ssl/certs/ca-certificates.crt $CRAFT_PART_INSTALL/etc/ssl/certs/ca-certificates.crt
craftctl default
/bin/bash -c "mkdir -p --mode=775 srv/indico/{archive,cache,custom,etc,log,tmp}"
cp $CRAFT_PART_INSTALL/lib/python3.12/site-packages/indico/web/indico.wsgi srv/indico/indico.wsgi
/bin/bash -c "chown 2000:2000 srv/indico srv/indico/{archive,cache,custom,etc,indico.wsgi,log,tmp}"
cp -R $CRAFT_PART_INSTALL/lib/python3.12/site-packages/indico/web/static srv/indico/static
# Copy root certificates
mkdir -p usr/lib/ssl
mkdir -p etc/ssl/certs/
cp /etc/ssl/certs/ca-certificates.crt etc/ssl/certs/ca-certificates.crt
ln -s /etc/ssl/certs/ca-certificates.crt usr/lib/ssl/cert.pem
prime:
- -usr/lib/python3.12/EXTERNALLY-MANAGED
copy-config:
plugin: dump
source: .
Expand Down

0 comments on commit 7516278

Please sign in to comment.