Nvidia Unveils Futuristic Gaming Experience at Computex 2023
News

Nvidia Unveils Futuristic Gaming Experience at Computex 2023, Blending Gaming and AI

by Isabel
May 29, 2023
0

At Computex 2023, Nvidia displays a futuristic gaming experience that...

Read more
Adobe Introduces Powerful Generative AI Tools in Photoshop

Adobe Introduces Powerful Generative AI Tools in Photoshop Beta

May 29, 2023
Adobe Photoshop's Generative Fill Feature

Exploring the Power of Adobe Photoshop’s Generative Fill Feature

May 27, 2023
NVIDIA and Microsoft Partner to Accelerate AI

NVIDIA and Microsoft Partner to Accelerate AI

May 25, 2023
google photos security and privacy

Exploring the Top 5 Privacy and Security Risks of using Google Photos

May 24, 2023
Google I/O 2023

A New Update on Google I/O 2023 event

May 12, 2023
AutoGPT and ChatGPT

AutoGPT and ChatGPT: Discovering the World of AI Language Models

May 4, 2023
Google bard vs chatGPt

Bard vs ChatGPT: The Battle for the Future of AI

May 29, 2023
GPT4free chatbot

GPT4Free-Python based Discord Chatbot

May 5, 2023
AutoGPT plugins

Simplify Your Email Life with AutoGPT Plugins

May 5, 2023
How Bard Is Different from ChatGPT

How Bard Is Different from ChatGPT

May 18, 2023
Cloudbooklet
  • News
  • Artificial Intelligence
  • Linux
  • Google Cloud
  • AWS
No Result
View All Result
Cloudbooklet
  • News
  • Artificial Intelligence
  • Linux
  • Google Cloud
  • AWS
No Result
View All Result
Cloudbooklet
No Result
View All Result
Home Google Cloud

Running Docker Compose with Docker on Ubuntu 18.04 – Google Cloud

by Cloudbooklet
May 23, 2020
in Google Cloud, Compute Engine
Reading Time: 4 mins read
Running Docker Compose with Docker on Ubuntu 18.04
Share on FacebookShare on TwitterShare on WhatsAppShare on Telegram

Running Docker Compose with Docker on Ubuntu 18.04 – Google Cloud. Docker Compose provides an easy way to orchestrate the processes of Docker containers.

This guide helps you to install Docker Compose for managing multi-container applications.

You might also like

How to Setup SSH Keys on Ubuntu

How to Setup SSH Keys on Ubuntu 20.04

May 31, 2023
DragGAN AI editing Tool Install and Use DragGAN Photo Editor

DragGAN AI editing Tool Install and Use DragGAN Photo Editor

May 27, 2023

Prerequisites

  1. Your Compute Engine Instance running.
  2. For setting up Compute Engine, see the Setting up Compute Engine Instance.
  3. Ubuntu server setup on Google Cloud.
  4. How to install Docker on Ubuntu 18.04 LTS.

Install Docker Compose

We shall install latest version of Docker Compose from the GitHub repository.

sudo curl -L https://github.com/docker/compose/releases/download/1.23.2/docker-compose-`uname -s`-`uname -m` -o /usr/local/bin/docker-compose

Set correct permissions.

sudo chmod +x /usr/local/bin/docker-compose

Test the installation

docker-compose --version
Output
docker-compose version 1.23.2, build 1110ad01

Now Docker Compose is installed successfully and you can start running containers.

Use Docker Compose

Docker Compose allows you to use YAML file to define multiple container applications. With the YAML file you can run, build and configure all containers.

Create a project directory and navigate inside that directory.

mkdir my-project
cd my-project

Create a YAML file. This is a basic example of the yaml file for hello world .

sudo nano docker-compose.yml

Paste the following contents and save the file.

my-test:
image: hello-world

Hit Ctrl + X followed by Y and Enter to save the file and exit.

Now you can execute the following command to pull the hello word image from Docker Hub.

docker-compose up

You will receive an output similar to this.

Output
Pulling my-test (hello-world:)…
latest: Pulling from library/hello-world
1b930d010525: Pull complete
Creating my-project_my-test_1 … done
Attaching to my-project_my-test_1
my-test_1 |
my-test_1 | Hello from Docker!
my-test_1 | This message shows that your installation appears to be working correctly.
my-test_1 |
my-test_1 | To generate this message, Docker took the following steps:
my-test_1 | 1. The Docker client contacted the Docker daemon.
my-test_1 | 2. The Docker daemon pulled the "hello-world" image from the Docker Hub.
my-test_1 | (amd64)
my-test_1 | 3. The Docker daemon created a new container from that image which runs the
my-test_1 | executable that produces the output you are currently reading.
my-test_1 | 4. The Docker daemon streamed that output to the Docker client, which sent it
my-test_1 | to your terminal.
my-test_1 |
my-test_1 | To try something more ambitious, you can run an Ubuntu container with:
my-test_1 | $ docker run -it ubuntu bash
my-test_1 |
my-test_1 | Share images, automate workflows, and more with a free Docker ID:
my-test_1 | https://hub.docker.com/
my-test_1 |
my-test_1 | For more examples and ideas, visit:
my-test_1 | https://docs.docker.com/get-started/
my-test_1 |
my-project_my-test_1 exited with code 0

