Installation guide for Docker, MySQL and git for Linux-based distributions.
1.1 Install Docker
Docker is a platform that allows you to create, deploy, and run applications in containers. Follow these instructions for your operating system:
- Update your package list and install Docker:
sudo apt-get update
sudo apt-get install docker.io
- Start Docker and enable it to start on boot:
sudo systemctl start docker
sudo systemctl enable docker
- Verify Docker installation:
docker --version
1.2 Install MySQL
Omeka S requires a MySQL database. Here’s how to install MySQL on different systems:
- Install MySQL server:
sudo apt-get install mysql-server
!During the installation process, you may be prompted to set a root password for MySQL. Enter a strong password and remember it for later use.
- Secure the MySQL installation:
sudo mysql_secure_installation
Follow the prompts to remove insecure default settings.
- Start MySQL and ensure it runs on startup:
sudo systemctl start mysql
sudo systemctl enable mysql
- Accessing MySQL; Log in to the MySQL command-line interface as root:
mysql -u root -p
Enter the root password you set during installation. if you need to enable root permission do the following instead:
sudo mysql -u root -p
- Create a new database:
CREATE DATABASE my_database;
- Create a new user and grant privileges:
CREATE USER 'newuser'@'localhost' IDENTIFIED BY 'userpassword'; GRANT ALL PRIVILEGES ON my_database.* TO 'newuser'@'localhost'; FLUSH PRIVILEGES;
Replace newuser with the
username
anduserpassword
with a strong password. You’ll also need to save your username and userpassword somewhere. For username it will later be prompted as;MYSQL_USER
=newuser and the password as;MYSQL_PASSWORD
=userpassword - Exit the MySQL shell:
EXIT;
- Testing the MySQL Installation
mysql -u root -p
Enter the root password you set during installation.
- Run a simple query to test:
SHOW DATABASES;
- You should see a list of databases, including the one you created (
my_database
).
1.3 Install Git
Git is a powerful version control system that allows you to track changes in your code and collaborate with others. This tutorial will guide you through the basic steps of installing Git, configuring it, and using fundamental Git commands.
- Open a terminal and run:
sudo apt-get update
sudo apt-get install git
1.4 Configuring Git
Once Git is installed, configure it with your name and email. This information will be used to track your commits.
- Set your username:
git config --global user.name "Your Name"
- Set your email:
git config --global user.email "your.email@example.com"
- You can check your configuration at any time with:
git config --list