Commit Graph

141 Commits

Author SHA1 Message Date
3d567ff6f8 Docker: use variables instead of hard-coded stuff
WHEELHOUSE: since we're defining the variable we might as well use it.
DOCKER_IMAGE_NAME: introduced to prevent duplications of the name, and to
    add a little confirmation message when the script is done.
2019-05-14 10:36:15 +02:00
cfbb3d7e5a Poetry'ising the docker stuff 2019-05-14 10:36:15 +02:00
35675866ee Build our own HAproxy docker image
The HAproxy docker image we were using is no longer maintained (hasn't been
for years), but is built upon Alpine Linux which has a big security leak:
https://talosintelligence.com/vulnerability_reports/TALOS-2019-0782

The security leak is fixed in this build of the docker image, but we should
move to something else (lke Træfik).
2019-05-09 14:12:02 +02:00
fb016c3e3b build wheels using the correct Docker image 2019-03-29 15:18:10 +01:00
c5f8add5f5 Made it easier to rebuild the Docker image after someone else built it
Because we only pushed the final image to Docker Hub, it was impossible to
pull the base image someone else created and "quickly" build a new deploy
image.

Now the deploy scripts push (some) of the intermediate images as well,
making it possible to pull them later. I've added `build-pull.sh` and
`full-pull.sh` to perform this pull and built up from the pulled images.
2019-03-13 15:47:12 +01:00
fc986b0ab6 Renamed docker/4_run/deploy to docker/4_run/staging
"Staging" covers the meaning of what is actually happening better than
"deploy". I want to keep "deploy" for actually deploying onto a production
server.
2019-02-13 10:39:18 +01:00
5bf1693d5b Removed RabbitMQ docker container from docker-compose.yml
Now that Celery switched to using Redis as broker, we no longer need
RabbitMQ. Celery has been running on Redis for a while now and it all seems
fine, so it's time to wave the Rabbit goodbye.
2018-12-04 17:57:49 +01:00
27caff7e6e Docker: added little list of Redis database numbers we're using 2018-12-04 11:30:48 +01:00
a674de4db5 Remove CELERY_BEAT_SCHEDULE from config_local
CELERY_BEAT_SCHEDULE shouldn't need any changes in config_local for
production; the default should be production-ready.
2018-10-10 14:58:52 +02:00
7f58be4568 Updated Blender Cloud add-on to 1.9.0
Also change the config_local.py so that we only have to change one variable
for a new version.
2018-09-05 13:40:24 +02:00
099984f97c Added #!/bin/sh at top of shell script 2018-08-30 12:53:34 +02:00
8bfb40ce54 Various Docker image upgrades, read the entire commit message!
- Ubuntu 17.10 → 18.04.
- Python 3.6.3 → 3.6.6.
- Use `DEBIAN_FRONTEND=noninteractive` to prevent prompts during
  installation.
- Install `tzdata` in the base image as it's required by subimages.
- Correctly set maintainer in Dockerfile.
2018-08-30 12:53:34 +02:00
d60a65c9f0 End BLENDER_ID_ENDPOINT with a slash 2018-08-30 12:46:58 +02:00
9cd2853e49 Upgrade pip after building Python 2018-08-30 12:31:31 +02:00
4696d09fed Corrected rewrite rule for Caminandes 2018-07-06 14:56:40 +02:00
4e8530478a Remove trailing slash from BLENDER_ID_ENDPOINT 2018-06-22 19:40:44 +02:00
b66b6cf445 Reduced verbosity of mongo-backup.sh 2018-06-14 11:57:36 +02:00
b153cae70e Increased WSGI thread count 32 → 64 2018-06-13 10:47:28 +02:00
6a698daaa0 Remove time from logs; timestamp is added by Apache anyway. 2018-03-27 16:42:43 +02:00
5f07c7ce17 Use new hashing of static file names.
Every time the docker image is rebuilt a random hash is chosen.

Requires Pillar d560f89704e3a6f4490df57712525048c469bed2 or newer.
2018-03-23 17:39:04 +01:00
5a42e2dcb8 Flip condition to unindent pretty much all the code
No semantic changes.
2018-03-23 17:24:36 +01:00
d5a54b7cf1 Formatting 2018-03-23 16:37:58 +01:00
7cb4b37ae2 Renamed some docker files to Dockerfile
This makes it simpler to manage by using the default name. It also helps
my editor to recognise the file and highlight it properly.
2018-03-23 12:42:56 +01:00
1fca473257 Moved Apache files into separate subdir 2018-03-23 12:12:39 +01:00
5a6035a494 Change hostname from blender-cloud → cloud.local in docker-compose.yml 2018-03-23 12:11:59 +01:00
98698be7eb Add redirect for waking-the-forest project
Waking the Forest was originally part of the Art Gallery, but was
moved to its own dedicated workshop to increase visibility.
2018-03-19 11:17:45 +01:00
d4f072480c Add convenience redirect from /hero to /p/hero 2018-03-14 14:35:27 +01:00
2d036ee657 Fix rsync of MongoDB backup to Swami
- Forcing IPv4 no longer necessary
- Directory on Swami is determined by rrsync parameters on Swami side
  .ssh/authorized_keys file.