Now the hello-world image is pulled from Docker Hub and docker-compose creates a container, attaches and runs the program.

You can see all the containers using the following command.

docker ps -a
Output
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
f697e5990246 hello-world "/hello" 43 seconds ago Exited (0) 41 seconds ago my-project_my-test_1

Alright, Done! Now you have installed Docker Compose in your Ubuntu Server.

Tags: Compute EngineDockerGoogle Cloud Platform
ShareTweetSendShare
Cloudbooklet

Cloudbooklet

Help us grow and support our blog! Your contribution can make a real difference in providing valuable content to our readers. Join us in our journey by supporting our blog today!
Buy me a Coffee

Related Posts

Set Up Deep Learning with Nvidia, Cuda, cuDNN on Ubuntu

How to Set Up Deep Learning with Nvidia, CUDA, cuDNN on Ubuntu 22.04

May 27, 2023
How to Install or Upgrade PHP 8.2 on Ubuntu 22.04

How to Install or Upgrade PHP 8.2 on Ubuntu 22.04

April 13, 2023
How to Change Timezone on Ubuntu 22.04

How to Change Timezone on Ubuntu 22.04

May 16, 2023
How to Install Ansible on Ubuntu 22.04

How to Install Ansible on Ubuntu 22.04

May 19, 2023

Leave a Reply Cancel reply

Your email address will not be published. Required fields are marked *

I agree to the Terms & Conditions and Privacy Policy.

  • Trending
  • Comments
  • Latest
DragGAN The AI-Powered Image Editing Tool

DragGAN: The AI-Powered Image Editing Tool That Makes Editing Images Easy

May 30, 2023
DragGAN AI editing Tool Install and Use DragGAN Photo Editor

DragGAN AI editing Tool Install and Use DragGAN Photo Editor

May 27, 2023
Bard API key

Everything You Need to Know About Google’s Bard API Key

May 20, 2023
Install PHP 8.1 on Ubuntu

How to Install or Upgrade PHP 8.1 on Ubuntu 20.04

May 17, 2023
DragGAN The AI-Powered Image Editing Tool

DragGAN: The AI-Powered Image Editing Tool That Makes Editing Images Easy

75
Upgrade PHP version to PHP 7.4 on Ubuntu

Upgrade PHP version to PHP 7.4 on Ubuntu

28
Install Odoo 13 on Ubuntu 18.04 with Nginx - Google Cloud

Install Odoo 13 on Ubuntu 18.04 with Nginx – Google Cloud

25
Best Performance WordPress with Google Cloud CDN and Load Balancing

Best Performance WordPress with Google Cloud CDN and Load Balancing

23
How to Setup SSH Keys on Ubuntu

How to Setup SSH Keys on Ubuntu 20.04

May 31, 2023
ChatGPT app

The Easiest Way to Download ChatGPT App Free

May 31, 2023
LLM Connected with APIs

Gorilla: LLM Connected with APIs

May 31, 2023
Soundstorm-Pytorch

Soundstorm-Pytorch: A Powerful Tool for Audio Generation

May 30, 2023

Popular Articles

  • DragGAN The AI-Powered Image Editing Tool

    DragGAN: The AI-Powered Image Editing Tool That Makes Editing Images Easy

    1442 shares
    Share 577 Tweet 361
  • DragGAN AI editing Tool Install and Use DragGAN Photo Editor

    337 shares
    Share 135 Tweet 84
  • Auto-Photoshop-Stable Diffusion-Plugin: A New Way to Create AI-Generated Images in Photoshop

    70 shares
    Share 28 Tweet 18
  • InternGPT: A New Way to Interact with ChatGPT

    54 shares
    Share 22 Tweet 14
  • Midjourney vs Adobe Firefly: A Comparison of Two AI Image Generation Tools

    11 shares
    Share 4 Tweet 3
Cloudbooklet

Welcome to our technology blog, where we explore the latest advancements in the field of artificial intelligence (AI) and how they are revolutionizing cloud computing. In this blog, we dive into the powerful capabilities of cloud platforms like Google Cloud Platform (GCP), Amazon Web Services (AWS), and Microsoft Azure, and how they are accelerating the adoption and deployment of AI solutions across various industries. Join us on this exciting journey as we explore the endless possibilities of AI and cloud computing.

  • About
  • Contact
  • Disclaimer
  • Privacy Policy

Cloudbooklet © 2023 All rights reserved.

No Result
View All Result
  • News
  • Artificial Intelligence
  • Linux
  • Google Cloud
  • AWS

Cloudbooklet © 2023 All rights reserved.

This website uses cookies. By continuing to use this website you are giving consent to cookies being used. Visit our Privacy and Cookie Policy.