Jump to content

spoetnik

Members
  • Content Count

    59
  • Joined

  • Last visited

Community Reputation

11 Good

About spoetnik

  • Rank
    Distinguished Member

Profile Information

  • Gender
    Male
  • Location
    Europe, the Netherlands

Recent Profile Visitors

The recent visitors block is disabled and is not being shown to other users.

  1. What would be needed to get this module to work with Processwire 3? I get the error 'FieldtypeRangeSlider: Default value should be in format [int,int]. (1,100) if range is checked'
  2. Here is my setup: My Dockerfile: # # PHP Dependencies # FROM composer:1.7 as vendor COPY web/ /app RUN composer install \ --ignore-platform-reqs \ --no-interaction \ --no-plugins \ --no-scripts \ --prefer-dist # # Frontend # FROM node:latest as frontend COPY --from=vendor /app /app WORKDIR /app/site/templates RUN npm install --global gulp-cli && \ npm --prefix /app/site/templates install gulp /app/site/templates && \ npm --prefix /app/site/templates install /app/site/templates && \ gulp build # # Application # FROM php:7.2.7-fpm-alpine COPY --from=frontend /app /var/www/html WORKDIR /var/www RUN apk add --update $PHPIZE_DEPS \ freetype-dev \ libjpeg-turbo-dev \ libpng-dev \ && docker-php-ext-install iconv pdo pdo_mysql mysqli opcache zip \ && docker-php-ext-configure gd --with-freetype-dir=/usr/include/ --with-jpeg-dir=/usr/include/ \ && docker-php-ext-install gd \ && rm -rf /var/cache/apk/* \ && chown -R www-data:www-data . # set recommended PHP.ini settings # see https://secure.php.net/manual/en/opcache.installation.php RUN { \ echo 'opcache.memory_consumption=128'; \ echo 'opcache.interned_strings_buffer=8'; \ echo 'opcache.max_accelerated_files=4000'; \ echo 'opcache.revalidate_freq=2'; \ echo 'opcache.fast_shutdown=1'; \ echo 'opcache.enable_cli=1'; \ } > /usr/local/etc/php/conf.d/opcache-recommended.ini \ My dev_docker-compose.yml: version: '3' services: web: image: nginx:alpine volumes: - ./etc/nginx/default.conf:/etc/nginx/conf.d/default.conf:delegated - ./etc/ssl:/etc/ssl:delegated - ./web:/var/www/html:delegated - ./etc/nginx/default.template.conf:/etc/nginx/conf.d/default.template:delegated - ./logs/nginx/:/var/log/nginx:cached ports: - "8000:80" - "3000:443" environment: - NGINX_HOST=${NGINX_HOST} command: /bin/sh -c "envsubst '$$NGINX_HOST' < /etc/nginx/conf.d/default.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'" restart: always depends_on: - php - mysqldb php: build: ./ image: app:latest restart: always environment: MYSQL_HOST: ${MARIADB_HOST} MYSQL_PORT: 3306 MYSQL_DATABASE: ${MARIADB_DATABASE} MYSQL_USER: ${MARIADB_USER} MYSQL_PASSWORD: ${MARIADB_PASSWORD} volumes: - ./etc/php/php.ini:/usr/local/etc/php/conf.d/php.ini - ./web:/var/www/html:delegated - ./assets:/var/www/html/site/assets:delegated composer: image: "composer" volumes: - ./web:/app command: install --ignore-platform-reqs myadmin: image: phpmyadmin/phpmyadmin container_name: phpmyadmin ports: - "8080:80" environment: - PMA_ARBITRARY=1 - PMA_HOST=${MARIADB_HOST} restart: always depends_on: - mysqldb mysqldb: image: mariadb:${MARIADB_VERSION} container_name: ${MARIADB_HOST} restart: always env_file: - ".env" environment: - MYSQL_DATABASE=${MARIADB_DATABASE} - MYSQL_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD} - MYSQL_USER=${MARIADB_USER} - MYSQL_PASSWORD=${MARIADB_PASSWORD} ports: - "8989:3306" volumes: - ./data/db/mysql:/var/lib/mysql:delegated my prod_docker-compose.yml version: '3' services: web: image: nginx:alpine volumes: - ./etc/nginx/default.conf:/etc/nginx/conf.d/default.conf - ./etc/ssl:/etc/ssl - ./etc/nginx/default.template.conf:/etc/nginx/conf.d/default.template - ./logs/nginx/:/var/log/nginx - webroot-volume:/var/www/html ports: - "80:80" - "443:443" environment: - NGINX_HOST=${NGINX_HOST} command: /bin/sh -c "envsubst '$$NGINX_HOST' < /etc/nginx/conf.d/default.template > /etc/nginx/conf.d/default.conf && nginx -g 'daemon off;'" restart: always depends_on: - php - mysqldb php: image: app:latest restart: always environment: MYSQL_HOST: ${MARIADB_HOST} MYSQL_PORT: 3306 MYSQL_DATABASE: ${MARIADB_DATABASE} MYSQL_USER: ${MARIADB_USER} MYSQL_PASSWORD: ${MARIADB_PASSWORD} volumes: - webroot-volume:/var/www/html - ./assets:/var/www/html/site/assets mysqldb: image: mariadb:${MARIADB_VERSION} container_name: ${MARIADB_HOST} restart: always env_file: - ".env" environment: - MYSQL_DATABASE=${MARIADB_DATABASE} - MYSQL_ROOT_PASSWORD=${MARIADB_ROOT_PASSWORD} - MYSQL_USER=${MARIADB_USER} - MYSQL_PASSWORD=${MARIADB_PASSWORD} volumes: - ./data/db/mysql:/var/lib/mysql volumes: webroot-volume:
  3. So, I have build a form, and I can call this in my template like: <?=AddPostForm/> After submitting this form, the data is passed to a function with all the input values to add the post. Where do you sanitize your data? Is that the responsibility of the form, before passing the data to the function, or do you expect the function to sanitize the data before handling it?
  4. Why?? Why not just php-fpm and nginx as a proxy? That's a more know architecture with blogs explaining the setup, and google-hits when it's not working...
  5. I am playing with the setup in a sandbox. Do I understand it right? For each private group, I create Role, and a Template. Then on the Temaplte of the Parentpage I set Role permissions, so only people in that Role (Group) can view and create Children? So Group -> Role -> Template Access?
  6. I was thinking about a page reference from the user's profile to a group-page, and restrict access by restricting all content by filtering on this reference in all selectors... Would that work?
  7. How would you handle this: A site with private groups. Only members of these groups can see the content posted in these private groups.
  8. I am using Bootstrap3 for my one page template. I would like to be able to open a link in a bootstrap modal. I can't find a CKeditor modal plugin or something. Tried using the 'ProcessWire Edit Link Process' module, and add target="_modal", so I could strreplace something, but this gets stripped by CKeditor. Any suggestions how I could open a link, created in CKeditor, in a modal?
  9. Thanks Lisandi for the recommendations. I had nginx serve the static files, but this wasn't the fastest option. Now Apache serve the static files, and ik enabled gzip, caching etc. I am familiar with cloudflare for another site I am building. That client has his customers all over the world, so a CDN release benefits. This is all Dutch, so I don't see anly real benefits of cloudflare here. I will look into the SEO module, thanks.
  10. A clean, Basic Foundation website, build using Processwire. Team Training For Professionals The client is happy with the site, and using Repeaterfields and Hannacode makes adding FAQ's piece of cake! This was am "in between" hobby project, but as always took much longer estimated.
  11. I think this is an amazing setup. It was a bit of a steep learning curve for me, it was my first experience programming MVC. I must say it works sweet, changing layouts is a breeze with the logic in the controllers. I love it and thinks this deserves way more attention!
  12. spoetnik

    vs Drupal 8

    D8 has Twig as the template-engine, which is a big plus over the old phptemplate engine. The default html-output will suffer less from div-itus and useless classes. D8 is OO programmed, and uses the Symfony framework for some of its functions. D8 looks to become a bit more complicated to program for than the previous versions. D8 Some good modules a in core now (Views, Configuration management...) Expect D8 version 1 in the first quart of 2015. Don expect to many contrib modules in the first 6 months after this release.
  13. Thanks, I think that I will go for option 1: A new install for each client. There will be no custom instances, so a deployment on based on a Git Pull will work nice. Second question. How would you handle agile development? Not all development takes place in File. Field are created, and added to templates. All in Database. How would I deploy new features to running installs, and not destroy the data in the database?
  14. A "Batch" function, or "background" function would be nice given the following use-case. Process the files from an upload field, and index the processed values in your indexing server. There is no need for the webuser to waith for this processing, it could perfectly happen in the background using shell_exec
  15. I am building a SAAS solution based on Processwire. For example it's an intranet hosted on the internet (just for example) I have the following deployment strategies: 1 Processwire install per client. With separate Databases, Assets folder, and maybe ElasticSearch instances in the future. 1 Processwire install for all clients. A reference field on all templates to a "Client" field, so I can relate content to a client. Set the clientID in the $session for all loged-in users, so I can check their permissions. I am considering the first option for the following reasons: All results from a search action are for the correct Client. Strong separation of confidential content Arguments for the second option would be: Maintenance is much easierAny insights, tips??
×
×
  • Create New...