You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+11-2Lines changed: 11 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,15 +14,24 @@ Explore the **[NPP Main GitHub Repository](https://github.com/psaux-it/nginx-fas
14
14
- ✅ Isolated and secure **PHP process owner** for enhanced security and performance
15
15
- ✅ Built with **bindfs** (1.17.7) + **fuse3** (1.16.2) for FUSE-based mounting of **Nginx Cache Path**
16
16
- ✅ Supports a wide range of **PHP extensions**
17
+
- ✅ Easily switch between the **stable** release and the **bleeding-edge dev** version of the **NPP**
17
18
- ✅ All containers powered by **Debian 12** for a stable, consistent environment
18
19
19
20
## 🔑 Environment Variables
20
21
21
22
Please check the **.env** file for the environment variables used by the project.
22
23
23
-
Some variables can be directly modified by the user to customize the setup, while others are integral to the project's core configuration. Changing these core variables may require some work to adjust other parts of the project to maintain proper integration and workflow.
24
+
Some variables can be directly modified by the user to customize the setup easily, while others are hard depend to the project's core configuration. Modifying these core variables for a production environment may require adjustments in other parts of the project to ensure proper integration and workflow. Feel free to customize it to meet your full-stack WordPress **production** needs!
24
25
25
-
Enjoy customizing it to suit your needs!
26
+
#### Use the Bleeding-Edge Version of NPP or Contribute to Development
27
+
28
+
If you want to use the **latest bleeding-edge version** of the NPP plugin or set up a **development/test environment**, simply set the following environment variable:
29
+
30
+
```bash
31
+
NPP_DEV_ENABLED=1
32
+
```
33
+
34
+
🔄 This will sync the plugin with the latest development branch commit from GitHub, ensuring you always have access to the newest features and improvements.
Copy file name to clipboardExpand all lines: wordpress/wp-cli.sh
+18-2Lines changed: 18 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -165,7 +165,7 @@ if [[ "${#NPP_PLUGINS[@]}" -gt 0 ]]; then
165
165
echo -e "${COLOR_RED}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET} Plugin ${COLOR_CYAN}${plugin}${COLOR_RESET} installation failed. Please check the logs for more details."
166
166
fi
167
167
else
168
-
echo -e "${COLOR_GREEN}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET} Plugin ${COLOR_CYAN}${plugin}${COLOR_RESET} is already installed."
168
+
echo -e "${COLOR_GREEN}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET} Plugin ${COLOR_CYAN}${plugin}${COLOR_RESET} is already installed. Skipping..."
169
169
fi
170
170
done
171
171
else
@@ -182,13 +182,26 @@ if [[ "${#NPP_THEMES[@]}" -gt 0 ]]; then
182
182
echo -e "${COLOR_RED}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET} Theme ${COLOR_CYAN}${theme}${COLOR_RESET} installation failed. Please check the logs for more details."
183
183
fi
184
184
else
185
-
echo -e "${COLOR_GREEN}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET} Theme ${COLOR_CYAN}${theme}${COLOR_RESET} is already installed."
185
+
echo -e "${COLOR_GREEN}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET} Theme ${COLOR_CYAN}${theme}${COLOR_RESET} is already installed. Skipping..."
186
186
fi
187
187
done
188
188
else
189
189
echo -e "${COLOR_YELLOW}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET}${COLOR_CYAN}No themes${COLOR_RESET} to install."
190
190
fi
191
191
192
+
# Check if the current permalink structure is already set
193
+
CURRENT_PERMALINK=$(su -m -c "wp option get permalink_structure""${NPP_USER}")
194
+
if [[ -z"$CURRENT_PERMALINK"||"$CURRENT_PERMALINK"=="/index.php/%pagename%/" ]];then
195
+
# Apply the new permalink structure
196
+
if su -m -c "wp rewrite structure '/%postname%/' --hard""${NPP_USER}">/dev/null 2>&1;then
197
+
echo -e "${COLOR_GREEN}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET}${COLOR_CYAN}Permalink structure${COLOR_RESET} has been successfully updated."
198
+
else
199
+
echo -e "${COLOR_RED}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET}${COLOR_CYAN}Failed to update${COLOR_RESET} permalink structure. Please check logs for more details."
200
+
fi
201
+
else
202
+
echo -e "${COLOR_GREEN}${COLOR_BOLD}NPP-WP-CLI:${COLOR_RESET}${COLOR_CYAN}Permalink structure${COLOR_RESET} is already properly set. Skipping..."
203
+
fi
204
+
192
205
# Check development deploy wanted
193
206
if [[ "${NPP_DEV_ENABLED}"-eq 1 ]];then
194
207
# Set variables
@@ -213,6 +226,7 @@ if [[ "${NPP_DEV_ENABLED}" -eq 1 ]]; then
0 commit comments