Dockerization of a sample demo php app

I am doing a trial of dockerization of a sample php application. i just created a sample laravel project and built a image for the sample app. The Dockerfile i used has

FROM php:8.0-cli 
RUN apt-get update -y && apt-get install -y libmcrypt-dev
RUN curl -sS | php -- --install-dir=/usr/local/bin --filename=composer
RUN docker-php-ext-install pdo
COPY . /app
RUN apt-get install zip -y
RUN composer update
RUN composer install
CMD php artisan serve --host --port 8000

And i used the cmd ‘’’ sudo docker run -it -p 8000:8000 containername ‘’’ but when i cant see the output in my browser


its not “containername” but “imagename”

what command did you use to build this image?

what does “docker logs CONTAINERNAME” provide?