Download Dockerfile from Opera8/Webtt: direct link, hf CLI and curl.
- Browser
- Download file 845 Bytes
-
https://huggingface.co/spaces/Opera8/Webtt/resolve/main/Dockerfile
- Command line
-
hf download hf://spaces/Opera8/Webtt/Dockerfile
-
curl -L -o Dockerfile https://huggingface.co/spaces/Opera8/Webtt/resolve/main/Dockerfile
845 Bytes
| FROM php:8.2-apache | |
| # نصب ابزارهای پایه و curl | |
| RUN apt-get update && apt-get install -y \ | |
| git \ | |
| libcurl4-openssl-dev \ | |
| pkg-config \ | |
| libssl-dev \ | |
| && docker-php-ext-install curl | |
| # پاک کردن فایلهای پیشفرض | |
| RUN rm -rf /var/www/html/* | |
| # کلون کردن کدهای شما (با استفاده از توکن مخفی) | |
| RUN --mount=type=secret,id=GITHUB_TOKEN,mode=0444,required=true \ | |
| git clone https://$(cat /run/secrets/GITHUB_TOKEN)@github.com/Hamed744/my-tts-website.git /var/www/html/ | |
| # تنظیم دسترسیها | |
| RUN chown -R www-data:www-data /var/www/html \ | |
| && chmod -R 755 /var/www/html | |
| # تنظیم پورت هاگینگ فیس | |
| RUN sed -i 's/80/7860/g' /etc/apache2/sites-available/000-default.conf /etc/apache2/ports.conf | |
| EXPOSE 7860 | |
| CMD ["apache2-foreground"] |