This is an automated email from the ASF dual-hosted git repository.
rombert pushed a commit to branch master
in repository
https://gitbox.apache.org/repos/asf/sling-org-apache-sling-starter.git
The following commit(s) were added to refs/heads/master by this push:
new 6df89a0 SLING-9818 - Move repoinit statements out of feature files
6df89a0 is described below
commit 6df89a001f0bf9fcf63ec1e42abd9accc45c19be
Author: Robert Munteanu <[email protected]>
AuthorDate: Tue Oct 13 12:44:07 2020 +0200
SLING-9818 - Move repoinit statements out of feature files
---
pom.xml | 2 +-
src/main/features/app/slingshot-repoinit.txt | 20 +++++++++++
src/main/features/app/slingshot.json | 23 +-----------
src/main/features/base-repoinit.txt | 49 +++++++++++++++++++++++++
src/main/features/base.json | 53 +---------------------------
src/main/features/caconfig-repoinit.txt | 1 +
src/main/features/caconfig.json | 4 +--
src/main/features/discovery-repoinit.txt | 8 +++++
src/main/features/discovery.json | 11 +-----
src/main/features/event-repoinit.txt | 8 +++++
src/main/features/event.json | 11 +-----
11 files changed, 92 insertions(+), 98 deletions(-)
diff --git a/pom.xml b/pom.xml
index 375f926..83b4b40 100644
--- a/pom.xml
+++ b/pom.xml
@@ -81,7 +81,7 @@
<plugin>
<groupId>org.apache.sling</groupId>
<artifactId>slingfeature-maven-plugin</artifactId>
- <version>1.3.16</version>
+ <version>1.4.2</version>
<extensions>true</extensions>
<configuration>
<replacePropertyVariables>jackrabbit.version,oak.version,slf4j.version,composum.nodes.version,jackson.version</replacePropertyVariables>
diff --git a/src/main/features/app/slingshot-repoinit.txt
b/src/main/features/app/slingshot-repoinit.txt
new file mode 100644
index 0000000..ec20794
--- /dev/null
+++ b/src/main/features/app/slingshot-repoinit.txt
@@ -0,0 +1,20 @@
+create service user slingshot-service with path system/sling
+create user slingshot1 with password slingshot1
+create user slingshot2 with password slingshot2
+
+create path (sling:Folder) /content/slingshot
+create path (sling:Folder) /content/slingshot/users
+create path (sling:Folder) /content/slingshot/users/slingshot1
+create path (sling:Folder) /content/slingshot/users/slingshot2
+
+set principal ACL for slingshot-service
+ allow jcr:read,rep:write on /content/slingshot
+end
+
+set ACL for slingshot1
+ allow jcr:read,rep:write on /content/slingshot/users/slingshot1
+end
+
+set ACL for slingshot2
+ allow jcr:read,rep:write on /content/slingshot/users/slingshot2
+end
\ No newline at end of file
diff --git a/src/main/features/app/slingshot.json
b/src/main/features/app/slingshot.json
index b4bbe7d..e55a673 100644
--- a/src/main/features/app/slingshot.json
+++ b/src/main/features/app/slingshot.json
@@ -13,26 +13,5 @@
]
}
},
- "repoinit:TEXT|true":[
- "create service user slingshot-service with path system/sling",
- "create user slingshot1 with password slingshot1",
- "create user slingshot2 with password slingshot2",
- "",
- "create path (sling:Folder) /content/slingshot",
- "create path (sling:Folder) /content/slingshot/users",
- "create path (sling:Folder) /content/slingshot/users/slingshot1",
- "create path (sling:Folder) /content/slingshot/users/slingshot2",
- "",
- "set principal ACL for slingshot-service",
- "allow jcr:read,rep:write on /content/slingshot",
- "end",
- "",
- "set ACL for slingshot1",
- "allow jcr:read,rep:write on /content/slingshot/users/slingshot1",
- "end",
- "",
- "set ACL for slingshot2",
- "allow jcr:read,rep:write on /content/slingshot/users/slingshot2",
- "end"
- ]
+ "repoinit:TEXT|true": "@file"
}
\ No newline at end of file
diff --git a/src/main/features/base-repoinit.txt
b/src/main/features/base-repoinit.txt
new file mode 100644
index 0000000..3064851
--- /dev/null
+++ b/src/main/features/base-repoinit.txt
@@ -0,0 +1,49 @@
+# general
+create path (sling:OrderedFolder) /content
+set ACL for everyone
+ allow jcr:read on /content
+end
+
+# sling-readall
+create service user sling-readall with path system/sling
+
+set principal ACL for sling-readall
+ allow jcr:read on /
+end
+
+# sling-xss
+create service user sling-xss with path system/sling
+
+create path (sling:Folder) /apps/sling/xss
+
+set principal ACL for sling-xss
+ allow jcr:read on /apps/sling/xss
+end
+
+# sling-jcr-install
+create service user sling-jcr-install with path system/sling
+
+# used for config OSGi writeback
+create path (sling:Folder) /apps/sling/install
+
+set principal ACL for sling-jcr-install
+ allow rep:write on /apps/sling/install
+end
+
+# content-package installer
+create service user sling-package-install with path system/sling
+
+set principal ACL for sling-package-install
+ allow jcr:all on /
+ allow jcr:namespaceManagement,jcr:nodeTypeDefinitionManagement on
:repository
+end
+#<<< SLING-5848 - Define service user and ACLs for Scripting
+create service user sling-search-path-reader with path system/sling
+
+create path (sling:Folder) /libs
+create path (sling:Folder) /apps
+
+set principal ACL for sling-search-path-reader
+ allow jcr:read on /libs,/apps
+end
+# SLING-5848 - Define service user and ACLs for Scripting >>>
\ No newline at end of file
diff --git a/src/main/features/base.json b/src/main/features/base.json
index 3c85cd6..b4a24f1 100644
--- a/src/main/features/base.json
+++ b/src/main/features/base.json
@@ -329,56 +329,5 @@
]
}
},
- "repoinit:TEXT|true":[
- "# general",
- "create path (sling:OrderedFolder) /content",
- "set ACL for everyone",
- "allow jcr:read on /content",
- "end",
- "",
- "# sling-readall",
- "create service user sling-readall with path system/sling",
- "",
- "set principal ACL for sling-readall",
- "allow jcr:read on /",
- "end",
- "",
- "# sling-xss",
- "create service user sling-xss with path system/sling",
- "",
- "create path (sling:Folder) /apps/sling/xss",
- "",
- "set principal ACL for sling-xss",
- "allow jcr:read on /apps/sling/xss",
- "end",
- "",
- "# sling-jcr-install",
- "create service user sling-jcr-install with path system/sling",
- "",
- "# used for config OSGi writeback",
- "create path (sling:Folder) /apps/sling/install",
- "",
- "set principal ACL for sling-jcr-install",
- "allow rep:write on /apps/sling/install",
- "end",
- "",
- "# content-package installer",
- "create service user sling-package-install with path system/sling",
- "",
- "set principal ACL for sling-package-install",
- "allow jcr:all on /",
- "allow jcr:namespaceManagement,jcr:nodeTypeDefinitionManagement on
:repository",
- "end",
- "#<<< SLING-5848 - Define service user and ACLs for Scripting",
- "create service user sling-search-path-reader with path system/sling",
- "",
- "create path (sling:Folder) /libs",
- "create path (sling:Folder) /apps",
- "",
- "set principal ACL for sling-search-path-reader",
- "allow jcr:read on /libs,/apps",
- "end",
- "# SLING-5848 - Define service user and ACLs for Scripting >>>"
-
- ]
+ "repoinit:TEXT|true":"@file"
}
diff --git a/src/main/features/caconfig-repoinit.txt
b/src/main/features/caconfig-repoinit.txt
new file mode 100644
index 0000000..33f6acc
--- /dev/null
+++ b/src/main/features/caconfig-repoinit.txt
@@ -0,0 +1 @@
+create path (sling:Folder) /conf
\ No newline at end of file
diff --git a/src/main/features/caconfig.json b/src/main/features/caconfig.json
index 9260235..5d9aef7 100644
--- a/src/main/features/caconfig.json
+++ b/src/main/features/caconfig.json
@@ -21,7 +21,5 @@
]
}
},
- "repoinit:TEXT|true":[
- "create path (sling:Folder) /conf"
- ]
+ "repoinit:TEXT|true": "@file"
}
\ No newline at end of file
diff --git a/src/main/features/discovery-repoinit.txt
b/src/main/features/discovery-repoinit.txt
new file mode 100644
index 0000000..383b122
--- /dev/null
+++ b/src/main/features/discovery-repoinit.txt
@@ -0,0 +1,8 @@
+create service user sling-discovery with path system/sling
+
+create path (sling:Folder) /var/discovery
+create path (sling:Folder) /var/discovery/oak
+
+set principal ACL for sling-discovery
+ allow jcr:read,rep:write on /var/discovery
+end
\ No newline at end of file
diff --git a/src/main/features/discovery.json b/src/main/features/discovery.json
index 817ae76..76eadfa 100644
--- a/src/main/features/discovery.json
+++ b/src/main/features/discovery.json
@@ -31,14 +31,5 @@
]
}
},
- "repoinit:TEXT|true":[
- "create service user sling-discovery with path system/sling",
- "",
- "create path (sling:Folder) /var/discovery",
- "create path (sling:Folder) /var/discovery/oak",
- "",
- "set principal ACL for sling-discovery",
- "allow jcr:read,rep:write on /var/discovery",
- "end"
- ]
+ "repoinit:TEXT|true": "@file"
}
\ No newline at end of file
diff --git a/src/main/features/event-repoinit.txt
b/src/main/features/event-repoinit.txt
new file mode 100644
index 0000000..01ec23a
--- /dev/null
+++ b/src/main/features/event-repoinit.txt
@@ -0,0 +1,8 @@
+create service user sling-event with path system/sling
+
+create path (sling:Folder) /var
+create path (sling:Folder) /var/eventing
+
+set principal ACL for sling-event
+ allow jcr:read,rep:write on /var/eventing
+end
\ No newline at end of file
diff --git a/src/main/features/event.json b/src/main/features/event.json
index 6bbb58b..19d17d7 100644
--- a/src/main/features/event.json
+++ b/src/main/features/event.json
@@ -18,14 +18,5 @@
]
}
},
- "repoinit:TEXT|true":[
- "create service user sling-event with path system/sling",
- "",
- "create path (sling:Folder) /var",
- "create path (sling:Folder) /var/eventing",
- "",
- "set principal ACL for sling-event",
- "allow jcr:read,rep:write on /var/eventing",
- "end"
- ]
+ "repoinit:TEXT|true": "@file"
}
\ No newline at end of file