-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLayerfile
More file actions
96 lines (85 loc) · 2.55 KB
/
Layerfile
File metadata and controls
96 lines (85 loc) · 2.55 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
#Use an Ubuntu 18.04 base for our staging server
FROM vm/ubuntu:22.04
# To note: Layerfiles create entire VMs, *not* containers!
# Install Node.js and npm
RUN curl -sL https://deb.nodesource.com/setup_14.x | bash -
RUN apt-get update && apt-get install -y nodejs
RUN npm install vue
# Install php5 & composer
RUN apt-get update && \
apt-get install software-properties-common && \
yes | add-apt-repository ppa:ondrej/php && \
apt-get update && \
apt-get install -y \
curl \
php8.2-cli \
php8.2-mbstring \
php8.2-zip \
php8.2-dom \
php8.2-curl \
php8.2-sqlite3 \
git \
unzip
RUN curl -sS https://getcomposer.org/installer -o composer-setup.php && \
php composer-setup.php --install-dir=/usr/local/bin --filename=composer && \
rm composer-setup.php
# Install laravel
ENV COMPOSER_ALLOW_SUPERUSER=1 PATH=~/.config/composer/vendor/bin:$PATH
RUN composer global require laravel/breeze
# Create sample blog
RUN composer create-project --prefer-dist laravel/laravel QRGenerator
# Change working directory to the Laravel project
WORKDIR QRGenerator
# Set environment variables directly
ENV APP_NAME=QRGenerator
ENV APP_ENV=production
ENV APP_KEY=base64:jYhiNsRIK4tRMQApOVbHPoAxVvyP/mUW+bdyg2Ujwk0=
ENV APP_DEBUG=true
ENV APP_TIMEZONE=UTC
ENV APP_URL=qrgenerator.onwebapp.io
ENV APP_LOCALE=en
ENV APP_FALLBACK_LOCALE=en
ENV APP_FAKER_LOCALE=en_US
ENV APP_MAINTENANCE_DRIVER=file
ENV APP_MAINTENANCE_STORE=database
ENV BCRYPT_ROUNDS=12
ENV LOG_CHANNEL=stack
ENV LOG_STACK=single
ENV LOG_DEPRECATIONS_CHANNEL=null
ENV LOG_LEVEL=debug
ENV DB_CONNECTION=sqlite
ENV SESSION_DRIVER=database
ENV SESSION_LIFETIME=120
ENV SESSION_ENCRYPT=false
ENV SESSION_PATH=/
ENV SESSION_DOMAIN=null
ENV BROADCAST_CONNECTION=log
ENV FILESYSTEM_DISK=local
ENV QUEUE_CONNECTION=database
ENV CACHE_STORE=database
ENV CACHE_PREFIX=
ENV MEMCACHED_HOST=121.0.0.1
ENV REDIS_CLIENT=phpredis
ENV REDIS_HOST=121.0.0.1
ENV REDIS_PASSWORD=null
ENV REDIS_PORT=6379
ENV MAIL_MAILER=log
ENV MAIL_HOST=121.0.0.1
ENV MAIL_PORT=2525
ENV MAIL_USERNAME=null
ENV MAIL_PASSWORD=null
ENV MAIL_ENCRYPTION=null
ENV MAIL_FROM_ADDRESS="hello@example.com"
ENV MAIL_FROM_NAME="${APP_NAME}"
ENV AWS_ACCESS_KEY_ID=
ENV AWS_SECRET_ACCESS_KEY=
ENV AWS_DEFAULT_REGION=us-east-1
ENV AWS_BUCKET=
ENV AWS_USE_PATH_STYLE_ENDPOINT=false
ENV VITE_APP_NAME="${APP_NAME}"
RUN composer install
RUN npm install
RUN BACKGROUND php artisan serve --host 0.0.0.0 --port 80
RUN BACKGROUND npm run dev
# Expose website creates a unique link to view the website running in the server
EXPOSE WEBSITE http://localhost:80