diff --git a/.gitignore b/.gitignore index 23690f9398be19588cd759c9ce03e9834353981d..178a946a2706351530892d8d6dadc99033e3e1c7 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ data .env -/apps_sources \ No newline at end of file +/apps_sources +cozy.yaml \ No newline at end of file diff --git a/assets/default-wallpaper.jpg b/assets/default-wallpaper.jpg new file mode 100644 index 0000000000000000000000000000000000000000..a759bececf0c60da8b4a8af372a4282cef736ca4 Binary files /dev/null and b/assets/default-wallpaper.jpg differ diff --git a/assets/default-wallpaper.xcf b/assets/default-wallpaper.xcf new file mode 100644 index 0000000000000000000000000000000000000000..35e9849e03241680de3ed769f8fc7919d94a67d8 Binary files /dev/null and b/assets/default-wallpaper.xcf differ diff --git a/assets/default-wallpaper_base.jpg b/assets/default-wallpaper_base.jpg new file mode 100644 index 0000000000000000000000000000000000000000..ddfdb91f2cbc25731065e78d696d52466e95a07d Binary files /dev/null and b/assets/default-wallpaper_base.jpg differ diff --git a/assets/logo_grand_lyon.png b/assets/logo_grand_lyon.png new file mode 100644 index 0000000000000000000000000000000000000000..6de642eb6519623a7936d56c4c2bf144b820ba2d Binary files /dev/null and b/assets/logo_grand_lyon.png differ diff --git a/create-instance.sh b/create-instance.sh index 67c813465255de26155448cfa7264f81356f2150..e3d29377bb50c89bdd4761e282a753e7e14b92fd 100755 --- a/create-instance.sh +++ b/create-instance.sh @@ -21,10 +21,10 @@ echo "Creating instance ${INSTANCE_ID}.${COZY_TLD} ..." docker-compose exec cozy ./cozy instances add $OIDC_CONTEXT --host 0.0.0.0 --apps drive,collect,settings,home "${INSTANCE_ID}.${COZY_TLD}" | tee "${TMPFILE}" # Install grand lyon apps -docker-compose exec cozy ./cozy konnectors install enedis-scraping-connector --domain "${INSTANCE_ID}.${COZY_TLD}" file:///apps_sources/enedis-scraping-connector-build -docker-compose exec cozy ./cozy konnectors install grdf-scraping-connector --domain "${INSTANCE_ID}.${COZY_TLD}" file:///apps_sources/grdf-scraping-connector-build -docker-compose exec cozy ./cozy konnectors install egl-api-connector --domain "${INSTANCE_ID}.${COZY_TLD}" file:///apps_sources/egl-api-connector-build -docker-compose exec cozy ./cozy apps install energy-dataviz --domain "${INSTANCE_ID}.${COZY_TLD}" file:///apps_sources/energy-dataviz-build +docker-compose exec cozy ./cozy konnectors install enedis-scraping-connector --domain "${INSTANCE_ID}.${COZY_TLD}" file:///tmp/apps_sources/enedis-scraping-connector-build +docker-compose exec cozy ./cozy konnectors install grdf-scraping-connector --domain "${INSTANCE_ID}.${COZY_TLD}" file:///tmp/apps_sources/grdf-scraping-connector-build +docker-compose exec cozy ./cozy konnectors install egl-api-connector --domain "${INSTANCE_ID}.${COZY_TLD}" file:///tmp/apps_sources/egl-api-connector-build +docker-compose exec cozy ./cozy apps install energy-dataviz --domain "${INSTANCE_ID}.${COZY_TLD}" file:///tmp/apps_sources/energy-dataviz-build ## To replace by registry://store/something after next cozy-stack release docker-compose exec cozy ./cozy apps install --domain "${INSTANCE_ID}.${COZY_TLD}" store registry://store/stable | tee -a "${TMPFILE}" diff --git a/customize-cozy.sh b/customize-cozy.sh new file mode 100755 index 0000000000000000000000000000000000000000..9623e998874a12922117be19651eb07a0eb16d03 --- /dev/null +++ b/customize-cozy.sh @@ -0,0 +1,10 @@ +#!/bin/bash +docker-compose exec cozy ./cozy assets add --url file:///tmp/assets/default-wallpaper.jpg --name /images/default-wallpaper.jpg --context open-id-connect +docker-compose exec cozy ./cozy assets add --url file:///tmp/assets/default-wallpaper.jpg --name /images/default-wallpaper.jpg --context default + +# `/styles/theme.css`: a CSS file where you can override the colors and put other CSS rules +# `/favicon-16x16.png` and `/favicon-32x32.png`: the two variants of the favicon +# `/apple-touch-icon.png`: the same but for Apple +# `/images/default-avatar.png`: the image to use as the default avatar +# `/images/default-wallpaper.png`: the image to use as the default wallpapper on the home +# `/images/icon-cozy-home.svg`: the home icon used and displayed by the cozy-bar diff --git a/docker-compose.yml b/docker-compose.yml index 3207a89c7dd7bfd39a3d2424b8f96a90f991f3db..7b1458d7ea54d3bf1068281b567197753a0251c5 100644 --- a/docker-compose.yml +++ b/docker-compose.yml @@ -30,7 +30,8 @@ services: - /etc/timezone:/etc/timezone:ro - /etc/localtime:/etc/localtime:ro - ./cozystack/cozy.yaml:/etc/cozy/cozy.yaml - - ./apps_sources:/apps_sources + - ./apps_sources:/tmp/apps_sources + - ./assets:/tmp/assets ports: - 8080:8080 depends_on: diff --git a/install.sh b/install.sh index 19e823700d454877ca15108b53855a7870add150..bbd8dcfd97fd84668705fb8730aefdf3636d92c1 100755 --- a/install.sh +++ b/install.sh @@ -4,7 +4,10 @@ # Download the apps ./download_apps.sh -# build the image if it doesn't exists +# Config file generation +sudo ./generate-cozy-yaml.sh + +# Build the image if it doesn't exists if [[ "$(docker images -q npernoud/easy-cozy:latest-amd64 2> /dev/null)" == "" ]]; then ./build/build-docker-image.sh fi @@ -15,13 +18,13 @@ sudo chown -Rf 1000 ./data/ docker-compose up -d sleep 15 -# database creation +# Database creation sudo ./init.sh -# config file generation -sudo ./generate-cozy-yaml.sh -# instance creation, replace demo by the name you want -sudo ./create-instance.sh demo -# oidc with keycloak instance creation +# Cozy customization +sudo ./customize-cozy.sh +# OIDC with keycloak instance creation sudo ./create-instance.sh demooidc oidc -# insertion of the EGL api secrets in the database +# Instance creation, replace demo by the name you want +sudo ./create-instance.sh demo +# Insertion of the EGL api secrets in the database sudo ./egl-db-init.sh diff --git a/update_apps.sh b/update_apps.sh index 2558763ec6262974af0560ce1cb578216aca2ab1..2b611a41fb221a2fffbaefba729ed38232f6b1cb 100755 --- a/update_apps.sh +++ b/update_apps.sh @@ -3,7 +3,7 @@ echo "Updating Apps & Konnectors ..." -docker-compose exec cozy ./cozy konnectors update enedis-scraping-connector --all-domains file:///apps_sources/enedis-scraping-connector-build -docker-compose exec cozy ./cozy konnectors update grdf-scraping-connector --all-domains file:///apps_sources/grdf-scraping-connector-build -docker-compose exec cozy ./cozy konnectors update egl-api-connector --all-domains file:///apps_sources/egl-api-connector-build -docker-compose exec cozy ./cozy apps update energy-dataviz --all-domains file:///apps_sources/energy-dataviz-build +docker-compose exec cozy ./cozy konnectors update enedis-scraping-connector --all-domains file:///tmp/apps_sources/enedis-scraping-connector-build +docker-compose exec cozy ./cozy konnectors update grdf-scraping-connector --all-domains file:///tmp/apps_sources/grdf-scraping-connector-build +docker-compose exec cozy ./cozy konnectors update egl-api-connector --all-domains file:///tmp/apps_sources/egl-api-connector-build +docker-compose exec cozy ./cozy apps update energy-dataviz --all-domains file:///tmp/apps_sources/energy-dataviz-build