Getting started with Magic and Hyperlambda
This tutorial covers the following parts of Magic and Hyperlambda.
- How to setup Magic locally in your own development environment using Docker or the code
- How to deploy Magic to your own VPS
- How to update Magic
- How to clone Magic’s code
- How to get support for Magic
The easiest way to get started is to download the docker-compose file from the primary Aista website, assuming you have Docker installed, and then execute the following in a terminal window where you saved the file.
When your docker containers have started, open your browser and go to http://localhost:5555, use the default connection string for MySQL, choose a root password, crudify your Magic database, type your name and email address when you generate a key pair, and Magic should work out of the box without any hassle. If you want to test Magic’s CRUD automation capabilities, there’s a “sakila” SQL script that you can execute in the “SQL” menu item to create an example database. In the video below I am illustrating this process.
If you want to use Magic with Microsoft SQL Server or PostgreSQL you can find recipes for this below.
Download the code
If you can’t use Docker, you can also configure your development environment locally on your development machine using the code directly. If so you will first of all need the following components.
- Visual Studio or VS Code + DotNet CLI and SDK
- MySQL or Microsoft SQL Server
- Download Magic Cloud’s source code from Aista’s website
To deploy Magic into production you can follow this recipe, which guides you through setting up your VPS server to host Magic.
If you’re using the docker images, updating Magic is fairly easy, and only requires you to stop Magic for some few seconds, update the core, and restart your docker containers again. Below is the entire recipe. Execute the following terminal commands one at the time. Make sure you execute the following in the same folder as where your main Magic “docker-compose.yml” file is.
docker-compose down docker pull aistamagic/magic-frontend docker pull aistamagic/magic-backend docker-compose up
Magic is not one project, it’s actually 35+ projects, implying if you clone only Magic, you’ll only get some few hundreds lines of code, while most of its actual code exists in one of the 35+ satellite projects. Hence, to clone Magic to for instance maintain it, or look at its code, you’ll have to follow this recipe.
If you have a support request of private nature, you can send us an email at firstname.lastname@example.org. If you want to submit a feature request or a bug report, you can do such through the project’s GitHub Issues.
- Continue with Automatically generate a CRUD Web API