Merge branch 'main' of github.com:AudebertAdrien/ft_transcendence

This commit is contained in:
Adrien Audebert 2024-07-18 15:03:32 +02:00
commit ec371e0db1
2 changed files with 84 additions and 13 deletions

View File

@ -11,26 +11,97 @@ This guide will help you install Docker and Docker Compose on an Ubuntu system.
1. **Update the package index:** 1. **Update the package index:**
```bash ```bash
sudo apt update sudo apt update
```
sudo apt install apt-transport-https ca-certificates curl software-properties-common 2. **Install required packages:**
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add - ```bash
sudo apt install apt-transport-https ca-certificates curl software-properties-common
```
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable" 3. **Add Docker's official GPG key:**
sudo apt update ```bash
curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
```
sudo apt install docker-ce 4. **Set up the Docker repository:**
sudo systemctl status docker ```bash
sudo add-apt-repository "deb [arch=amd64] https://download.docker.com/linux/ubuntu $(lsb_release -cs) stable"
```
sudo usermod -aG docker $USER 5. **Update the package index again:**
sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose ```bash
sudo apt update
```
sudo chmod +x /usr/local/bin/docker-compose 6. **Install Docker CE:**
```bash
sudo apt install docker-ce
```
7. **Check the Docker service status:**
```bash
sudo systemctl status docker
```
8. **Add your user to the `docker` group to run Docker commands without `sudo`:**
```bash
sudo usermod -aG docker $USER
```
9. **Log out and log back in to apply the group changes.**
## Installing Docker Compose
1. **Download Docker Compose:**
```bash
sudo curl -L "https://github.com/docker/compose/releases/download/1.29.2/docker-compose-$(uname -s)-$(uname -m)" -o /usr/local/bin/docker-compose
```
2. **Apply executable permissions to the Docker Compose binary:**
```bash
sudo chmod +x /usr/local/bin/docker-compose
```
3. **Verify the installation:**
```bash
docker-compose --version
```
## Verifying Docker and Docker Compose Installation
1. **Run a simple Docker container:**
```bash
docker run hello-world
```
This command downloads a test image and runs it in a container. When the container runs, it prints a confirmation message.
2. **Check Docker Compose version:**
```bash
docker-compose --version
```
This command outputs the version of Docker Compose installed.
Congratulations! You have successfully installed Docker and Docker Compose on your Ubuntu system.
## Additional Resources
- [Docker Documentation](https://docs.docker.com/)
- [Docker Compose Documentation](https://docs.docker.com/compose/)
docker compose version

View File

@ -1,4 +1,4 @@
from django.http import HttpResponse from django.http import HttpResponse
def index(request): def index(request):
return HttpResponse("Hello, QWER!") return HttpResponse("Hello, CHAKIB est une trompette!")