Skip to content

bchassoul/singula

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Singula - All hostnames collapse into one port.

A simple application that serves multiple hostnames over HTTPS using self-signed certificates.

Setup Steps

  1. Add Local Domains

    Add the following entries to your /etc/hosts file:

    127.0.0.1 domain1.localhost domain2.localhost
    
  2. Generate SSL Certificates

    Run the certificate generation script:

    chmod +x generate_certs.sh
    ./generate_certs.sh

    This will create self-signed certificates in priv/certs/ for:

    • domain1.localhost
    • domain2.localhost

Running

  1. Start the App

    rebar3 shell

    The cowboy will start with:

    • HTTP on port 8080 (redirects to HTTPS)
    • HTTPS on port 8443

Testing

Visit the following URLs in your browser:

Note: Since we're using self-signed certificates, your browser will show a security warning. You can:

  • Click "Advanced" and proceed anyway (temporary)
  • Add the certificates to your system's trusted certificates (permanent)

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published