forked from canonical/vanilla-framework
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathrockcraft.yaml
More file actions
54 lines (52 loc) · 1.8 KB
/
rockcraft.yaml
File metadata and controls
54 lines (52 loc) · 1.8 KB
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
name: vanillaframework-io
base: ubuntu@22.04
version: '0.1'
summary: A simple, extendable CSS framework.
description: |
This is the rockcraft for the vanillaframework.io website
license: LGPL-3.0
platforms:
amd64:
extensions:
# https://documentation.ubuntu.com/rockcraft/en/latest/reference/extensions/flask-framework
- flask-framework
parts:
build-ui:
plugin: nil
source: .
source-type: local
build-snaps:
# Necessary to run `npm`
- node/22/stable
override-build: |
# set error & debugging flags - exit on error and pipe commands to the console
set -eux
# install dependencies
npm install -g yarn
yarn install
# https://documentation.ubuntu.com/rockcraft/en/latest/common/craft-parts/how-to/override_build/
# Vanilla's `build` dir is pointed to by `templates/static/build` symlink - it must be present at runtime
yarn run build
mkdir -p "$CRAFT_PART_INSTALL/flask/app"
cp -r build "$CRAFT_PART_INSTALL/flask/app/"
flask-framework/install-app:
after:
- build-ui
# Add all files that must be available to the Flask app at runtime.
prime:
- flask/app/.env
# Flask-framework / PAAS charm entrypoint - re-exports `webapp/app.py`
- flask/app/app.py
# App entrypoint
# flask/app/build is also needed but is manually staged in the build-ui step
- flask/app/webapp
- flask/app/templates
- flask/app/scripts
# These YAML files are read by `webapp/app.py` at runtime
- flask/app/component_tabs.yaml
- flask/app/deleted.yaml
- flask/app/releases.yml
- flask/app/redirects.yaml
- flask/app/side-navigation.yaml
# Used on the homepage, release notes page, download pages, to indicate the current version
- flask/app/package.json