Skip to content

Scaleway

Scaleway is similar to Google Cloud however it is a company based in Europe and has all the stuff we need to host our website for free. You can find the free tier listed on scaleway’s pricing page, under “Serverless Containers”:

  • 400,000 GB-s per account per month
  • 200,000 vCPU-s per account per month
  • 75GB storage space in container registry (note that this MUST be public and if an image is bigger than 500MB it might produce charges).

Furthermore if we do somehow go over this, it should not cost that much due to the low prices (and you can always see the estimated charge you will get at the end of the month).

Scaleway’s documentation is also amazing, so if you need help just go their documentation

Signing up

For some reason, to sign up you only need to provide an email (and then specify a password and 2FA in the “profile”).

You will also need access to a card which can be charged 1€ - we recommend using a virtual card which you can then assign £0 budget or deactivate after signing up so that we can pass to other people later on (and they can’t charge your account). Make sure if they do charge you, you can and will pay for it, asking BCSS for money if you have to.

Once signed up, you have to verify the card (yes you haven’t done that yet). Simply click the button which says “verify card” and find the 4 digit code in your statement and enter that into the website.

Uploading a container

As mentioned in the video, to get a container running, you must upload it to the container registry.

To do this, you will first have to create a namespace (if you have not created one already there should be a bit “create a namespace” button when you click on the container registry option in the sidebar).

You can either tag one of your previously built containers as they mention:

Terminal window
docker tag ubuntu:latest rg.fr-par.scw.cloud/$namespace/ubuntu:latest

or you can build the dockerfile in the current directory with the tag

Terminal window
docker build -t rg.fr-par.scw.cloud/$namespace/ubuntu:latest .

And then you can push it with:

Terminal window
docker push rg.fr-par.scw.cloud/$namespace/ubuntu:latest

Now reload the page and you will be able to see your container there

Hosting a container

You can basically just click the 3 dots for the dropdown and click “deploy”.

  • You want to choose the namespace (scroll up)
  • Set the port to the one your container is listening to (the one you exposed)
  • Set the name + description
  • For resources don’t go overboard as we want to basically set it to the lowest it will be able to run at but it preferably it should run fast.
  • Scaling should be changed to between 0 and 1 instances.
  • You will probably have environment variables and secrets to set, which is under “Advanced Options”.
  • Under “Advanced Options” you will want to change the sandboxing to v2 as v1 is extremely slow at starting up instances.
  • You can then ignore the estimated cost (if you’ve calculated your total VCPUs and memory is under on your ENTIRE account)
  • Hit deploy!

You will then have to add a custom endpoint. Note you will have to wait until the container has been fully deployed (which takes a while).

Basically you want to add a CNAME record to the DNS and set its value to the given domain (make sure Cloudflare proxy-ing is off). Once that is done, just click add endpoint and type in the hostname with the record and it’ll generate a certificate for it.

Updating a container

Okay so I’m not 100% sure this is the official method. But basically you can push your updated image and then go onto the container (in scaleway) and click on the deploy tab then just click on the button at the bottom which says “deploy” and it should redeploy like that.

Monitoring

Scaleway uses Grafana for monitoring which you can access once you have enabled Cockpit.

We do love Grafana, if you don’t know how to use it, that’s fine, just follow the links scaleway gives you and marvel at Grafana’s beautiful and slightly slow interface (I feel like that’s because this is the free tier).