mirror of
https://github.com/newnius/Dockerfiles.git
synced 2025-06-07 16:41:55 +00:00
add git
This commit is contained in:
parent
77aca1ab5a
commit
daf3d740ff
@ -9,7 +9,10 @@ RUN npm install hexo-generator-feed --save
|
|||||||
#Local Search
|
#Local Search
|
||||||
RUN npm install hexo-generator-searchdb --save
|
RUN npm install hexo-generator-searchdb --save
|
||||||
|
|
||||||
RUN npm install --save hexo-algolia
|
RUN npm install --save hexo-algolia@0.2.0
|
||||||
|
|
||||||
|
RUN npm install hexo-deployer-git --save
|
||||||
|
|
||||||
|
|
||||||
ADD bootstrap.sh /etc/bootstrap.sh
|
ADD bootstrap.sh /etc/bootstrap.sh
|
||||||
|
|
||||||
|
@ -3,7 +3,13 @@ https://hexo.io/zh-cn/
|
|||||||
http://theme-next.iissnan.com/
|
http://theme-next.iissnan.com/
|
||||||
|
|
||||||
First Time:
|
First Time:
|
||||||
docker service create --name hexo --publish 4000:4000 --mount type=bind,source=/mnt/data/blog,target=/blog newnius/hexo
|
docker service create \
|
||||||
|
--name hexo \
|
||||||
|
--publish 4000:4000 \
|
||||||
|
-e GIT_EMAIL="me@newnius.com" \
|
||||||
|
-e GIT_NAME="newnius" \
|
||||||
|
--mount type=bind,source=/mnt/data/blog,target=/blog \
|
||||||
|
newnius/hexo
|
||||||
|
|
||||||
Start Server:
|
Start Server:
|
||||||
docker service create --name hexo --publish 4000:4000 --mount type=bind,source=/mnt/data/blog,target=/blog newnius/hexo /etc/bootstrap.sh server
|
docker service create --name hexo --publish 4000:4000 --mount type=bind,source=/mnt/data/blog,target=/blog newnius/hexo /etc/bootstrap.sh server
|
||||||
|
@ -1,5 +1,8 @@
|
|||||||
#! /bin/bash
|
#! /bin/bash
|
||||||
|
|
||||||
|
git config --global user.email $GIT_EMAIL
|
||||||
|
git config --global user.name $GIT_NAME
|
||||||
|
|
||||||
if [ "$1" == "server" ]; then
|
if [ "$1" == "server" ]; then
|
||||||
# start hexo server
|
# start hexo server
|
||||||
echo "starting hexo..."
|
echo "starting hexo..."
|
||||||
|
Loading…
Reference in New Issue
Block a user