2018-03-09 14:02:39 +01:00
29d1d02bfd Prevent error when there are no Mongo backups to remove yet. 2018-02-22 10:01:59 +01:00
2141aed06c Added script to run on server for nightly MongoDB backups
Forced to use IPv4 due to IPv6 connectivity issues with Swami.
2018-02-21 11:30:48 +01:00
c3ddc831aa Stricter XSendFilePath in Apache config 2018-02-14 11:07:47 +01:00
484ac34c50 T53983: Explicitly version the picohttp docker image 2018-02-13 12:32:19 +01:00
87cf5a9844 Revert "Add https://cloud*/* as virtual host to haproxy config"
This reverts commit 3be926b9b3.
2018-02-02 13:00:57 +01:00
5a3a7a3883 LetsEncrypt fixes
- Changed virtual host weight for the letsencrypt docker so that it is
  higher than any other weight
- Copy the renewal script to the server (previously it was available
  to the host at /data/git/blender-cloud/…, but no longer.
2018-02-02 12:39:07 +01:00
3be926b9b3 Add https://cloud*/* as virtual host to haproxy config
This allows testing on https://cloud3/ for example, without having to
edit the docker-compose.yml file on the cloud3 server.
2018-02-02 12:20:39 +01:00
6f73222dcd Add the most-changing files as last step for faster Docker rebuilds. 2018-02-02 12:09:16 +01:00
bef402a6b0 Updated documentation for the new way to deploy Blender Cloud 2018-02-02 12:01:47 +01:00
94ef616593 Placing code + assets directly into Docker image
This radically changes the way we deploy to the production server, as a
Git checkout is no longer required there. All the necessary files are
now inside the docker image. As a result, /data/git should no longer be
mounted as a Docker volume.

- Renamed docker/build.sh → docker/full_rebuild.sh
  This makes it clearer that it performs a full rebuild of the Docker images.
- Full rebuilds should be done on a regular basis to pull in Ubuntu
  security updates.
- Removed rsync_ui.sh, we no longer need it. Other projects can also
  remove their rsync_ui.sh.
- Moved deploy.sh → deploy/2docker.sh and added deploy/2server.sh
2018-02-02 12:01:17 +01:00
ffc4f271e8 Upgrade Docker base image to Ubuntu 17.10 2018-02-01 15:53:33 +01:00
add20f0c6c Fixed indentation 2018-01-12 12:33:48 +01:00
996beaf090 Bump version of elasticproxy to 1.2 2018-01-12 11:55:13 +01:00
37b84cf75a Upgraded ElasticSearch and Kibana to 6.1.1
Requires a reset + reindex of everything (well, that's the easiest way to
get things indexed properly again), which will loose us the Cloud stats.
Before doing this, export those to MongDB and upgrade the statscollector
to the version that I'll be committing soon.
2018-01-12 11:55:13 +01:00
eb2a058ce2 Python 3.6.3 → 3.6.4 2018-01-12 11:55:13 +01:00
4891803552 Docker: never cache the base image when rebuilding 2018-01-12 11:55:13 +01:00
ab11f98331 Removed notifserv from docker-compose.yml 2018-01-12 11:55:13 +01:00
0ed03240e7 Made docker-compose.yml indentation consistent. 2018-01-12 11:55:07 +01:00
de6cdbaf19 Fixed broken networking with new docker-compose.yml
- No more 'links', all dockers can reach each other by name
- Added 'depends_on', which handles startup sequence
- Allowed haproxy connection to the docker daemon socket
- Told haproxy explicitly which services to proxy. The 'docker:' prefix
  comes from the fact that the directory containing the docker-compose.yml
  file is called 'docker'.
2018-01-03 15:27:28 +01:00
e641565e6a Docker: Limit logging for celery worker 2017-12-22 11:58:47 +01:00
617b600ce8 Upgraded docker-compose.yaml file format from 1 to 3.4
This allows us to set logging options, which weren't available in version 1.
I've also added newlines around each service definition, and made the
formatting consistent across the entire file (using align-yaml, one of the
tools of the atom-beautify plugin for Atom).
2017-12-22 11:54:06 +01:00
5e15185166 HaProxy: Explicitly configure allowed TLS ciphers 2017-12-13 14:00:51 +01:00