Deploy: Update deployment instructions
Move sensitive information into a dedicated .env file, which is required only for deployment purposes.
This commit is contained in:
parent
ebf4021da2
commit
9915951007
4
.env.example
Normal file
4
.env.example
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
# Copy this file as .env
|
||||||
|
# SSH account & hostname for publishing.
|
||||||
|
WEBSERVER_SSH_=user@domain
|
||||||
|
WEBSERVER_ROOT=/path-to/flamenco.blender.org
|
1
.gitignore
vendored
1
.gitignore
vendored
@ -5,6 +5,7 @@
|
|||||||
*.db
|
*.db
|
||||||
*.blend[0-9]
|
*.blend[0-9]
|
||||||
*.flamenco.blend
|
*.flamenco.blend
|
||||||
|
.env
|
||||||
|
|
||||||
/flamenco-manager
|
/flamenco-manager
|
||||||
/flamenco-worker
|
/flamenco-worker
|
||||||
|
19
Makefile
19
Makefile
@ -1,3 +1,5 @@
|
|||||||
|
-include .env
|
||||||
|
|
||||||
PKG := git.blender.org/flamenco
|
PKG := git.blender.org/flamenco
|
||||||
|
|
||||||
# To update the version number in all the relevant places, update the VERSION
|
# To update the version number in all the relevant places, update the VERSION
|
||||||
@ -41,9 +43,17 @@ FFMPEG_VERSION=5.0.1
|
|||||||
TOOLS=./tools
|
TOOLS=./tools
|
||||||
TOOLS_DOWNLOAD=./tools/download
|
TOOLS_DOWNLOAD=./tools/download
|
||||||
|
|
||||||
# SSH account & hostname for publishing.
|
# For production deployments: check variables stored in .env
|
||||||
WEBSERVER_SSH=flamenco@flamenco.blender.org
|
.PHONY: check-environment
|
||||||
WEBSERVER_ROOT=/var/www/flamenco.blender.org
|
check-environment:
|
||||||
|
ifndef WEBSERVER_SSH
|
||||||
|
echo "WEBSERVER_SSH not found. Check .env or .env.example"
|
||||||
|
exit 1
|
||||||
|
endif
|
||||||
|
ifndef WEBSERVER_ROOT
|
||||||
|
echo "WEBSERVER_ROOT not found. Check .env or .env.example"
|
||||||
|
exit 1
|
||||||
|
endif
|
||||||
|
|
||||||
all: application
|
all: application
|
||||||
|
|
||||||
@ -230,9 +240,11 @@ clean-webapp-static:
|
|||||||
touch ${WEB_STATIC}/emptyfile
|
touch ${WEB_STATIC}/emptyfile
|
||||||
|
|
||||||
project-website:
|
project-website:
|
||||||
|
$(MAKE) check-environment
|
||||||
rm -rf web/project-website/public/
|
rm -rf web/project-website/public/
|
||||||
cd web/project-website; hugo --baseURL https://flamenco.blender.org/
|
cd web/project-website; hugo --baseURL https://flamenco.blender.org/
|
||||||
rsync web/project-website/public/ ${WEBSERVER_SSH}:${WEBSERVER_ROOT}/ \
|
rsync web/project-website/public/ ${WEBSERVER_SSH}:${WEBSERVER_ROOT}/ \
|
||||||
|
-e "ssh" \
|
||||||
-va \
|
-va \
|
||||||
--exclude v2/ \
|
--exclude v2/ \
|
||||||
--exclude downloads/ \
|
--exclude downloads/ \
|
||||||
@ -338,6 +350,7 @@ release-package-windows:
|
|||||||
|
|
||||||
.PHONY: publish-release-packages
|
.PHONY: publish-release-packages
|
||||||
publish-release-packages:
|
publish-release-packages:
|
||||||
|
$(MAKE) check-environment
|
||||||
cd dist; sha256sum ${RELEASE_PACKAGE_LINUX} ${RELEASE_PACKAGE_DARWIN} ${RELEASE_PACKAGE_WINDOWS} > ${RELEASE_PACKAGE_SHAFILE}
|
cd dist; sha256sum ${RELEASE_PACKAGE_LINUX} ${RELEASE_PACKAGE_DARWIN} ${RELEASE_PACKAGE_WINDOWS} > ${RELEASE_PACKAGE_SHAFILE}
|
||||||
cd dist; rsync -va \
|
cd dist; rsync -va \
|
||||||
${RELEASE_PACKAGE_LINUX} ${RELEASE_PACKAGE_DARWIN} ${RELEASE_PACKAGE_WINDOWS} ${RELEASE_PACKAGE_SHAFILE} \
|
${RELEASE_PACKAGE_LINUX} ${RELEASE_PACKAGE_DARWIN} ${RELEASE_PACKAGE_WINDOWS} ${RELEASE_PACKAGE_SHAFILE} \
|
||||||
|
@ -12,14 +12,15 @@ people.
|
|||||||
|
|
||||||
Replace `${VERSION}` with the actual version number.
|
Replace `${VERSION}` with the actual version number.
|
||||||
|
|
||||||
|
1. Ensure that env variables are set in the `.env` file (see `.env.example` for reference)
|
||||||
1. Update `CHANGELOG.md` and mark the to-be-released version as released today.
|
1. Update `CHANGELOG.md` and mark the to-be-released version as released today.
|
||||||
2. Update `web/project-website/data/flamenco.yaml` for the new version.
|
1. Update `web/project-website/data/flamenco.yaml` for the new version.
|
||||||
3. Update `Makefile` and change the `VERSION` and `RELEASE_CYCLE` variables.
|
1. Update `Makefile` and change the `VERSION` and `RELEASE_CYCLE` variables.
|
||||||
4. `make update-version`
|
1. `make update-version`
|
||||||
5. `git commit -m "Bump version to ${VERSION}"`
|
1. `git commit -m "Bump version to ${VERSION}"`
|
||||||
6. `git tag v${VERSION}`
|
1. `git tag v${VERSION}`
|
||||||
7. `make release-package`
|
1. `make release-package`
|
||||||
8. Check that the files in `dist/` are there and have a non-zero size.
|
1. Check that the files in `dist/` are there and have a non-zero size.
|
||||||
9. `make publish-release-packages` to upload the packages to the website.
|
1. `make publish-release-packages` to upload the packages to the website.
|
||||||
10. `make project-website` to generate and publish the new website.
|
1. `make project-website` to generate and publish the new website.
|
||||||
11. `git push && git push --tags`
|
1. `git push && git push --tags`
|
||||||
|
Loading…
Reference in New Issue
Block a user