Skip to content

Latest commit

 

History

History
94 lines (66 loc) · 4.32 KB

CONFIGURATION.md

File metadata and controls

94 lines (66 loc) · 4.32 KB

🛠️ Configuration - Snap Camera Server

In order to get the server running you need to complete the following 5 steps:

  1. Create Configuration file
  2. Generate SSL certificate
  3. Import Root certificate
  4. Start Docker
  5. Edit the /etc/hosts file

This can be done manually or automatically (Windows).

🤖 Automatic Configuration on Windows

Windows users can now use the Auto Configuration Tool, which will handle all of these tasks for you.

If you are not a Windows user or prefer to do the steps manually then you can watch the video guide below which covers all the steps in detail.

🎓 How To Video Guides

You can watch these step by step video guides on YouTube if you need help with the configuration on your local machine.

Windows Installation Guide

Snap Camera Server Windows Installation Guide

Mac OS Installation Guide

Snap Camera Server Mac OS Installation Guide

💪 Manual Configuration Steps

In addition to the full video guide each step is also covered by a short video tutorial

1. Create Configuration file (Video Tutorial)

You need to create a .env configuration file.

Create a copy of the file example.env and name the copy .env (without filename).

You can go with all default values and don't need to change anything unless your having problems with certain ports being occupied or if you want to host the server on the internet.

Read the Server Settings (.env) page for configuration details.

2. Generate SSL certificate (Video Tutorial)

Snap Camera will refuse to connect to your local server if you don't have a trusted SSL certificate. You need to generate a .crt and .key file and have the .crt file installed as trusted root certificate on your operating system.

Don't worry, it sounds harder than it is. Just make sure you have OpenSSL installed.

The required files can be generated with the included script ./gencert.bat or ./gencert.sh which will output:

  • ./ssl/studio-app.snapchat.com.crt
  • ./ssl/studio-app.snapchat.com.key

Docker compose expects these two files by default, otherwise the containers will not start.

3. Import Root certificate (Video Tutorial)

You need to tell your operating system to trust the newly generated certificate.

On Windows you can import the certificate in three different ways:

  1. By double-clicking the file and going through the pop up dialog
  2. By running the Widnows management console application certlm.msc
  3. By simply executing a command called certutil (what I recommend)
certutil -addstore -enterprise Root ./ssl/studio-app.snapchat.com.crt

You need to run this command as Administrator on a Windows Powershell.

4. Starting Docker (Video Tutorial)

You may start the docker containers now by executing the command

docker compose up

The command can be executed with a terminal like Windows Powershell.

Docker must be installed to execute this command

5. Edit the /etc/hosts file (Video Tutorial)

Connecting your Snap Camera application to your local server

You need to tell/force your Snap Camera application to use your server instead the one that has been shutdown on January 25, 2023.

  1. Edit your /etc/hosts file. For Windows users that file is located at

    %SYSTEMROOT%\System32\drivers\etc\hosts
    
  2. Open the file as Administrator and add a single line to connect your Snap Camera application to the local server

    127.0.0.1       studio-app.snapchat.com
  3. You can disable the connection anytime by placing a hash before the line

    #127.0.0.1       studio-app.snapchat.com

🎉 Congratulations

After completing the 5 steps you may now start Snap Camera!