diff --git a/conf/ArchiveBox.conf b/conf/ArchiveBox.conf new file mode 100644 index 0000000..18d8522 --- /dev/null +++ b/conf/ArchiveBox.conf @@ -0,0 +1,2 @@ +[DEPENDENCY_CONFIG] +NODE_BINARY=__YNH_NODE__ \ No newline at end of file diff --git a/scripts/install b/scripts/install index da4d7b5..95a6d1d 100755 --- a/scripts/install +++ b/scripts/install @@ -141,6 +141,9 @@ cp ../conf/package.json "$final_path/package.json" cp ../conf/package-lock.json "$final_path/package-lock.json" cd $final_path; ynh_npm ci +ynh_node_path=$ynh_node +ynh_script_progression --message="ynh_node_path: $ynh_node_path" --weight=1 + #================================================= # CREATE DATA DIRECTORY #================================================= @@ -160,6 +163,13 @@ chown -R $app:www-data "$datadir" # CREATE ARCHIVEBOX CONFIG #================================================= +# copy configuration file +ynh_add_config --template="../conf/ArchiveBox.conf" --destination="$datadir/ArchiveBox.conf" + +# permissions +chmod 750 "$datadir" +chmod -R o-rwx "$datadir" +chown -R $app:www-data "$datadir" #================================================= # INITIALIZE ARCHIVEBOX