#docker ps
Explore tagged Tumblr posts
matchasquid · 2 years ago
Text
Attention Splatoon Artists!!
I'm happy to announce that my Splatoon brushes (v.2) bundle for Krita is available for download!!! (rbs are appreciated<3)
Tumblr media
This bundle includes new and reworked brushes (from the previous version), focused on imitating the official art style of the Splatoon series' artworks.
Here's a brief rundown of the brushes:
Tumblr media
Download Link:
How to install them:
Download the .bundle file from the Google Drive link, and place it wherever you want on your computer
Tumblr media
2. Open Krita and go to Settings > Manage Resource Libraries
Tumblr media
3. On the Manage Resource Libraries window, click the Import button and select the .bundle file on the file explorer
Tumblr media
4. Once you finish the last step, you should see the bundle is now on your Manage Resource Libraries window
Tumblr media
5. Now, restart Krita and open a new file. The brushes should be on your Brush Presets docker!! (If you can't find them for whatever reason, just search "Splatoon" on the docker and the brushes should appear.)
Tumblr media
"But Matcha, how good are they??" Well, that obviously depends on your drawing/painting skills and familiarity with the brushes, but here are some comparisons:
Tumblr media Tumblr media
On both of these I traced the official artworks and tried my best to replicate the paintings, using only my brushes. You can decide if these are to your liking or not :p
Anyway, thank you for the attention and good luck making beautiful art <3
Ps: If you do use them, don't be afraid to tag me! I'd love to see you art :D
217 notes · View notes
debian-official · 3 days ago
Note
what flags do you use for ls
usually none, -la when things are going wrong.
Used to use the alias la but I've not gotten around to standardizing bashrc or whatever on all my systems so I'm not doing that anymore
(i really should go do that, i am in dire need of an alias for docker ps -a with only the useful stuff so I don't have to maximize the terminal to read anything lol)
4 notes · View notes
promptlyspeedyandroid · 17 days ago
Text
Docker Tutorial for Beginners: Learn Docker Step by Step
What is Docker?
Docker is an open-source platform that enables developers to automate the deployment of applications inside lightweight, portable containers. These containers include everything the application needs to run—code, runtime, system tools, libraries, and settings—so that it can work reliably in any environment.
Before Docker, developers faced the age-old problem: “It works on my machine!” Docker solves this by providing a consistent runtime environment across development, testing, and production.
Why Learn Docker?
Docker is used by organizations of all sizes to simplify software delivery and improve scalability. As more companies shift to microservices, cloud computing, and DevOps practices, Docker has become a must-have skill. Learning Docker helps you:
Package applications quickly and consistently
Deploy apps across different environments with confidence
Reduce system conflicts and configuration issues
Improve collaboration between development and operations teams
Work more effectively with modern cloud platforms like AWS, Azure, and GCP
Who Is This Docker Tutorial For?
This Docker tutorial is designed for absolute beginners. Whether you're a developer, system administrator, QA engineer, or DevOps enthusiast, you’ll find step-by-step instructions to help you:
Understand the basics of Docker
Install Docker on your machine
Create and manage Docker containers
Build custom Docker images
Use Docker commands and best practices
No prior knowledge of containers is required, but basic familiarity with the command line and a programming language (like Python, Java, or Node.js) will be helpful.
What You Will Learn: Step-by-Step Breakdown
1. Introduction to Docker
We start with the fundamentals. You’ll learn:
What Docker is and why it’s useful
The difference between containers and virtual machines
Key Docker components: Docker Engine, Docker Hub, Dockerfile, Docker Compose
2. Installing Docker
Next, we guide you through installing Docker on:
Windows
macOS
Linux
You’ll set up Docker Desktop or Docker CLI and run your first container using the hello-world image.
3. Working with Docker Images and Containers
You’ll explore:
How to pull images from Docker Hub
How to run containers using docker run
Inspecting containers with docker ps, docker inspect, and docker logs
Stopping and removing containers
4. Building Custom Docker Images
You’ll learn how to:
Write a Dockerfile
Use docker build to create a custom image
Add dependencies and environment variables
Optimize Docker images for performance
5. Docker Volumes and Networking
Understand how to:
Use volumes to persist data outside containers
Create custom networks for container communication
Link multiple containers (e.g., a Node.js app with a MongoDB container)
6. Docker Compose (Bonus Section)
Docker Compose lets you define multi-container applications. You’ll learn how to:
Write a docker-compose.yml file
Start multiple services with a single command
Manage application stacks easily
Real-World Examples Included
Throughout the tutorial, we use real-world examples to reinforce each concept. You’ll deploy a simple web application using Docker, connect it to a database, and scale services with Docker Compose.
Example Projects:
Dockerizing a static HTML website
Creating a REST API with Node.js and Express inside a container
Running a MySQL or MongoDB database container
Building a full-stack web app with Docker Compose
Best Practices and Tips
As you progress, you’ll also learn:
Naming conventions for containers and images
How to clean up unused images and containers
Tagging and pushing images to Docker Hub
Security basics when using Docker in production
What’s Next After This Tutorial?
After completing this Docker tutorial, you’ll be well-equipped to:
Use Docker in personal or professional projects
Learn Kubernetes and container orchestration
Apply Docker in CI/CD pipelines
Deploy containers to cloud platforms
Conclusion
Docker is an essential tool in the modern developer's toolbox. By learning Docker step by step in this beginner-friendly tutorial, you’ll gain the skills and confidence to build, deploy, and manage applications efficiently and consistently across different environments.
Whether you’re building simple web apps or complex microservices, Docker provides the flexibility, speed, and scalability needed for success. So dive in, follow along with the hands-on examples, and start your journey to mastering containerization with Docker tpoint-tech!
0 notes
souhaillaghchimdev · 2 months ago
Text
Using Docker in Software Development
Tumblr media
Docker has become a vital tool in modern software development. It allows developers to package applications with all their dependencies into lightweight, portable containers. Whether you're building web applications, APIs, or microservices, Docker can simplify development, testing, and deployment.
What is Docker?
Docker is an open-source platform that enables you to build, ship, and run applications inside containers. Containers are isolated environments that contain everything your app needs—code, libraries, configuration files, and more—ensuring consistent behavior across development and production.
Why Use Docker?
Consistency: Run your app the same way in every environment.
Isolation: Avoid dependency conflicts between projects.
Portability: Docker containers work on any system that supports Docker.
Scalability: Easily scale containerized apps using orchestration tools like Kubernetes.
Faster Development: Spin up and tear down environments quickly.
Basic Docker Concepts
Image: A snapshot of a container. Think of it like a blueprint.
Container: A running instance of an image.
Dockerfile: A text file with instructions to build an image.
Volume: A persistent data storage system for containers.
Docker Hub: A cloud-based registry for storing and sharing Docker images.
Example: Dockerizing a Simple Python App
Let’s say you have a Python app called app.py: # app.py print("Hello from Docker!")
Create a Dockerfile: # Dockerfile FROM python:3.10-slim COPY app.py . CMD ["python", "app.py"]
Then build and run your Docker container: docker build -t hello-docker . docker run hello-docker
This will print Hello from Docker! in your terminal.
Popular Use Cases
Running databases (MySQL, PostgreSQL, MongoDB)
Hosting development environments
CI/CD pipelines
Deploying microservices
Local testing for APIs and apps
Essential Docker Commands
docker build -t <name> . — Build an image from a Dockerfile
docker run <image> — Run a container from an image
docker ps — List running containers
docker stop <container_id> — Stop a running container
docker exec -it <container_id> bash — Access the container shell
Docker Compose
Docker Compose allows you to run multi-container apps easily. Define all your services in a single docker-compose.yml file and launch them with one command: version: '3' services: web: build: . ports: - "5000:5000" db: image: postgres
Start everything with:docker-compose up
Best Practices
Use lightweight base images (e.g., Alpine)
Keep your Dockerfiles clean and minimal
Ignore unnecessary files with .dockerignore
Use multi-stage builds for smaller images
Regularly clean up unused images and containers
Conclusion
Docker empowers developers to work smarter, not harder. It eliminates "it works on my machine" problems and simplifies the development lifecycle. Once you start using Docker, you'll wonder how you ever lived without it!
0 notes
learning-code-ficusoft · 4 months ago
Text
Using Docker for Full Stack Development and Deployment
Tumblr media
1. Introduction to Docker
What is Docker? Docker is an open-source platform that automates the deployment, scaling, and management of applications inside containers. A container packages your application and its dependencies, ensuring it runs consistently across different computing environments.
Containers vs Virtual Machines (VMs)
Containers are lightweight and use fewer resources than VMs because they share the host operating system’s kernel, while VMs simulate an entire operating system. Containers are more efficient and easier to deploy.
Docker containers provide faster startup times, less overhead, and portability across development, staging, and production environments.
Benefits of Docker in Full Stack Development
Portability: Docker ensures that your application runs the same way regardless of the environment (dev, test, or production).
Consistency: Developers can share Dockerfiles to create identical environments for different developers.
Scalability: Docker containers can be quickly replicated, allowing your application to scale horizontally without a lot of overhead.
Isolation: Docker containers provide isolated environments for each part of your application, ensuring that dependencies don’t conflict.
2. Setting Up Docker for Full Stack Applications
Installing Docker and Docker Compose
Docker can be installed on any system (Windows, macOS, Linux). Provide steps for installing Docker and Docker Compose (which simplifies multi-container management).
Commands:
docker --version to check the installed Docker version.
docker-compose --version to check the Docker Compose version.
Setting Up Project Structure
Organize your project into different directories (e.g., /frontend, /backend, /db).
Each service will have its own Dockerfile and configuration file for Docker Compose.
3. Creating Dockerfiles for Frontend and Backend
Dockerfile for the Frontend:
For a React/Angular app:
Dockerfile
FROM node:14 WORKDIR /app COPY package*.json ./ RUN npm install COPY . . EXPOSE 3000 CMD ["npm", "start"]
This Dockerfile installs Node.js dependencies, copies the application, exposes the appropriate port, and starts the server.
Dockerfile for the Backend:
For a Python Flask app
Dockerfile
FROM python:3.9 WORKDIR /app COPY requirements.txt . RUN pip install -r requirements.txt COPY . . EXPOSE 5000 CMD ["python", "app.py"]
For a Java Spring Boot app:
Dockerfile
FROM openjdk:11 WORKDIR /app COPY target/my-app.jar my-app.jar EXPOSE 8080 CMD ["java", "-jar", "my-app.jar"]
This Dockerfile installs the necessary dependencies, copies the code, exposes the necessary port, and runs the app.
4. Docker Compose for Multi-Container Applications
What is Docker Compose? Docker Compose is a tool for defining and running multi-container Docker applications. With a docker-compose.yml file, you can configure services, networks, and volumes.
docker-compose.yml Example:
yaml
version: "3" services: frontend: build: context: ./frontend ports: - "3000:3000" backend: build: context: ./backend ports: - "5000:5000" depends_on: - db db: image: postgres environment: POSTGRES_USER: user POSTGRES_PASSWORD: password POSTGRES_DB: mydb
This YAML file defines three services: frontend, backend, and a PostgreSQL database. It also sets up networking and environment variables.
5. Building and Running Docker Containers
Building Docker Images:
Use docker build -t <image_name> <path> to build images.
For example:
bash
docker build -t frontend ./frontend docker build -t backend ./backend
Running Containers:
You can run individual containers using docker run or use Docker Compose to start all services:
bash
docker-compose up
Use docker ps to list running containers, and docker logs <container_id> to check logs.
Stopping and Removing Containers:
Use docker stop <container_id> and docker rm <container_id> to stop and remove containers.
With Docker Compose: docker-compose down to stop and remove all services.
6. Dockerizing Databases
Running Databases in Docker:
You can easily run databases like PostgreSQL, MySQL, or MongoDB as Docker containers.
Example for PostgreSQL in docker-compose.yml:
yaml
db: image: postgres environment: POSTGRES_USER: user POSTGRES_PASSWORD: password POSTGRES_DB: mydb
Persistent Storage with Docker Volumes:
Use Docker volumes to persist database data even when containers are stopped or removed:
yaml
volumes: - db_data:/var/lib/postgresql/data
Define the volume at the bottom of the file:
yaml
volumes: db_data:
Connecting Backend to Databases:
Your backend services can access databases via Docker networking. In the backend service, refer to the database by its service name (e.g., db).
7. Continuous Integration and Deployment (CI/CD) with Docker
Setting Up a CI/CD Pipeline:
Use Docker in CI/CD pipelines to ensure consistency across environments.
Example: GitHub Actions or Jenkins pipeline using Docker to build and push images.
Example .github/workflows/docker.yml:
yaml
name: CI/CD Pipeline on: [push] jobs: build: runs-on: ubuntu-latest steps: - name: Checkout Code uses: actions/checkout@v2 - name: Build Docker Image run: docker build -t myapp . - name: Push Docker Image run: docker push myapp
Automating Deployment:
Once images are built and pushed to a Docker registry (e.g., Docker Hub, Amazon ECR), they can be pulled into your production or staging environment.
8. Scaling Applications with Docker
Docker Swarm for Orchestration:
Docker Swarm is a native clustering and orchestration tool for Docker. You can scale your services by specifying the number of replicas.
Example:
bash
docker service scale myapp=5
Kubernetes for Advanced Orchestration:
Kubernetes (K8s) is more complex but offers greater scalability and fault tolerance. It can manage Docker containers at scale.
Load Balancing and Service Discovery:
Use Docker Swarm or Kubernetes to automatically load balance traffic to different container replicas.
9. Best Practices
Optimizing Docker Images:
Use smaller base images (e.g., alpine images) to reduce image size.
Use multi-stage builds to avoid unnecessary dependencies in the final image.
Environment Variables and Secrets Management:
Store sensitive data like API keys or database credentials in Docker secrets or environment variables rather than hardcoding them.
Logging and Monitoring:
Use tools like Docker’s built-in logging drivers, or integrate with ELK stack (Elasticsearch, Logstash, Kibana) for advanced logging.
For monitoring, tools like Prometheus and Grafana can be used to track Docker container metrics.
10. Conclusion
Why Use Docker in Full Stack Development? Docker simplifies the management of complex full-stack applications by ensuring consistent environments across all stages of development. It also offers significant performance benefits and scalability options.
Recommendations:
Encourage users to integrate Docker with CI/CD pipelines for automated builds and deployment.
Mention the use of Docker for microservices architecture, enabling easy scaling and management of individual services.
WEBSITE: https://www.ficusoft.in/full-stack-developer-course-in-chennai/
0 notes
qcs01 · 6 months ago
Text
Podman for Beginners: Understanding Rootless Containers
In the fast-evolving world of containerization, Podman has emerged as a powerful, user-friendly, and secure alternative to Docker. One of its standout features is the support for rootless containers, which allows users to run containers without requiring elevated privileges. If you're new to Podman and curious about rootless containers, this guide is for you.
What is Podman?
Podman (Pod Manager) is an open-source container engine that enables users to create, manage, and run containers and pods. Unlike Docker, Podman operates without a central daemon, which enhances its security and flexibility.
What Are Rootless Containers?
Rootless containers allow users to run containers as non-root users. This significantly reduces security risks, as it minimizes the impact of potential vulnerabilities within containers. With rootless containers, even if a container is compromised, the damage is limited to the privileges of the user running it.
Benefits of Rootless Containers
Enhanced Security Rootless containers reduce the risk of privilege escalation, making them an ideal choice for running containers in development and production environments.
User-Specific Containers Each user can manage their container ecosystem independently, avoiding conflicts and ensuring isolation.
No Root Privileges Required Rootless containers eliminate the need for administrative access, making them safer for shared environments and CI/CD pipelines.
How to Get Started with Podman Rootless Containers
Step 1: Install Podman
Ensure you have Podman installed on your system. For most Linux distributions, you can install Podman using the package manager:
sudo apt install podman # For Debian-based systems sudo dnf install podman # For Fedora-based systems
Step 2: Verify Installation
Run the following command to check if Podman is installed correctly:
podman --version
Step 3: Create and Run a Rootless Container
Switch to a non-root user and run the following commands:
Pull an image:podman pull alpine
Run a container:podman run --rm -it alpine sh
This runs an Alpine Linux container in a rootless mode.
Step 4: Manage Containers
You can list running containers using:
podman ps
And stop a container using:
podman stop <container_id>
Limitations of Rootless Containers
While rootless containers are highly secure, there are some limitations:
Networking: Networking features may be restricted due to the lack of root privileges.
Performance: Certain operations may have slight performance overheads.
Compatibility: Not all container images or workloads are fully compatible with rootless containers.
When to Use Rootless Containers
Rootless containers are ideal for:
Development environments where security and isolation are essential.
CI/CD pipelines that don’t require root access.
Scenarios where multi-user isolation is necessary.
Conclusion
Podman’s rootless containers offer a seamless and secure way to work with containers, especially for users who value security and flexibility. By enabling rootless operations, Podman empowers developers to build and manage containers without compromising system integrity.
Ready to embrace rootless containers? Install Podman today and experience the future of containerization! 
For more details click www.hawkstack.com
#Podman #RootlessContainers #Containerization #DevOps #ContainerSecurity
0 notes
labexio · 10 months ago
Text
Understanding Docker Playground Online: Your Gateway to Containerization
In the ever-evolving world of software development, containerization has become a pivotal technology, allowing developers to create, deploy, and manage applications in isolated environments. Docker, a leader in this domain, has revolutionized how applications are built and run. For both novices and seasoned developers, mastering Docker is now essential, and one of the best ways to do this is by leveraging an Online Docker Playground. In this article, we will explore the benefits of using such a platform and delve into the Docker Command Line and Basic Docker Commands that form the foundation of containerization.
The Importance of Docker in Modern Development
Docker has gained immense popularity due to its ability to encapsulate applications and their dependencies into containers. These containers are lightweight, portable, and can run consistently across different computing environments, from a developer's local machine to production servers in the cloud. This consistency eliminates the "it works on my machine" problem, which has historically plagued developers.
As a developer, whether you are building microservices, deploying scalable applications, or managing a complex infrastructure, Docker is an indispensable tool. Understanding how to effectively use Docker begins with getting comfortable with the Docker Command Line Interface (CLI) and mastering the Basic Docker Commands.
Learning Docker with an Online Docker Playground
For beginners, diving into Docker can be daunting. The Docker ecosystem is vast, with numerous commands, options, and configurations to learn. This is where an Online Docker Playground comes in handy. An Online Docker Playground provides a sandbox environment where you can practice Docker commands without the need to install Docker locally on your machine. This is particularly useful for those who are just starting and want to experiment without worrying about configuring their local environment.
Using an Online Docker Playground offers several advantages:
Accessibility: You can access the playground from any device with an internet connection, making it easy to practice Docker commands anytime, anywhere.
No Installation Required: Skip the hassle of installing Docker and its dependencies on your local machine. The playground provides a ready-to-use environment.
Safe Experimentation: You can test commands and configurations in a risk-free environment without affecting your local system or production environment.
Immediate Feedback: The playground often includes interactive tutorials that provide instant feedback, helping you learn more effectively.
Getting Started with Docker Command Line
The Docker Command Line Interface (CLI) is the primary tool you'll use to interact with Docker. It's powerful, versatile, and allows you to manage your Docker containers and images with ease. The CLI is where you will issue commands to create, manage, and remove containers, among other tasks.
To begin, let's explore some Basic Docker Commands that you will frequently use in your journey to mastering Docker:
docker run: This command is used to create and start a new container from an image. For example, docker run hello-world pulls the "hello-world" image from Docker Hub and runs it in a new container.
docker ps: To see a list of running containers, use the docker ps command. To view all containers (running and stopped), you can add the -a flag: docker ps -a.
docker images: This command lists all the images stored locally on your machine. It shows details like the repository, tag, image ID, and creation date.
docker pull: To download an image from Docker Hub, use docker pull. For example, docker pull nginx fetches the latest version of the NGINX image from Docker Hub.
docker stop: To stop a running container, use docker stop [container_id]. Replace [container_id] with the actual ID or name of the container you want to stop.
docker rm: Once a container is stopped, you can remove it using docker rm [container_id].
docker rmi: If you want to delete an image from your local storage, use docker rmi [image_id].
Conclusion
Mastering Docker is a crucial skill for modern developers, and utilizing an Online Docker Playground is one of the most effective ways to get started. By practicing Docker Command Line usage and familiarizing yourself with Basic Docker Commands, you can gain the confidence needed to manage complex containerized environments. As you progress, you'll find that Docker not only simplifies the deployment process but also enhances the scalability and reliability of your applications. Dive into Docker today, and unlock the full potential of containerization in your development workflow.
0 notes
archaeopath · 1 year ago
Text
Updating a Tiny Tiny RSS install behind a reverse proxy
Tumblr media
Screenshot of my Tiny Tiny RSS install on May 7th 2024 after a long struggle with 502 errors. I had a hard time when trying to update my Tiny Tiny RSS instance running as Docker container behind Nginx as reverse proxy. I experienced a lot of nasty 502 errors because the container did not return proper data to Nginx. I fixed it in the following manner: First I deleted all the containers and images. I did it with docker rm -vf $(docker ps -aq) docker rmi -f $(docker images -aq) docker system prune -af Attention! This deletes all Docker images! Even those not related to Tiny Tiny RSS. No problem in my case. It only keeps the persistent volumes. If you want to keep other images you have to remove the Tiny Tiny RSS ones separately. The second issue is simple and not really one for me. The Tiny Tiny RSS docs still call Docker Compose with a hyphen: $ docker-compose version. This is not valid for up-to-date installs where the hyphen has to be omitted: $ docker compose version. The third and biggest issue is that the Git Tiny Tiny RSS repository for Docker Compose does not exist anymore. The files have to to be pulled from the master branch of the main repository https://git.tt-rss.org/fox/tt-rss.git/. The docker-compose.yml has to be changed afterwards since the one in the repository is for development purposes only. The PostgreSQL database is located in a persistent volume. It is not possible to install a newer PostgreSQL version over it. Therefore you have to edit the docker-compose.yml and change the database image image: postgres:15-alpine to image: postgres:12-alpine. And then the data in the PostgreSQL volume were owned by a user named 70. Change it to root. Now my Tiny Tiny RSS runs again as expected. Read the full article
0 notes
redactedconcepts · 1 year ago
Text
Docker
Readme
What is Docker and why is it popular?
Take note: The following instructions are run in a ubuntu-xenial virtual machine setup using Vagrant. To do the same, you can also install docker in any Vagrant virtual machine, or install docker on your host OS (Windows, Linux or Mac OS)
Let’s first pull a Docker image and run a container:
vagrant@ubuntu-xenial:~$ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES vagrant@ubuntu-xenial:~$ docker run -d -ti ubuntu:16.04 Unable to find image 'ubuntu:16.04' locally 16.04: Pulling from library/ubuntu 34667c7e4631: Pull complete d18d76a881a4: Pull complete 119c7358fbfc: Pull complete 2aaf13f3eff0: Pull complete Digest: sha256:58d0da8bc2f434983c6ca4713b08be00ff5586eb5cdff47bcde4b2e88fd40f88 Status: Downloaded newer image for ubuntu:16.04 e1fc0d4bbb5d3513b8f7666c91932812da7640346f6e05b7cfc3130ddbbb8278 vagrant@ubuntu-xenial:~$ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES e1fc0d4bbb5d ubuntu:16.04 "/bin/bash" About a minute ago Up About a minute keen_blackwell vagrant@ubuntu-xenial:~$
Note that docker command will pull the Ubuntu docker container image from the Internet and run it. I let you look at the meaning of the flags using the command docker run --help, the main idea is that it keeps the container up and running.
To execute a command on the Docker container, use docker exec:
vagrant@ubuntu-xenial:~$ docker exec -i e1fc0d4bbb5d hostname e1fc0d4bbb5d vagrant@ubuntu-xenial:~$ hostname ubuntu-xenial vagrant@ubuntu-xenial:~$
If you want to connect to your Docker container and use Bash, you need to use docker exec -ti:
vagrant@ubuntu-xenial:~$ docker exec -ti e1fc0d4bbb5d /bin/bash root@e1fc0d4bbb5d:/# echo "I am in $(hostname) Docker container" I am in e1fc0d4bbb5d Docker container root@e1fc0d4bbb5d:/# exit exit vagrant@ubuntu-xenial:~$
If you want to stop a container, use docker stop:
vagrant@ubuntu-xenial:~$ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES e1fc0d4bbb5d ubuntu:16.04 "/bin/bash" 5 minutes ago Up 5 minutes keen_blackwell vagrant@ubuntu-xenial:~$ docker stop e1fc0d4bbb5d e1fc0d4bbb5d vagrant@ubuntu-xenial:~$ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES vagrant@ubuntu-xenial:~$
0 notes
metricsviews · 1 year ago
Text
Docking Your Workflow: A Hands-On Guide to Docker Compose Installation and Examples
Tumblr media
What is docker-compose?
It is a tool which is used to create and start Docker application by using a single command.
It simplifies the deployment of complex applications by defining their architecture in a human-readable format.
This configuration file, typically written in YAML, outlines the services, networks, and volumes needed to run your application.
Docker Compose not only simplifies the management of containers but also encourages collaboration among developers and teams
Users can activate all the services (containers) using a single command.
Docker compose features
Purpose:Orchesrating multi-container application
Configuration:YAML base configuration
Scale:Multiple containers
Networking:Built-in networking and service discovery
Dependancy:Images and compose configuration
Ecosystem:Docker Hub and private registries
How to Install Docker Compose
Prerequisites:
Before installing Docker Compose, ensure that you have Docker installed on your system.
Installation Steps:
Check the Current Release:
Visit the Docker Compose GitHub release page to find the latest stable release. Identify the version number you want to install.
Download the Docker Compose Binary:
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
Tumblr media
Apply Executable Permissions:
Make the downloaded binary executable:
sudo chmod +x /usr/local/bin/docker-compose
Tumblr media
Verify Installation:
Confirm the successful installation by checking the version:
docker-compose –version
Tumblr media
Docker Compose Commands:
docker-compose build =Look for all services containing the build
docker-compose run=Run a one-time command against a service
docker-compose up=Command used to start all the services of the container.
docker Compose down=This syntax is used to stop all the services that were started.
docker-compose -f =Specify the location of a docker-compose configuration file by adding the -f flag
docker-compose start=Start existing containers for a service
docker_compose_v=To check the version of docker-compose, we use this command.
docker ps=This command is used to bring out the whole process of Docker.
docker Compose.yml=This command is used to configure application services using YAML files.
docker-compose up -d=Used to run a Docker-Compose file.
docker Compose up -d -scale=Used to scale the service of the container.
pip install -U Docker-compose= Command used to install Docker Compose using pip.
Compose step process
 1 Create a Directory
Creating the Dockerfile for the app environment
defining the services in docker-compose.yml
starting the application
Running Application using Docker Compose
Example:
Follow the following example
1) Create a Directory
mkdir docker-compose-praman
Tumblr media
2)Go to the directory
cd docker-composer-praman
Tumblr media
3) Define docker-compose.yml file
sudo vi docker-compose.yml
Tumblr media
let’s dismantle the above code and understand it by piece:
version: It refers to the docker-compose version (Latest 3)
services: It defines the services that we need to run
app: It is a custom name for one of your containers
image: The image which we have to pull. Here we are using node:latest and mongo
container_name:  It is the name for each container
restart: starts/restarts a service container
port: It defines the custom port to run the container
working_dir: It is the current working directory for the service container
environment: It defines the environment variables, such as DB credentials, and so on
command: It is the command to run the service
4)How to run the multi-container:
We need to build our multi-container using docker build.
docker-compose build  (Command to build the docker-compose.yml)
Tumblr media
docker-compose up  (Command to run multiple containers using docker-compose)
docker-compose up -d (Command to run multiple containers using docker-compose in detached mode)
Tumblr media
docker-compose ps  (Command to list the running container services)
Tumblr media
Sample output for running mongodb service using docker:
Tumblr media
Docker Compose Disadvantages:
Below are the drawbacks of Docker-Compose.
1.You have to spend more time and effort, installing Docker on your server.
2.Docker-Compose requires manual updates and fails when it comes to rebooting.
3.You have to spend more time and effort, installing Docker on your server.
4. However, docker-compose is already there in your system if you have installed   Docker.
 
