mirror of
https://github.com/hassio-addons/addon-vscode.git
synced 2025-05-03 18:51:23 +00:00
devenv
This commit is contained in:
parent
72a4bae085
commit
a2bcc30d84
3 changed files with 18 additions and 1 deletions
|
@ -20,10 +20,14 @@ hassio_api: true
|
||||||
hassio_role: manager
|
hassio_role: manager
|
||||||
homeassistant_api: true
|
homeassistant_api: true
|
||||||
map:
|
map:
|
||||||
|
- type: addons
|
||||||
|
read_only: false
|
||||||
- type: backup
|
- type: backup
|
||||||
read_only: false
|
read_only: false
|
||||||
- type: data
|
- type: data
|
||||||
read_only: false
|
read_only: false
|
||||||
|
- type: homeassistant_config
|
||||||
|
read_only: false
|
||||||
- type: media
|
- type: media
|
||||||
read_only: false
|
read_only: false
|
||||||
- type: share
|
- type: share
|
||||||
|
|
|
@ -10,7 +10,6 @@ bashio::log.info "Initalizing code-server configs"
|
||||||
source "/etc/s6-overlay/s6-rc.d/paths.sh"
|
source "/etc/s6-overlay/s6-rc.d/paths.sh"
|
||||||
|
|
||||||
# List of previous config hashes, to allow upgrade "default" configs.
|
# List of previous config hashes, to allow upgrade "default" configs.
|
||||||
readonly CUSTOM_BASH_SCRIPTS_PATH="/data/custom"
|
|
||||||
|
|
||||||
run() {
|
run() {
|
||||||
if [ ! -d "$CUSTOM_BASH_SCRIPTS_PATH" ]; then
|
if [ ! -d "$CUSTOM_BASH_SCRIPTS_PATH" ]; then
|
||||||
|
@ -19,6 +18,11 @@ run() {
|
||||||
bashio::exit.nok "Could not create persistent storage folder."
|
bashio::exit.nok "Could not create persistent storage folder."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
if [[ ! -e "$CUSTOM_BASH_SCRIPTS_PATH"/custom-scripts.md ]]; then
|
||||||
|
bashio::log.warning "custom-scripts.md does not exist."
|
||||||
|
cp "$DEFAULT_FILES_PATH"/core/custom-scripts.md "$CUSTOM_BASH_SCRIPTS_PATH"/custom-scripts.md
|
||||||
|
fi
|
||||||
|
|
||||||
if [[ ! -e "$CUSTOM_BASH_SCRIPTS_PATH"/custom-template.sh ]]; then
|
if [[ ! -e "$CUSTOM_BASH_SCRIPTS_PATH"/custom-template.sh ]]; then
|
||||||
bashio::log.warning "custom-template.sh does not exist."
|
bashio::log.warning "custom-template.sh does not exist."
|
||||||
cp "$DEFAULT_FILES_PATH"/core/custom-template.sh "$CUSTOM_BASH_SCRIPTS_PATH"/custom-template.sh
|
cp "$DEFAULT_FILES_PATH"/core/custom-template.sh "$CUSTOM_BASH_SCRIPTS_PATH"/custom-template.sh
|
||||||
|
|
|
@ -0,0 +1,9 @@
|
||||||
|
|
||||||
|
# Custom Scripts
|
||||||
|
|
||||||
|
This directory is for shell scripts to be ran at boot time so you can add functionality if needed.
|
||||||
|
|
||||||
|
## custom-template.sh
|
||||||
|
|
||||||
|
This script is an example of a script that has an on/off switch that can allow you to add extra functionality when needed. To run it,
|
||||||
|
change ENABLED to true and restart the VS Code server instance.
|
Loading…
Add table
Add a link
Reference in a new issue