Jump to content
MakeWebGames

Samurai Legend

Members
  • Posts

    483
  • Joined

  • Last visited

  • Days Won

    5

Samurai Legend last won the day on February 6

Samurai Legend had the most liked content!

1 Follower

About Samurai Legend

  • Birthday 04/09/1999

Personal Information

  • Website
    https://samuraiconflict.com

Recent Profile Visitors

14,488 profile views

Samurai Legend's Achievements

Enthusiast

Enthusiast (6/14)

  • Reacting Well Rare
  • Dedicated Rare
  • Conversation Starter Rare
  • First Post Rare
  • Collaborator Rare

Recent Badges

32

Reputation

  1. Figured it out. I didn’t need the docker compose watch. I just had to set up a few settings in PHPStorm for Docker. Then expose Vites port as npm run dev was not working and I was using npm run build. Thanks everyone!
  2. Anyone can help? @Magictallguy I've used PHPStorm to connect to Docker. The files now update in the container when editing files. However, the new changes don't show on the browser?
  3. Thanks @Magictallguyfor the help. Been bombarding you with annoyance I still get this error? [+] Running 3/0 ✔ Container app Running 0.0s ✔ Container mysql Running 0.0s ✔ Container nginx Running 0.0s none of the selected services is configured for watch, consider setting an 'develop' section Also can I not add this to the composer file somehow without to manually doing it? - docker-compose exec app php artisan key:generate docker-compose exec app php artisan migrate docker-compose exec app php npm install docker-compose exec app php npm run build Furthermore, if I close or delete the container do I loose the MySQL data? What would be the best way to store MySQL Queries?
  4. Id use a database, either cross the number out or highlight it
  5. @Magictallguy- Thanks, I have run the command but it says "Add watch sections to one or more services in compose.yaml" Also, all of these errors come up for the MySQL now? mysql | 2025-01-26 19:07:17+00:00 [Note] [Entrypoint]: Initializing database files mysql | 2025-01-26T19:07:17.032867Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). mysql | 2025-01-26T19:07:17.214593Z 0 [Warning] InnoDB: New log files created, LSN=45790 mysql | 2025-01-26T19:07:17.255496Z 0 [Warning] InnoDB: Creating foreign key constraint system tables. mysql | 2025-01-26T19:07:17.264169Z 0 [Warning] No existing UUID has been found, so we assume that this is the first time that this server has been started. Generating a new UUID: c285af2f-dc18-11ef-836c-0242ac120002. mysql | 2025-01-26T19:07:17.266986Z 0 [Warning] Gtid table is not ready to be used. Table 'mysql.gtid_executed' cannot be opened. mysql | 2025-01-26T19:07:17.361986Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher. mysql | 2025-01-26T19:07:17.362031Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher. mysql | 2025-01-26T19:07:17.363000Z 0 [Warning] CA certificate ca.pem is self signed. mysql | 2025-01-26T19:07:17.395675Z 1 [Warning] root@localhost is created with an empty password ! Please consider switching off the --initialize-insecure option. mysql | 2025-01-26 19:07:20+00:00 [Note] [Entrypoint]: Database files initialized mysql | 2025-01-26 19:07:20+00:00 [Note] [Entrypoint]: Starting temporary server mysql | 2025-01-26 19:07:20+00:00 [Note] [Entrypoint]: Waiting for server startup mysql | 2025-01-26T19:07:20.376701Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). mysql | 2025-01-26T19:07:20.377872Z 0 [Note] mysqld (mysqld 5.7.44) starting as process 125 ... mysql | 2025-01-26T19:07:20.381943Z 0 [Note] InnoDB: PUNCH HOLE support available mysql | 2025-01-26T19:07:20.382003Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins mysql | 2025-01-26T19:07:20.382013Z 0 [Note] InnoDB: Uses event mutexes mysql | 2025-01-26T19:07:20.382020Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier mysql | 2025-01-26T19:07:20.382026Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.13 mysql | 2025-01-26T19:07:20.382033Z 0 [Note] InnoDB: Using Linux native AIO mysql | 2025-01-26T19:07:20.382421Z 0 [Note] InnoDB: Number of pools: 1 mysql | 2025-01-26T19:07:20.382539Z 0 [Note] InnoDB: Using CPU crc32 instructions mysql | 2025-01-26T19:07:20.384671Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M mysql | 2025-01-26T19:07:20.396731Z 0 [Note] InnoDB: Completed initialization of buffer pool mysql | 2025-01-26T19:07:20.399286Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority(). mysql | 2025-01-26T19:07:20.411215Z 0 [Note] InnoDB: Highest supported file format is Barracuda. mysql | 2025-01-26T19:07:20.428149Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables mysql | 2025-01-26T19:07:20.428239Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ... mysql | 2025-01-26T19:07:20.491270Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB. mysql | 2025-01-26T19:07:20.494330Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active. mysql | 2025-01-26T19:07:20.494414Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active. mysql | 2025-01-26T19:07:20.497249Z 0 [Note] InnoDB: 5.7.44 started; log sequence number 2768291 mysql | 2025-01-26T19:07:20.497917Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool mysql | 2025-01-26T19:07:20.499768Z 0 [Note] Plugin 'FEDERATED' is disabled. mysql | 2025-01-26T19:07:20.505304Z 0 [Note] InnoDB: Buffer pool(s) load completed at 250126 19:07:20 mysql | 2025-01-26T19:07:20.521170Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them. mysql | 2025-01-26T19:07:20.521220Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory. mysql | 2025-01-26T19:07:20.521227Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher. mysql | 2025-01-26T19:07:20.521229Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher. mysql | 2025-01-26T19:07:20.528780Z 0 [Warning] CA certificate ca.pem is self signed. mysql | 2025-01-26T19:07:20.528945Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory. mysql | 2025-01-26T19:07:20.535829Z 0 [Warning] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory. mysql | 2025-01-26T19:07:20.545413Z 0 [Note] Event Scheduler: Loaded 0 events mysql | 2025-01-26T19:07:20.545823Z 0 [Note] mysqld: ready for connections. mysql | Version: '5.7.44' socket: '/var/run/mysqld/mysqld.sock' port: 0 MySQL Community Server (GPL) mysql | 2025-01-26 19:07:21+00:00 [Note] [Entrypoint]: Temporary server started. mysql | '/var/lib/mysql/mysql.sock' -> '/var/run/mysqld/mysqld.sock' mysql | 2025-01-26T19:07:21.277147Z 3 [Note] InnoDB: Stopping purge mysql | 2025-01-26T19:07:21.282037Z 3 [Note] InnoDB: Resuming purge mysql | 2025-01-26T19:07:21.284606Z 3 [Note] InnoDB: Stopping purge mysql | 2025-01-26T19:07:21.289144Z 3 [Note] InnoDB: Resuming purge mysql | 2025-01-26T19:07:21.292158Z 3 [Note] InnoDB: Stopping purge mysql | 2025-01-26T19:07:21.295776Z 3 [Note] InnoDB: Resuming purge mysql | 2025-01-26T19:07:21.298099Z 3 [Note] InnoDB: Stopping purge mysql | 2025-01-26T19:07:21.301883Z 3 [Note] InnoDB: Resuming purge mysql | Warning: Unable to load '/usr/share/zoneinfo/iso3166.tab' as time zone. Skipping it. mysql | Warning: Unable to load '/usr/share/zoneinfo/leapseconds' as time zone. Skipping it. mysql | Warning: Unable to load '/usr/share/zoneinfo/tzdata.zi' as time zone. Skipping it. mysql | Warning: Unable to load '/usr/share/zoneinfo/zone.tab' as time zone. Skipping it. mysql | Warning: Unable to load '/usr/share/zoneinfo/zone1970.tab' as time zone. Skipping it. mysql | 2025-01-26 19:07:23+00:00 [Note] [Entrypoint]: Creating database portfolio_db mysql | 2025-01-26 19:07:23+00:00 [Note] [Entrypoint]: Creating user portfolio_user mysql | 2025-01-26 19:07:23+00:00 [Note] [Entrypoint]: Giving user portfolio_user access to schema portfolio_db mysql | mysql | 2025-01-26 19:07:23+00:00 [Note] [Entrypoint]: Stopping temporary server mysql | 2025-01-26T19:07:23.828474Z 0 [Note] Giving 0 client threads a chance to die gracefully mysql | 2025-01-26T19:07:23.828520Z 0 [Note] Shutting down slave threads mysql | 2025-01-26T19:07:23.828524Z 0 [Note] Forcefully disconnecting 0 remaining clients mysql | 2025-01-26T19:07:23.828529Z 0 [Note] Event Scheduler: Purging the queue. 0 events mysql | 2025-01-26T19:07:23.828635Z 0 [Note] Binlog end mysql | 2025-01-26T19:07:23.829149Z 0 [Note] Shutting down plugin 'ngram' mysql | 2025-01-26T19:07:23.829189Z 0 [Note] Shutting down plugin 'partition' mysql | 2025-01-26T19:07:23.829194Z 0 [Note] Shutting down plugin 'BLACKHOLE' mysql | 2025-01-26T19:07:23.829198Z 0 [Note] Shutting down plugin 'ARCHIVE' mysql | 2025-01-26T19:07:23.829200Z 0 [Note] Shutting down plugin 'PERFORMANCE_SCHEMA' mysql | 2025-01-26T19:07:23.829232Z 0 [Note] Shutting down plugin 'MRG_MYISAM' mysql | 2025-01-26T19:07:23.829244Z 0 [Note] Shutting down plugin 'MyISAM' mysql | 2025-01-26T19:07:23.829253Z 0 [Note] Shutting down plugin 'INNODB_SYS_VIRTUAL' mysql | 2025-01-26T19:07:23.829257Z 0 [Note] Shutting down plugin 'INNODB_SYS_DATAFILES' mysql | 2025-01-26T19:07:23.829259Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESPACES' mysql | 2025-01-26T19:07:23.829262Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN_COLS' mysql | 2025-01-26T19:07:23.829264Z 0 [Note] Shutting down plugin 'INNODB_SYS_FOREIGN' mysql | 2025-01-26T19:07:23.829266Z 0 [Note] Shutting down plugin 'INNODB_SYS_FIELDS' mysql | 2025-01-26T19:07:23.829269Z 0 [Note] Shutting down plugin 'INNODB_SYS_COLUMNS' mysql | 2025-01-26T19:07:23.829271Z 0 [Note] Shutting down plugin 'INNODB_SYS_INDEXES' mysql | 2025-01-26T19:07:23.829274Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLESTATS' mysql | 2025-01-26T19:07:23.829276Z 0 [Note] Shutting down plugin 'INNODB_SYS_TABLES' mysql | 2025-01-26T19:07:23.829278Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_TABLE' mysql | 2025-01-26T19:07:23.829280Z 0 [Note] Shutting down plugin 'INNODB_FT_INDEX_CACHE' mysql | 2025-01-26T19:07:23.829282Z 0 [Note] Shutting down plugin 'INNODB_FT_CONFIG' mysql | 2025-01-26T19:07:23.829284Z 0 [Note] Shutting down plugin 'INNODB_FT_BEING_DELETED' mysql | 2025-01-26T19:07:23.829287Z 0 [Note] Shutting down plugin 'INNODB_FT_DELETED' mysql | 2025-01-26T19:07:23.829289Z 0 [Note] Shutting down plugin 'INNODB_FT_DEFAULT_STOPWORD' mysql | 2025-01-26T19:07:23.829291Z 0 [Note] Shutting down plugin 'INNODB_METRICS' mysql | 2025-01-26T19:07:23.829294Z 0 [Note] Shutting down plugin 'INNODB_TEMP_TABLE_INFO' mysql | 2025-01-26T19:07:23.829296Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_POOL_STATS' mysql | 2025-01-26T19:07:23.829298Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE_LRU' mysql | 2025-01-26T19:07:23.829301Z 0 [Note] Shutting down plugin 'INNODB_BUFFER_PAGE' mysql | 2025-01-26T19:07:23.829303Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX_RESET' mysql | 2025-01-26T19:07:23.829306Z 0 [Note] Shutting down plugin 'INNODB_CMP_PER_INDEX' mysql | 2025-01-26T19:07:23.829311Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM_RESET' mysql | 2025-01-26T19:07:23.829314Z 0 [Note] Shutting down plugin 'INNODB_CMPMEM' mysql | 2025-01-26T19:07:23.829320Z 0 [Note] Shutting down plugin 'INNODB_CMP_RESET' mysql | 2025-01-26T19:07:23.829323Z 0 [Note] Shutting down plugin 'INNODB_CMP' mysql | 2025-01-26T19:07:23.829326Z 0 [Note] Shutting down plugin 'INNODB_LOCK_WAITS' mysql | 2025-01-26T19:07:23.829328Z 0 [Note] Shutting down plugin 'INNODB_LOCKS' mysql | 2025-01-26T19:07:23.829331Z 0 [Note] Shutting down plugin 'INNODB_TRX' mysql | 2025-01-26T19:07:23.829333Z 0 [Note] Shutting down plugin 'InnoDB' mysql | 2025-01-26T19:07:23.829689Z 0 [Note] InnoDB: FTS optimize thread exiting. mysql | 2025-01-26T19:07:23.830377Z 0 [Note] InnoDB: Starting shutdown... mysql | 2025-01-26T19:07:23.931852Z 0 [Note] InnoDB: Dumping buffer pool(s) to /var/lib/mysql/ib_buffer_pool mysql | 2025-01-26T19:07:23.933136Z 0 [Note] InnoDB: Buffer pool(s) dump completed at 250126 19:07:23 mysql | 2025-01-26T19:07:25.366913Z 0 [Note] InnoDB: Shutdown completed; log sequence number 12219253 mysql | 2025-01-26T19:07:25.369823Z 0 [Note] InnoDB: Removed temporary tablespace data file: "ibtmp1" mysql | 2025-01-26T19:07:25.369879Z 0 [Note] Shutting down plugin 'MEMORY' mysql | 2025-01-26T19:07:25.369888Z 0 [Note] Shutting down plugin 'CSV' mysql | 2025-01-26T19:07:25.369895Z 0 [Note] Shutting down plugin 'sha256_password' mysql | 2025-01-26T19:07:25.369900Z 0 [Note] Shutting down plugin 'mysql_native_password' mysql | 2025-01-26T19:07:25.370056Z 0 [Note] Shutting down plugin 'binlog' mysql | 2025-01-26T19:07:25.370827Z 0 [Note] mysqld: Shutdown complete mysql | mysql | 2025-01-26 19:07:25+00:00 [Note] [Entrypoint]: Temporary server stopped mysql | mysql | 2025-01-26 19:07:25+00:00 [Note] [Entrypoint]: MySQL init process done. Ready for start up. mysql | mysql | 2025-01-26T19:07:26.018194Z 0 [Warning] TIMESTAMP with implicit DEFAULT value is deprecated. Please use --explicit_defaults_for_timestamp server option (see documentation for more details). mysql | 2025-01-26T19:07:26.019417Z 0 [Note] mysqld (mysqld 5.7.44) starting as process 1 ... mysql | 2025-01-26T19:07:26.023597Z 0 [Note] InnoDB: PUNCH HOLE support available mysql | 2025-01-26T19:07:26.023657Z 0 [Note] InnoDB: Mutexes and rw_locks use GCC atomic builtins mysql | 2025-01-26T19:07:26.023665Z 0 [Note] InnoDB: Uses event mutexes mysql | 2025-01-26T19:07:26.023669Z 0 [Note] InnoDB: GCC builtin __atomic_thread_fence() is used for memory barrier mysql | 2025-01-26T19:07:26.023673Z 0 [Note] InnoDB: Compressed tables use zlib 1.2.13 mysql | 2025-01-26T19:07:26.023677Z 0 [Note] InnoDB: Using Linux native AIO mysql | 2025-01-26T19:07:26.023978Z 0 [Note] InnoDB: Number of pools: 1 mysql | 2025-01-26T19:07:26.024119Z 0 [Note] InnoDB: Using CPU crc32 instructions mysql | 2025-01-26T19:07:26.026178Z 0 [Note] InnoDB: Initializing buffer pool, total size = 128M, instances = 1, chunk size = 128M mysql | 2025-01-26T19:07:26.047064Z 0 [Note] InnoDB: Completed initialization of buffer pool mysql | 2025-01-26T19:07:26.049674Z 0 [Note] InnoDB: If the mysqld execution user is authorized, page cleaner thread priority can be changed. See the man page of setpriority(). mysql | 2025-01-26T19:07:26.062422Z 0 [Note] InnoDB: Highest supported file format is Barracuda. mysql | 2025-01-26T19:07:26.074135Z 0 [Note] InnoDB: Creating shared tablespace for temporary tables mysql | 2025-01-26T19:07:26.074249Z 0 [Note] InnoDB: Setting file './ibtmp1' size to 12 MB. Physically writing the file full; Please wait ... mysql | 2025-01-26T19:07:26.105493Z 0 [Note] InnoDB: File './ibtmp1' size is now 12 MB. mysql | 2025-01-26T19:07:26.106706Z 0 [Note] InnoDB: 96 redo rollback segment(s) found. 96 redo rollback segment(s) are active. mysql | 2025-01-26T19:07:26.106766Z 0 [Note] InnoDB: 32 non-redo rollback segment(s) are active. mysql | 2025-01-26T19:07:26.107315Z 0 [Note] InnoDB: Waiting for purge to start mysql | 2025-01-26T19:07:26.158746Z 0 [Note] InnoDB: 5.7.44 started; log sequence number 12219253 mysql | 2025-01-26T19:07:26.159722Z 0 [Note] InnoDB: Loading buffer pool(s) from /var/lib/mysql/ib_buffer_pool mysql | 2025-01-26T19:07:26.160136Z 0 [Note] Plugin 'FEDERATED' is disabled. mysql | 2025-01-26T19:07:26.164595Z 0 [Note] InnoDB: Buffer pool(s) load completed at 250126 19:07:26 mysql | 2025-01-26T19:07:26.177693Z 0 [Note] Found ca.pem, server-cert.pem and server-key.pem in data directory. Trying to enable SSL support using them. mysql | 2025-01-26T19:07:26.177732Z 0 [Note] Skipping generation of SSL certificates as certificate files are present in data directory. mysql | 2025-01-26T19:07:26.177737Z 0 [Warning] A deprecated TLS version TLSv1 is enabled. Please use TLSv1.2 or higher. mysql | 2025-01-26T19:07:26.177739Z 0 [Warning] A deprecated TLS version TLSv1.1 is enabled. Please use TLSv1.2 or higher. mysql | 2025-01-26T19:07:26.178301Z 0 [Warning] CA certificate ca.pem is self signed. mysql | 2025-01-26T19:07:26.178372Z 0 [Note] Skipping generation of RSA key pair as key files are present in data directory. mysql | 2025-01-26T19:07:26.178780Z 0 [Note] Server hostname (bind-address): '*'; port: 3306 mysql | 2025-01-26T19:07:26.181165Z 0 [Note] IPv6 is available. mysql | 2025-01-26T19:07:26.181217Z 0 [Note] - '::' resolves to '::'; mysql | 2025-01-26T19:07:26.181233Z 0 [Note] Server socket created on IP: '::'. mysql | 2025-01-26T19:07:26.183418Z 0 [Warning] Insecure configuration for --pid-file: Location '/var/run/mysqld' in the path is accessible to all OS users. Consider choosing a different directory. mysql | 2025-01-26T19:07:26.190087Z 0 [Note] Event Scheduler: Loaded 0 events mysql | 2025-01-26T19:07:26.190540Z 0 [Note] mysqld: ready for connections. mysql | Version: '5.7.44' socket: '/var/run/mysqld/mysqld.sock' port: 3306 MySQL Community Server (GPL)
  6. I have finally got Docker to work but still need help. Dockerfile - FROM php:8.2-fpm # Copy composer.lock and composer.json COPY composer.lock composer.json /var/www/ # Set working directory WORKDIR /var/www/ # Install dependencies RUN apt-get update && apt-get install -y \ build-essential \ libpng-dev \ libjpeg62-turbo-dev \ libfreetype6-dev \ locales \ zip \ jpegoptim optipng pngquant gifsicle \ vim \ unzip \ git \ curl \ libonig-dev \ libzip-dev \ libgd-dev # Clear cache RUN apt-get clean && rm -rf /var/lib/apt/lists/* #NPM RUN apt-get update && apt-get upgrade -y && \ apt-get install -y nodejs \ npm # note this one # Install extensions RUN docker-php-ext-install pdo_mysql mbstring zip exif pcntl RUN docker-php-ext-configure gd --with-external-gd RUN docker-php-ext-install gd # Install composer RUN curl -sS https://getcomposer.org/installer | php -- --install-dir=/usr/local/bin --filename=composer # Add user for laravel application RUN groupadd -g 1000 www RUN useradd -u 1000 -ms /bin/bash -g www www # Copy existing application directory contents COPY . /var/www/ # Copy existing application directory permissions COPY --chown=www:www . /var/www/ # Change current user to www USER www # Expose port 9000 and start php-fpm server EXPOSE 9000 CMD ["php-fpm"] docker-compose.yml - services: # PHP service (for Laravel) php: build: context: . dockerfile: Dockerfile container_name: php volumes: - .:/var/www/ networks: - portfolio_network working_dir: /var/www/ # Nginx service nginx: image: nginx:latest container_name: nginx volumes: - ./:/var/www - ./nginx/:/etc/nginx/conf.d/ ports: - "80:80" depends_on: - php networks: - portfolio_network # MySQL service mysql: image: mysql:5.7 container_name: mysql environment: MYSQL_ROOT_PASSWORD: MySQLPass MYSQL_DATABASE: portfolio_db MYSQL_USER: portfolio_user MYSQL_PASSWORD: portfolio_password volumes: - mysql_data:/var/lib/mysql networks: - portfolio_network volumes: mysql_data: networks: portfolio_network: driver: bridge nginx/default.conf - server { listen 80; index index.php index.html; error_log /var/log/nginx/error.log; access_log /var/log/nginx/access.log; root /var/www/public; location ~ \.php$ { try_files $uri =404; fastcgi_split_path_info ^(.+\.php)(/.+)$; fastcgi_pass php:9000; fastcgi_index index.php; include fastcgi_params; fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name; fastcgi_param PATH_INFO $fastcgi_path_info; } location / { try_files $uri $uri/ /index.php?$query_string; gzip_static on; } } Now from my understanding. I have to run these commands below each time I want to start a container? docker-compose up --build docker-compose up docker-compose exec app chown -R www-data:www-data /var/www/storage /var/www/bootstrap/cache docker-compose exec php php artisan key:generate docker-compose exec php php npm install docker-compose exec php php npm run build Is there not a way to have them run while building the container? How do I edit the files in the container with PHPStorm? How do I exit the build? Are my files good to go? Or is there any improvements to be made
  7. I can’t seem to get it running lmao; it’s always throwing errors Can someone help me run Docker on my Mac? I just want to run a fresh Laravel Breeze project. Everything I do just always throws an error.
  8. @Magictallguythank you for your reply. I have taken everything in and hopefully will dive into new knowledge. I have a question for Docker. I use AlmaLinux for my web server. However, with Docker in one of the Docker Configurations it uses sudo apt-get wheres AlmaLinux uses sudo dnf. Just say in the future I do want to use Docker to deploy my site will it have any effect?
  9. What do you use to code and what can I do to have a better environment? OS: MacOS. Text Editor: PHPStorm Database Manager: Sequel Ace Laravel Valet to deploy my offline site Composer for dependency management Homebrew for installing packages locally Git: Gitlab to store my files and note along what is happening. It’s not a detailed explanation but if you’re understanding my environment and you think I could do better or maybe even teach me something new. Please let me know below As for Git I’d really like to manage and deploy my websites in an efficient way. I was researching but there isn’t much out there on this topic. So if you know where I am getting at and you can pitch please elaborate For an instance I’d have two branches Release: Code for live site Staging: Code for dev site Whenever, I am working on something on my site e.g a new login. I’d create a new branch called login. From there I’d commit and note each push. Whenever, I am complete I’d merge the branch with the Staging. After that I’d tag the Staging branch with eg. V1.2.4 and push tag to the Release branch. I’ve seen someone else’s work and this is how they manage it I believe however, remembering all of it was hard. I’d like to have something like this but setting it up and having an better understanding is what I need
  10. <template> <div class="min-h-full"> <Disclosure as="nav" class="bg-gray-800" v-slot="{ open }"> <div class="mx-auto max-w-7xl px-4 sm:px-6 lg:px-8"> <div class="flex h-16 items-center justify-between"> <div class="flex items-center"> <div class="shrink-0"> <img class="size-8" src="https://tailwindui.com/plus/img/logos/mark.svg?color=indigo&shade=500" alt="Site Logo" /> </div> <div class="hidden md:block"> <div class="ml-10 flex items-baseline space-x-4"> <Link v-if="$page.props.auth.user" v-for="item in authNavigation" :key="item.name" :href="item.href" :class="[item.current ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white', 'rounded-md px-3 py-2 text-sm font-medium']" :aria-current="item.current ? 'page' : undefined">{{ item.name }}</Link> <Link v-if="!$page.props.auth.user" v-for="item in navigation" :key="item.name" :href="item.href" :class="[item.current ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white', 'rounded-md px-3 py-2 text-sm font-medium']" :aria-current="item.current ? 'page' : undefined">{{ item.name }}</Link> </div> </div> </div> <div class="hidden md:block"> <div class="ml-4 flex items-center md:ml-6"> <button v-if="$page.props.auth.user" type="button" class="relative rounded-full bg-gray-800 p-1 text-gray-400 hover:text-white focus:outline-none focus:ring-2 focus:ring-white focus:ring-offset-2 focus:ring-offset-gray-800"> <span class="absolute -inset-1.5" /> <span class="sr-only">View notifications</span> <BellIcon class="size-6" aria-hidden="true" /> </button> <Menu v-if="$page.props.auth.user" as="div" class="relative ml-3"> <div> <MenuButton class="relative flex max-w-xs items-center rounded-full bg-gray-800 text-sm focus:outline-none focus:ring-2 focus:ring-white focus:ring-offset-2 focus:ring-offset-gray-800"> <span class="absolute -inset-1.5" /> <span class="sr-only">Open user menu</span> <img class="size-8 rounded-full" :src="user.imageUrl" alt="" /> </MenuButton> </div> <transition enter-active-class="transition ease-out duration-100" enter-from-class="transform opacity-0 scale-95" enter-to-class="transform opacity-100 scale-100" leave-active-class="transition ease-in duration-75" leave-from-class="transform opacity-100 scale-100" leave-to-class="transform opacity-0 scale-95"> <MenuItems class="absolute right-0 z-10 mt-2 w-48 origin-top-right rounded-md bg-white py-1 shadow-lg ring-1 ring-black/5 focus:outline-none"> <MenuItem v-for="item in userNavigation" :key="item.name" v-slot="{ active }"> <Link :href="item.href" :method="$item.method" :as="$item.as" :type="$item.type" :class="[active ? 'bg-gray-100 outline-none' : '', 'block px-4 py-2 text-sm text-gray-700']" >{{ item.name }}</Link> </MenuItem> </MenuItems> </transition> </Menu> </div> </div> <div class="-mr-2 flex md:hidden"> <!-- Mobile menu button --> <DisclosureButton class="relative inline-flex items-center justify-center rounded-md bg-gray-800 p-2 text-gray-400 hover:bg-gray-700 hover:text-white focus:outline-none focus:ring-2 focus:ring-white focus:ring-offset-2 focus:ring-offset-gray-800"> <span class="absolute -inset-0.5" /> <span class="sr-only">Open main menu</span> <Bars3Icon v-if="!open" class="block size-6" aria-hidden="true" /> <XMarkIcon v-else class="block size-6" aria-hidden="true" /> </DisclosureButton> </div> </div> </div> <DisclosurePanel class="md:hidden"> <div class="space-y-1 px-2 pb-3 pt-2 sm:px-3"> <DisclosureButton v-if="$page.props.auth.user" v-for="item in authNavigation" :key="item.name" as="a" :href="item.href" :class="[item.current ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white', 'block rounded-md px-3 py-2 text-base font-medium']" :aria-current="item.current ? 'page' : undefined">{{ item.name }}</DisclosureButton> <DisclosureButton v-if="!$page.props.auth.user" v-for="item in navigation" :key="item.name" as="a" :href="item.href" :class="[item.current ? 'bg-gray-900 text-white' : 'text-gray-300 hover:bg-gray-700 hover:text-white', 'block rounded-md px-3 py-2 text-base font-medium']" :aria-current="item.current ? 'page' : undefined">{{ item.name }}</DisclosureButton> </div> <div v-if="$page.props.auth.user" class="border-t border-gray-700 pb-3 pt-4"> <div class="flex items-center px-5"> <div class="shrink-0"> <img class="size-10 rounded-full" :src="user.imageUrl" alt="" /> </div> <div class="ml-3"> <div class="text-base/5 font-medium text-white">{{ $page.props.auth.user.name }}</div> <div class="text-sm font-medium text-gray-400">{{ $page.props.auth.user.email }}</div> </div> <button type="button" class="relative ml-auto shrink-0 rounded-full bg-gray-800 p-1 text-gray-400 hover:text-white focus:outline-none focus:ring-2 focus:ring-white focus:ring-offset-2 focus:ring-offset-gray-800"> <span class="absolute -inset-1.5" /> <span class="sr-only">View notifications</span> <BellIcon class="size-6" aria-hidden="true" /> </button> </div> <div v-if="$page.props.auth.user" class="mt-3 space-y-1 px-2"> <DisclosureButton v-for="item in userNavigation" :key="item.name" as="a" :href="item.href" class="block rounded-md px-3 py-2 text-base font-medium text-gray-400 hover:bg-gray-700 hover:text-white">{{ item.name }}</DisclosureButton> </div> </div> </DisclosurePanel> </Disclosure> <header class="bg-white shadow"> </header> <main> <div class="mx-auto max-w-7xl px-4 py-6 sm:px-6 lg:px-8"> <slot></slot> </div> <footer class="bg-white rounded-lg shadow dark:bg-gray-900 m-4"> <div class="w-full max-w-screen-xl mx-auto p-4 md:py-8"> <div class="sm:flex sm:items-center sm:justify-between"> <a href="https://flowbite.com/" class="flex items-center mb-4 sm:mb-0 space-x-3 rtl:space-x-reverse"> <img src="https://flowbite.com/docs/images/logo.svg" class="h-8" alt="Flowbite Logo" /> <span class="self-center text-2xl font-semibold whitespace-nowrap dark:text-white">Flowbite</span> </a> <ul class="flex flex-wrap items-center mb-6 text-sm font-medium text-gray-500 sm:mb-0 dark:text-gray-400"> <li> <a href="#" class="hover:underline me-4 md:me-6">About</a> </li> <li> <a href="#" class="hover:underline me-4 md:me-6">Privacy Policy</a> </li> <li> <a href="#" class="hover:underline me-4 md:me-6">Licensing</a> </li> <li> <a href="#" class="hover:underline">Contact</a> </li> </ul> </div> <hr class="my-6 border-gray-200 sm:mx-auto dark:border-gray-700 lg:my-8" /> <span class="block text-sm text-gray-500 sm:text-center dark:text-gray-400">© 2023 <a href="https://flowbite.com/" class="hover:underline">Flowbite™</a>. All Rights Reserved.</span> </div> </footer> </main> </div> </template> <script setup> import { Disclosure, DisclosureButton, DisclosurePanel, Menu, MenuButton, MenuItem, MenuItems } from '@headlessui/vue' import { Bars3Icon, BellIcon, XMarkIcon } from '@heroicons/vue/24/outline' const user = { name: 'Tom Cook', email: '[email protected]', imageUrl: 'https://images.unsplash.com/photo-1472099645785-5658abf4ff4e?ixlib=rb-1.2.1&ixid=eyJhcHBfaWQiOjEyMDd9&auto=format&fit=facearea&facepad=2&w=256&h=256&q=80', } const navigation = [ { name: 'Home', href: '/'}, { name: 'About', href: '/about'}, { name: 'Login', href: '/login'}, { name: 'Register', href: '/register'}, ] const authNavigation = [ { name: 'Home', href: '/'}, { name: 'About', href: '/about'}, ] const userNavigation = [ { name: 'Your Profile', href: '#' }, { name: 'Settings', href: '#' }, { name: 'Logout', href: '/logout', method: "post", as: "button", type: "button" }, ] </script> const userNavigation = [ { name: 'Your Profile', href: '#' }, { name: 'Settings', href: '#' }, { name: 'Logout', href: '/logout', method: "post", as: "button", type: "button" }, ] <MenuItem v-for="item in userNavigation" :key="item.name" v-slot="{ active }"> <Link :href="route('{item.href}')" :method="$item.method" :as="$item.as" :type="$item.type" :class="[active ? 'bg-gray-100 outline-none' : '', 'block px-4 py-2 text-sm text-gray-700']" >{{ item.name }}</Link> </MenuItem> I've tried adding in a log out link which requires a POST method. Now I am using a const to create my navigation so I've tried doing this and it does not display an error. The menu pop up doesn't happen
  11. The problems I do not remember and it was way too confusing. Thank you for your response. I was told by someone else about a year ago to use Slim. I am now looking into Slim and I have come across detailed videos of Slim as well as blogs. By my understanding Slim seems to be something which I can work with and benefit from. How would you recommend me to go with Slim? Tips to start off my journey and what I should focus on. Best way to connect to a database What can I pair Slim with? e.g. Twig, JavaScript framework, maybe a SPA? Or maybe not I was thinking using Slims Skeleton and adding a database migration (Phoenix or Phinx) as I believe there isn't one. I know this isn’t require. From there I’ll create an authentication system (login & register) Then start off with a home page.
  12. Hello everyone! Hope all is well with you all. I previously was planning to recreate my old project Samurai Assault. I was wondering what framework would you guys use and why? I wanted to go with Laravel, Inertia and VueJS however, someone pointed out Inertia was a headache to work with. I do want to proceed using Laravel as I believe that will boost my credentials within a career in Web Development. However, Inertia and Vue I am not to sure. So other than Inertia and Vue I believe the best alternative are either just using the default blade system, Splade (Which also uses Vue) or Livewire (Which I know nothing about). What are your thoughts?
  13. Laravel Valet
  14. That's amazing aha! I am currently working on a Laravel Inertia Vue project. Hopefully, soon I shall be able to release to the public. But your work looks amazing + 1
  15. There are few things changed when I get home I’ll change it to standard MCCodes for it to work
×
×
  • Create New...