You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pulsar.apache.org by ur...@apache.org on 2022/06/17 05:51:30 UTC
[pulsar-site] 01/01: fix: url trailing slash
This is an automated email from the ASF dual-hosted git repository.
urfree pushed a commit to branch fix/trailing-slash
in repository https://gitbox.apache.org/repos/asf/pulsar-site.git
commit f1fb00af0091641a9490c12fc1c48357e8b91fdc
Author: Li Li <ur...@apache.org>
AuthorDate: Fri Jun 17 13:51:19 2022 +0800
fix: url trailing slash
Signed-off-by: Li Li <ur...@apache.org>
---
site2/website-next/docker-compose.yaml | 9 +++++++++
site2/website-next/docusaurus.config.js | 9 ++-------
site2/website-next/scripts/docker.sh | 24 ------------------------
3 files changed, 11 insertions(+), 31 deletions(-)
diff --git a/site2/website-next/docker-compose.yaml b/site2/website-next/docker-compose.yaml
new file mode 100644
index 00000000000..77709f822ca
--- /dev/null
+++ b/site2/website-next/docker-compose.yaml
@@ -0,0 +1,9 @@
+version: "3.1"
+services:
+ db:
+ image: nginx:1.18.0-alpine
+ ports:
+ - 80:80
+ volumes:
+ - ./build:/usr/share/nginx/html
+ container_name: psite
\ No newline at end of file
diff --git a/site2/website-next/docusaurus.config.js b/site2/website-next/docusaurus.config.js
index fbe4f3f1050..06f18de82d4 100644
--- a/site2/website-next/docusaurus.config.js
+++ b/site2/website-next/docusaurus.config.js
@@ -124,6 +124,7 @@ module.exports = {
"Apache Pulsar is a cloud-native, distributed messaging and streaming platform originally created at Yahoo! and now a top-level Apache Software Foundation project",
url: "https://pulsar.apache.org",
baseUrl: baseUrl,
+ trailingSlash: false,
onBrokenLinks: "ignore",
onBrokenMarkdownLinks: "ignore",
favicon: "img/favicon.ico",
@@ -186,7 +187,7 @@ module.exports = {
],
},
{
- href: "/docs/next/",
+ href: "/docs/next",
position: "right",
label: "Docs",
},
@@ -397,12 +398,6 @@ module.exports = {
],
],
plugins: [
- [
- "@docusaurus/plugin-client-redirects",
- {
- fromExtensions: ["md"],
- },
- ],
"./postcss-tailwind-loader",
[
"content-docs",
diff --git a/site2/website-next/scripts/docker.sh b/site2/website-next/scripts/docker.sh
deleted file mode 100755
index a8ba676b9be..00000000000
--- a/site2/website-next/scripts/docker.sh
+++ /dev/null
@@ -1,24 +0,0 @@
-
-#! /bin/sh
-
-ROOT_DIR=$(git rev-parse --show-toplevel)
-CONTAINER_NAME="website-next"
-CONTAINER_ID=$(docker ps | grep $CONTAINER_NAME | awk '{print $1}')
-
-if [ -n "$CONTAINER_ID" ]
-then
- # use httpd
- echo "reload"
- # use nginx
- docker exec -it $CONTAINER_NAME nginx -s reload
-else
- # use httpd
- # docker run -dit --name $CONTAINER_NAME -p 80:80 -v $ROOT_DIR/site2/website-next/build:/usr/local/apache2/htdocs/ -v $ROOT_DIR/site2/website-next/scripts/httpd.conf:/usr/local/apache2/conf/httpd.conf httpd:2.4-alpine
- # use nginx
- docker run --name $CONTAINER_NAME -d -p 80:80 -v $ROOT_DIR/site2/website-next/build:/usr/share/nginx/html nginx:1.18.0-alpine
- # test old website
- # docker run --name $CONTAINER_NAME -d -p 80:80 -v $ROOT_DIR/../pulsar/site2/website/build/pulsar:/usr/share/nginx/html nginx:1.18.0-alpine
-fi
-
-
-echo "Website is running: http://localhost"