Docker Compose Use Cases:
Automated testing environments-
Compose supports automated testing, which is an essential part of CI/CD as it can easily create and destroy the required testing environment
Single host deployments-
In Docker Compose, containers are designed to run on a single host as they have traditionally been focused on development and testing workflows.
Development Environments-
Compose is a fast and simple way of starting projects as it can quickly spin up new isolated development environments.
High productivity -
Docker-Compose increases productivity and reduces the time taken for each task
Security -
All the containers are isolated from each other, reducing the threat landscape
Configuration-
Docker-Compose files are written in YAML scripts hence, provide easy and quick configuration.
Credits - Sachin Auti (DevOps)
MetricsViews Pvt. Ltd.
MetricsViews specializes in building a solid DevOps strategy with cloud-native including AWS, GCP, Azure, Salesforce, and many more.  We excel in microservice adoption, CI/CD, Orchestration, and Provisioning of Infrastructure - with Smart DevOps tools like Terraform, and CloudFormation on the cloud.
www.metricsviews.com
0 notes
aoflima · 2 years ago
Text
Docker Cheatsheet Commands
List of all running and not running containers: docker container ps -a
Tumblr media
View On WordPress
0 notes
alexar60 · 3 years ago
Text
Au revoir
Tumblr media
Nul ne sait ce qui s’était passé ce matin-là.
Un docker arriva sur le quai et découvrit des milliers de chaussures posées au sol. Il inspecta le fleuve sans remarquer quoi que ce soit de suspect. Puis, il signala l’incident à sa direction. En nettoyant le quai, un apprenti découvrit un message dans chacune des chaussures gauches : « Au revoir ».
Le lendemain, alors que toutes les chaussures furent retirées, on découvrit plusieurs milliers de nouvelles chaussures. Elles étaient toutes de différents pointures, des grandes des petites, des chaussures pour adultes ou pour enfants. Et toutes les chaussures gauches contenaient un morceau de papier sur lequel était écrit le mot « au revoir ».
Inquiètes par ces constatations, les autorités ordonnèrent une enquête. Mais, comment savoir si c’était une blague ou un suicide collectif ? On posa des caméras rapidement sans résultat. Parce qu’elles s’éteignaient durant la nuit. Certains parlent de dysfonctionnement, d’autres de fantômes, mais toujours est-il qu’elles fonctionnaient au petit matin, offrant la triste vue de milliers de chaussures sur le quai. Et aucun corps retrouvé dans le fleuve.
L’affaire attira l’attention des médias. Alors, des personnes témoignèrent de la disparition d’un proche ; « on n’a plus de nouvelle d’un oncle ou d’une tante ». « Notre fille a disparu »… Les chaussures furent gardées pour être exposées dans un centre sportif et culturel. Quelques personnes reconnurent la chaussure d’un proche, sans conviction car elles se ressemblent toutes.
Durant les semaines suivantes, les chaussures continuèrent d’apparaitre. Une société de gardiennage fut appelée, des policiers réquisitionnés pour surveiller les quais. Seulement, le problème perdurait toujours. Les chaussures apparaissaient subitement pendant les pauses des services de sécurité. Une patrouille de police disparut aussi, laissant leur voiture garée au bord du port. L’inquiétude laissa place à la peur.
Encore maintenant, de nombreuses chaussures sont découvertes près du fleuve. Et toujours le même mot déposé dans celle de gauche : « Au revoir ».
Alex@r60 – juillet 2022
PS: Au revoir et à l’année prochaine pour un nouveau défi avec “30 jours pour écrire” !!!
31 notes · View notes
fashournalist · 5 years ago
Text
Thank you, Isentia Content Hub: An open letter to my colleagues.
Eleven days ago, it has exactly been two years since I first started working at Isentia. I remember feeling scared whether I’d belong, and what kind of people I’ll be working with. I remember I kept telling myself “Bawal maattach, Grace, as some alumni have said, when you enter the real world, you’re there to work. Just do your job well and be a team player, but don’t invest your emotions.” But here I am, after two years, with so many beautiful memories with amazing people. I did get attached after all, and it’s worth it. Because I did not only have colleagues, I met a new family.
Tumblr media
This was my open letter to Content Hub, which I hesitated to send at first after writing, because it’s too long. But thankfully, two of my teammates encouraged me to send it because they said what matters is I wrote it from my heart and it’s my farewell message to my friends. (I was one of the employees who got laid off.) It was here that I learned tears are really contagious, because after sending this letter, I received texts saying they shed a tear, too. Perhaps that’s because when I wrote it, I was shedding tears myself. Why do I feel like graduating from high school? Haha! I guess this is how close we have been. So here goes my letter, and pictures of some of the memories we have made. :)
Dear Content Hub,
This August 20, it has been exactly two years since I started working at Isentia. And now, 731 days and 41,283 summaries later, I just finished my last working day as a Broadcast Monitor. Permit me to be cheesy, I just want to thank the amazing people who made the past two years a memorable journey. I apologize in advance for the length of this email, but please know this letter came from my heart.
I'm really blessed that I got to work with you. I did not only have colleagues, I had a family. That is why whenever I reached the office, my update to my parents has always been "Happy place". It meant I arrived safely, I'm at OSMA already. And I know there have been hardships, times heartbreaking news crushed me, or times I went home way past my shift. Yet whenever I was on my home, no matter how tired I got, I just looked forward to facing the next day and working again. If world news were a play, we all get front row seats, binge-watching current events for at least 40 hours a week. It genuinely excited me that our job allows us to literally learn something new every day. But, I don't feel that way all the time; sometimes I just have burnouts and frustrations. So I think the real major reason that kept me going through it all is I had colleagues as supportive as you guys are. Allow me to thank you.
To Sydney Swans, my first team. 
Tumblr media
Working with helpful teammates like you added to my motivation as I traveled from LB to Ortigas every day for five months (when I was not yet able to find an apartment in Manila). Thank you for your devotion to Qld Premier Annastacia Palaszczuk. It showed me what client-obsessed looks like, and I committed to following that example. Your compere inside jokes and reactions to news added a lot of fun to our job. Until now, I enjoy backreading the group chat just to see your new musings or memes. Thanks a lot especially to John, Julianne, Zennon, Marco, and Kuya Ronnie.
To Fremantle Dockers, my afternoon shift team for more than a year, 
Tumblr media
Thank you for everything; for being supportive colleagues, helping me whenever I struggled, and celebrating with me whenever I improved. 
Tumblr media
Kuya Coily’s last day at our team.
Tumblr media
How we help one another, especially during the Christmas dinner just so everyone can go to Sambokojin on time, inspires me. This was our post-Sambo bonding at Greenfield. I am also relieved that you never judged me as “walang pakisama” even though I only drank iced tea or milkshake haha. Others tend to force me to drink, but my friends at Isentia just let me finish all the food. HAHA. I appreciate people who can respect our preferences and differences. And you are witnesses that I don’t need to drink to be drunk. Based on my energy, I am drunk by default. Haha I will miss all these sessions with you and my batchmates!
Tumblr media
I will miss our movie nights and billiard sessions (tho I'm just watching you haha) at the lounge. I wish we played more board games, too.
Tumblr media
Isentia Outing 2019
Thank you so much also for being there for me when I lost my mother, you had my back and that will always mean a lot to me. When my Momi was still alive, she always knew I was working with great people. Thank you to every single one of you especially AJ, Morris, Evann, Aly and Kuya Mel. 
Tumblr media
I look forward to a Dockers reunion when this pandemic is over! 
And my favorite teammate, Czesar. The best meetings are the ones you participated in. Thank you for all the laughter you gave us. 
I also want to thank my friends outside my team, including Tomie, Zendee, LA and Nico from Collingwood Magpies. 
Tumblr media
Thank you for the dinner sessions and conversations on life and dreams!
Tumblr media
This was LA’s birthday salubong at Kanto Breakfast :) While the next photo is a “panel discussion” at Goto Believe haha! We talked about the news we monitored, and boi, we went home at almost 5am.
Tumblr media
Tomie, thank you for our never-ending laughter on our way home. Normally, I just want to be quiet and regain energy while traveling, but with you, it's okay to chat all the way to Quiapo.
To my favourite comperes, who will not read this but I feel like thanking anyway because some of you might share love for them: Marc Fennell, Jan Fran, Kanoa Lloyd, Jules Schiller, Sonya Feldhoff, Anna Vidot, Dave Sutherland, Tamara Oudyn, Sammy J, Paul Barry, Jeremy Corbett, David Speers, Leigh Sales and my inspiration Jesse Mulligan. Thank you because I learned so much about the world and about life from you. I will miss blogging about your stories and reacting to your insights.
To the leaders who managed me and/or accommodated my concerns, 
Tumblr media
This is my former TL, Kuya Coily :)
TL Coily, TL Angel, TL Rem, TL Nico, TL Nic, TL Jonna, TL Geoff, TL Alni, and Sup Mitch. Thank you for all your help! Thank you for the times you inspired me and my colleagues to grow as well as the times you coached me, gave constructive feedback, and helped me overcome my weaknesses so I can continuously improve. 
To our Trainer Rachel, who we can consider as Content Hub's matriarch, 
Tumblr media
thank you so much because you patiently equipped every single one of us before we transitioned to live operations. To OM Dean, thank you for your feedback and praise during my regularisation.
And most of all, to Western Borlogs fam, my home for two years, I don't even know how to thank you enough. 
Tumblr media
I'm grateful you've been my batchmates at our training--and for everything after that. 
Tumblr media
Isentia Outing 2019
Tumblr media
Sibyullee, farewell samgyup party for Jai (her last day in the company)
Tumblr media
Seoulgyupsal, farewell samgyup party for Aiona (before she flew to Spain to teach)
Tumblr media
office memories :)
Tumblr media
Pantry catch-ups. I usually eat at my desk because of all the work but I’m grateful for the times I was able to join their dinner breaks hehe.
Tumblr media
Sambokojin, Christmas dinner 2019
Dear Borlogs, thank you for all the memories, endless laughter, samgyup sessions (a regular segment haha), Friday nights, and times we comforted each other when some of us are facing a hard time. Thank you also for comforting me and my family when you and B visited the wake of my Momi. She has always heard about you (and I'm happy she met some of you) when she was still alive. Thank you for being such a great sounding board, a safe space where we can be vulnerable and strong at the same time. Also, I've never been a milk tea person until I met you guys, so thanks for that, too. My BM experience would not be the same without you. Naz, Janelle, Joey, Patty, Billie, Lou, Aiona, Jai, Nee, Mau, C, Ady, Sarah. Thank you, sists!!
If you've read until here, thank you for bearing with my lengthy cheesy, farewell note to Content Hub. I attached some photos that captured a few of the memories I spent with you, as well as some jokes I've randomly thought about while monitoring. I was reserving them for Christmas Party or something, but anyway, here they are. I am confident they will make you cringe.
So there, I will miss you and I appreciate you always. I will not forget the memories we've made along the way. Thank you for everything, Isentia Content Hub! God bless you all and stay safe.
Arrivederci :)
Always,
Grace / Mariel
Tumblr media
(this was me when I graduated from training and was so excited to be part of Content Hub haha)
PS. Thank you to Janelle, Jai, Joey, Jai, Kuya Coily, LA, Zendee, Dots and Troy for the photos!
PPS. Thank you so much for your heartwarming replies!!! And the food/gifts some of you sent!! I love you guys. (There, I said it. Haha! I was too shy to put that sentence in the email I sent. But this is my blog, I can write what my heart says without holding back)
Tumblr media Tumblr media Tumblr media
^letter from AJ with a Bebi plant. She sent me oatmeal cookies and three novels too huehue she knows my weaknesses well haha thankuu ajj
Tumblr media Tumblr media Tumblr media Tumblr media Tumblr media Tumblr media
^Matchaaaa from Patty thank you sist! <33
Tumblr media Tumblr media Tumblr media
^Carbonaraaaa from Tomiee thank you siz!!!
Tumblr media Tumblr media Tumblr media Tumblr media Tumblr media Tumblr media Tumblr media
Thank you to every single one of you. I was emotional when I wrote the open letter, but I got more nostalgic when I read your responses. I will always be thankful for the privilege of working with you and being your friend. Keep in touch, okay? We’ll still meet again. :)
Love,
Grace
3 notes · View notes
hktime9 · 6 years ago
Text
“How to write better code?” asked a computer scientist-to-be
This is a question that I get once every 2 weeks (on average) mostly from my colleagues and friends who are studying the same degree for the same time as I. Why do they ask me? To be honest- I don’t know. What I also don’t know is the answer to their question. But I’d try to summarize what I think of the question. The answer to this question depends on many factors. If the questioner is a computer science major, I’d see what year they are in. Here’s my year to year advice to them:
- Freshman year: Coding at first is really intimidating. Its given that you’d spend hours in front of your screen to find that one line that does not compile. Here, you should remain patient and learn to accept that this problem demands a finite amount of time and focused concentration to overcome. Using online sources like stack overflow and GitHub are great options but never a first step if you want to become a decent coder. Go line by line and figure out what’s happening and whether it’s the right behavior. Freshman year includes a lot of programming labs, projects and assignments. Try to do all of them and start well before your deadline (seriously). Make it a habit to write a small program everyday. Could be a simple program to add two numbers or anything of that sort. Do some string operation or something. This would not only improve your algorithmic thinking, but also would polish the syntax of the language you code in. Like everything else in the world, mastery comes after practice. So hang in tight!
-Sophomore year: By now you have some experience of the life cycle of a typical program: understand the problem statement, do it on paper the way a human would do, do it on paper the way a computer would do, translate the latter to the programming language in question, debug. Now you also know some basics of computer science through some programming courses and maybe a few systems courses as well. The scope of your programming assignments should not be higher than maybe some array based tasks or implementing a few data structures like linked lists and binary trees to name a few. I’m assuming that you are completing your programming assignments religiously. If not, you really should be doing that before putting in extra work to improve your coding. I’ve seen people depending/copying on other people’s work even in individual assignments. While some might get away from plagiarism penalties and policies of your university, others face some sort of penalty (could be a grade reduction or something of that sort). While the latter might learn a lesson, the former fails to develop their skills and ultimately suffers in their professional life. So leaching on a friend is never a good option, well not in the long term. Try to do it even if you’re finding it hard. Take help from your teaching assistants and the rest of the course staff. You need to realize that these people are paid to help you. So please utilize office hours and appointments to the fullest. Doing extra always helps like attempting optional parts or the ones that give extra credits. Do some interesting problems and coding puzzles like the ones on hackerrank and leetcode. These are some excellent resources to polish up your skills as a developer and problem solver because they include some obvious metrics like completion, correctness and time. Have a study group where you can discuss your assignments and homeworks. There’s a difference between discussing and copying/leaching off. Mind that difference.
-Junior year: This is when you’re comfortable with programming in general. You know how it can be applied in a array of different tasks. You might have taken some old school courses like algorithms, databases and operating systems. PS I’m counting data structures as a programming intensive course and did not give it a special mention in the sophomore section :(. Go for some interesting courses like a networks course, AI/ ML or maybe some usability course. These courses will help you appreciate how you just cannot run away from programming. You’ll learn new approaches like socket programming and programming over a network (maybe some Remote Procedure Calls?). Go for some interesting applications. I remember developing a simple chatting application over a network during my junior year. I hosted it on the university’s network and anyone on the network could use it (if they knew the ip, obviously). I not only developed it, but also made it resistant to buffer overflows and scripting attacks(XSS) thanks to my roommate cum penetration tester. Once done with your Databases course, you can go for a full stack level by learning some server side and client side scripting. Learn some server based frameworks in javascript or anything. Look for some widely used frameworks; the ones which have a wider developer community. The community support will help you a lot, trust me. Some front end frameworks (client side) like ReactJS and VueJS are great these days. You can learn them using some MOOCS if your university doesn’t offer a course on them. Personally, Coursera is a great resource. Its super easy to use and has great customer care. Their “Full-Stack Web Development with React Specialization” offered by the Hong Kong University of Science and Technology is great. Once done you are fully capable to work as a full stack developer and the only thing stopping you is an internship offer from a company and time to practice. The latter can be achieved on your own, while the prior needs some homework and external networking. Connect to some local organization and CEOs on LinkedIn. Make sure you have a well maintained and updated LinkedIn profile and turn on recruiter discoveries to get recruiter in-mails. Be on the lookout for internship offerings and openings. Apply whenever you get a chance. Working on an organization’s project will help you learn a lot. It will not only improve your coding and problem solving stills, but also make you realize how important it is to work in teams. The latter is crucial to success in the industry since a project has multiple groups composed of many individuals. Be sure to take up work that is doable within the deadline. Keep a good relation with your supervisor and always ask for specific direction to get it right the first time.
Senior year: This has to be the most confusing year in-terms of future planning since graduation is approaching and life after is somewhat uncertain. Don’t let this fear of the uncertain get to you. My advice might not be very concrete because I, myself, am a senior while writing this. But I’ll try to incorporate my learning and findings here. The first question you might want to answer is whether coding is for you. This question is not presented before because there wasn’t an escape from it earlier because you had assignments that required you to code. Now that you can take up courses that need minimal programming effort like human-computer interaction and usability/planning courses you have a way out. These include courses like requirement engineering and planning. There are other examples as well which aren’t difficult to find. The answer to the question posed would not be a yes unless you completely love programming, in which case you’re on the right track. Loving programming is different from being good at it. You might love it and be bad at it and that’s completely fine in which case you should multiply your efforts to get better at it. Again, practice is the key. Try out programming courses on Coursera or some other platform. Get a github for student account. You’ll get it for free if you have an email account provided by your university. I’d like to make a special mention to Educative.io which offers a plethora of courses for free if you have a github for students. Educative.io is user friendly and keeps good track of your progress through the course. It is run by a very dedicated team. I personally know people working there who write articles and make courses. Almost all of them have worked as teaching assistants during their time at the university and most certainly know what they are doing and there work reflects their capabilites. They have some amazing courses. Do check it out if you have a github for students account. You’d also get free access to paid tools like AWS, Azure, DigitalOcean and Heroku. If the answer to the question is no, then you need to research more on courses and fields in computer science that do not require intense programming. These 3 years will definitely equip you with the skills that you need to do “some” coding that these fields demand. There wont be much but not zero at the same time. If you are still undecided about the question, you really should invest time knowing an answer. Ask your professors for help. Tell them honestly what you feel and why you can’t make a decision considering that you’ve spent considerable time doing it. They might guide you to a definitive answer. And then continue according to the answer. Now’s also a good time to look into industry’s standards and best practices. Maybe learn a new language? Or try using mainstream tools and familiarize yourself with devOps. Some of them are Docker, Jenkins, Slack, Jira, Git and many more, each with a set of its own unique features. Their knowledge and use will help you once you land a job because most organizations use them on a daily basis. Try some cloud computing platforms like the Amazon web services, Microsoft’s Azure and Google’s Cloud Platform. These platforms offer an array of services like storage, hosting and compute. Familiarize yourself with their usage because they usually have a learning curve. Do a lot of hobby coding. Try different approaches to a problem. For example I was going through geekforgeeks and came across an interesting problem which had a greedy solution and required an LCM (Least Common Multiple) of two numbers. The author had used a builtin function for computing it. I wondered if I could write it recursively. I decomposed the problem and found an optimal substructure which proved that a recursive solution should exist. I worked on it and wrote it and it worked. It was a mere 10 liner. Practice like the one mentioned will help you develop confidence while improving your coding skills. So practice writing code even if its not that intensive and long and hopefully you’ll see improvement.
This concludes my very first attempt that writing. I plan to write more and post here often. I’m eager to get feedback and comments. Here’s my LinkedIn profile. I really hope this helps the reader. Thank you for reading
41 notes · View notes
cloud2help-blog · 5 years ago
Text
How to Deploy LAMP Stack on Docker
In this article, we are going to see different ways to deploy Lamp Stack on Docker using Docker Compose as microservices. Docker-compose is a tool used to create docker containers and run multiple containers as single services.
Supposed if we create WordPress application we require apache/Nginx, PHP, and MySQL. You can create one file which can start both the containers as a service without the…
View On WordPress
0 notes
phulkor · 5 years ago
Text
Docker cheat sheet
List docker images
docker image ls
List docker process
docker ps
Remove a docker image
(use docker image)
docker rmi -f <image-id>
Build a docker image
docker build -t <repo-url>:5000/<image-name> .
Push a docker image to a docker repo
docker push <image-name-with-repo>:latest
Pull a docker image
docker pull <image-name-with-repo>:latest
Run a docker image with port mapping
docker run -d -p 8081:7777 <image-name>
Show docker image logs
(use docker ps)
docker logs -f <container-id>
Attach to a terminal inside docker image
docker exec -it <container-id> /bin/sh
Remove all images matching a given name
docker rmi $(docker images |grep 'imagename')
1 note · View note