mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-26 02:10:59 +00:00
docs: add build and upload scripts
The upload scripts might be unified down the track, or might not. CloudFront is not set up for the docs bucket yet, so CDN invalidation is commented out. This will be added later.
This commit is contained in:
parent
08e50aa39b
commit
a68c7ffb27
3
docs/build
Executable file
3
docs/build
Executable file
@ -0,0 +1,3 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
cd src; hugo
|
17
docs/upload-archive
Executable file
17
docs/upload-archive
Executable file
@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
if [[ $# -eq 0 ]] ; then
|
||||||
|
echo "Please supply a version, e.g. 'v3'"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
# This script uploads docs to a specified archive version.
|
||||||
|
|
||||||
|
SPATH="/archive/$1"
|
||||||
|
|
||||||
|
aws configure set preview.cloudfront true
|
||||||
|
aws --profile mitmproxy \
|
||||||
|
s3 sync --acl public-read ./public s3://docs.mitmproxy.org$SPATH
|
||||||
|
# aws --profile mitmproxy \
|
||||||
|
# cloudfront create-invalidation --distribution-id E3UCZ4MLN4TO7U \
|
||||||
|
# --paths "$SPATH"
|
8
docs/upload-master
Executable file
8
docs/upload-master
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
aws configure set preview.cloudfront true
|
||||||
|
aws --profile mitmproxy \
|
||||||
|
s3 sync --acl public-read ./public s3://docs.mitmproxy.org/master
|
||||||
|
# aws --profile mitmproxy \
|
||||||
|
# cloudfront create-invalidation --distribution-id E3UCZ4MLN4TO7U \
|
||||||
|
# --paths "/master"
|
8
docs/upload-stable
Executable file
8
docs/upload-stable
Executable file
@ -0,0 +1,8 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
aws configure set preview.cloudfront true
|
||||||
|
aws --profile mitmproxy \
|
||||||
|
s3 sync --acl public-read ./public s3://docs.mitmproxy.org/stable
|
||||||
|
# aws --profile mitmproxy \
|
||||||
|
# cloudfront create-invalidation --distribution-id E3UCZ4MLN4TO7U \
|
||||||
|
# --paths "/master"
|
Loading…
Reference in New Issue
Block a user