pd1_tools 0.45.2 → 0.48.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 305e3271b5a66c20ab4141ea5bd0bf80d6e7efa1dfa1f04fafe29cc5f29ea603
4
- data.tar.gz: 8a6ec1d717caed34a7bdb2431f57b4b5717dcd86b5a41879a19e7e8e0fbd815f
3
+ metadata.gz: a111980c747031f68b2c39fcbf051c5c3463645061b3198e7d8ea7fc627f240d
4
+ data.tar.gz: e7ce309ec2c8bb26c938ced74e45e50d8a78f3b28c871eca60ee9481b3ce4c9e
5
5
  SHA512:
6
- metadata.gz: 0f727b46f91027f9f3caad8e463a49df99bf88fb120e99ff15c9ec34c7a7b838c9b10282abd4e6b421cace9e614e40d68e57e1e8f03e4c1954bd9b3ec36f67d0
7
- data.tar.gz: ae72bce282916b9293f705f583afd343ded9ba73853587b92179c5dbb55d5e8b7d252e7c64081163d123186ca181fda5cb952f1da1253e33948f1abb665d196b
6
+ metadata.gz: f09bc45b2ad88e40be7d72bc4836d700b4e19f7c481d1c3735aeb1d443fb6ffc766b3bf39eaac2694319297e5dc282cd14b1dde10fcf3f5183613c27d2ac6f8b
7
+ data.tar.gz: e879bfa81995317485ea7af8e53b98207aa653675a39fced160e8e59dab645fa21dab6b43e475ba837a188b9f9a45d582ce9b3dcf447d3afa42ba37e912fa7a6
@@ -5,12 +5,12 @@ module Avmtrf1
5
5
  class PushLarge
6
6
  class LfsCommit
7
7
  module Push
8
- private
9
-
10
8
  PACK_ERROR_MESSAGE = 'pack exceeds maximum allowed size'
11
9
  PACK_ERROR_TRUE = 'true'
12
10
  PACK_ERROR_FALSE = 'false'
13
11
 
12
+ private
13
+
14
14
  def push_ok_uncached
15
15
  commit
16
16
  fresh_push if push_pack_error_cache.read.blank?
@@ -5,13 +5,13 @@ module Avmtrf1
5
5
  class PushLarge
6
6
  class LfsCommit
7
7
  module TrackLargeFiles
8
- private
9
-
10
8
  EXTENSIONS_REQUIRED_TO_TRACK = %w[
11
9
  bak bkp bmp bpm cfm chm dat db doc fla flv gz jar log mp3 mp4 otf pdf ppt psd rar rtf
12
10
  swf ttf wav wmf wmv wmz woff woff2 xmind z zip
13
11
  ].freeze
14
12
 
13
+ private
14
+
15
15
  def track_large_files_uncached
16
16
  cherry_pick_source_revision
17
17
  if lfs_file_min_size.present?
@@ -40,7 +40,8 @@ module Avmtrf1
40
40
  end
41
41
 
42
42
  def required_extesion_to_track?(file)
43
- EXTENSIONS_REQUIRED_TO_TRACK.include?(::File.extname(file.path).gsub(/\A\./, ''))
43
+ EXTENSIONS_REQUIRED_TO_TRACK.include?(::File.extname(file.path).gsub(/\A\./,
44
+ ''))
44
45
  end
45
46
 
46
47
  def tracked_file?(file)
@@ -7,10 +7,10 @@ module Avmtrf1
7
7
  class PushLarge
8
8
  class SourceCommit
9
9
  module Push
10
- private
11
-
12
10
  LFS_FILE_MIN_SIZES = [nil, 1_048_576, 524_288, 131_072].freeze
13
11
 
12
+ private
13
+
14
14
  def pushed_revision_uncached
15
15
  fs_cache.child('pushed_revision')
16
16
  end
@@ -18,9 +18,7 @@ module Avmtrf1
18
18
  'Quando usando Selenium não mostra a interface gráfica do navegador web.'
19
19
  end
20
20
 
21
- def application
22
- ::Avmtrf1::Tools.application
23
- end
21
+ delegate :application, to: :'::Avmtrf1::Tools'
24
22
 
25
23
  def run
26
24
  ::Aranha::Selenium::DriverFactory::Base.default_headless = parsed.headless?
@@ -9,7 +9,7 @@ module Pd1Tools
9
9
  module DockerImages
10
10
  class Base < ::Pd1Tools::Docker::Image
11
11
  enable_abstract_methods
12
- abstract_methods :mcrypt_install, :xdebug_pecl_package
12
+ abstract_methods :apcu_install, :mcrypt_install, :xdebug_pecl_package
13
13
 
14
14
  GD_OPTIONS = %w[--with-gd --with-webp-dir --with-jpeg-dir --with-png-dir --with-zlib-dir
15
15
  --with-xpm-dir --with-freetype-dir].freeze
@@ -7,6 +7,10 @@ module Pd1Tools
7
7
  module Php
8
8
  module DockerImages
9
9
  class V5 < ::Pd1Tools::Php::DockerImages::Base
10
+ APCU_INSTALL = <<~CODE
11
+ RUN pecl install apcu-4.0.11
12
+ RUN docker-php-ext-enable apcu
13
+ CODE
10
14
  MCRYPT_INSTALL = <<~CODE
11
15
  RUN docker-php-ext-install mcrypt
12
16
  CODE
@@ -23,6 +27,11 @@ module Pd1Tools
23
27
  rm -rf /tmp/xdebug
24
28
  CODE
25
29
 
30
+ # @return [String]
31
+ def apcu_install
32
+ APCU_INSTALL
33
+ end
34
+
26
35
  # @return [String]
27
36
  def apt_setup
28
37
  debian_stretch_apt_setup
@@ -7,6 +7,12 @@ module Pd1Tools
7
7
  module Php
8
8
  module DockerImages
9
9
  class V7 < ::Pd1Tools::Php::DockerImages::Base
10
+ APCU_INSTALL = <<~CODE
11
+ RUN pecl install apcu
12
+ RUN pecl install apcu_bc
13
+ RUN docker-php-ext-enable apcu --ini-name 10-docker-php-ext-apcu.ini
14
+ RUN docker-php-ext-enable apc --ini-name 20-docker-php-ext-apc.ini
15
+ CODE
10
16
  MCRYPT_INSTALL = <<~CODE
11
17
  RUN pecl install mcrypt
12
18
  RUN echo extension=mcrypt.so > "$PHP_INI_DIR/conf.d/mcrypt.ini"
@@ -14,6 +20,11 @@ module Pd1Tools
14
20
  PHP_VERSION = ::Gem::Version.new('7')
15
21
  XDEBUG_PECL_PACKAGE = 'xdebug-3.1.6'
16
22
 
23
+ # @return [String]
24
+ def apcu_install
25
+ APCU_INSTALL
26
+ end
27
+
17
28
  def mcrypt_install
18
29
  MCRYPT_INSTALL
19
30
  end
@@ -7,9 +7,18 @@ module Pd1Tools
7
7
  module Php
8
8
  module DockerImages
9
9
  class V8 < ::Pd1Tools::Php::DockerImages::V7V4
10
+ APCU_INSTALL = <<~CODE
11
+ RUN pecl install apcu
12
+ RUN docker-php-ext-enable apcu
13
+ CODE
10
14
  PHP_VERSION = ::Gem::Version.new('8')
11
15
  XDEBUG_PECL_PACKAGE = 'xdebug'
12
16
 
17
+ # @return [String]
18
+ def apcu_install
19
+ APCU_INSTALL
20
+ end
21
+
13
22
  def xdebug_pecl_package
14
23
  XDEBUG_PECL_PACKAGE
15
24
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Pd1Tools
4
- VERSION = '0.45.2'
4
+ VERSION = '0.48.0'
5
5
  end
@@ -2,8 +2,15 @@ FROM php:%%PLATFORM_VERSION%%-apache
2
2
 
3
3
  %%APT_SETUP%%
4
4
 
5
- # Apache HTTP
5
+ # Apache HTTPD
6
+ RUN apt-get install -y ssl-cert
6
7
  RUN a2enmod rewrite
8
+ RUN echo 'ServerTokens Prod' > /etc/apache2/conf-available/zzz_after.conf
9
+ RUN echo 'ServerSignature Off' >> /etc/apache2/conf-available/zzz_after.conf
10
+ RUN a2enconf zzz_after
11
+
12
+ # Extensão PHP "apcu"
13
+ %%APCU_INSTALL%%
7
14
 
8
15
  # Extensão PHP "bcmath"
9
16
  RUN docker-php-ext-install bcmath
@@ -18,7 +25,7 @@ RUN apt-get install -y libfreetype6-dev libjpeg62-turbo-dev libpng-dev libwebp-d
18
25
  RUN docker-php-ext-configure gd %%GD_OPTIONS%%
19
26
  RUN docker-php-ext-install gd
20
27
 
21
- # Extensão PHP "intl"
28
+ # Extensão PHP "imap"
22
29
  RUN apt-get install -y libc-client-dev libkrb5-dev
23
30
  RUN docker-php-ext-configure imap --with-kerberos --with-imap-ssl
24
31
  RUN docker-php-ext-install imap
@@ -36,37 +43,10 @@ RUN docker-php-ext-install ldap
36
43
  RUN apt-get install -y libmcrypt-dev
37
44
  %%MCRYPT_INSTALL%%
38
45
 
39
- # Extensão PHP "pcntl"
40
- RUN docker-php-ext-install pcntl
46
+ # Extensão PHP "mysqli"
47
+ RUN docker-php-ext-install mysqli
41
48
 
42
- # Extensão PHP "snmp"
43
- RUN apt-get install -y libsnmp-dev snmp
44
- RUN docker-php-ext-install snmp
45
-
46
- # Extensão PHP "soap"
47
- RUN apt-get install -y libxml2-dev
48
- RUN docker-php-ext-install soap
49
-
50
- # Extensão PHP "xdebug"
51
- %%XDEBUG_INSTALL%%
52
- RUN docker-php-ext-enable xdebug
53
-
54
- # Extensão PHP "xsl"
55
- RUN apt-get install -y libxslt1-dev
56
- RUN docker-php-ext-install xsl
57
-
58
- # Extensão PHP "zip"
59
- RUN apt-get install -y libzip-dev
60
- RUN docker-php-ext-install zip
61
-
62
- # Extensões MySql
63
- RUN docker-php-ext-install mysqli pdo_mysql
64
-
65
- # Extensões PHP PostgreSQL
66
- RUN apt-get install -y libpq-dev
67
- RUN docker-php-ext-install pdo_pgsql pgsql
68
-
69
- # Extensão PHP oci
49
+ # Extensão PHP "oci8"
70
50
  RUN apt-get install -y libarchive-tools libaio1
71
51
  RUN curl -sS https://raw.githubusercontent.com/caffeinalab/php-fpm-oci8/master/oracle/instantclient-basic-linux.x64-12.2.0.1.0.zip | bsdtar -xvf- -C /usr/local
72
52
  RUN curl -sS https://raw.githubusercontent.com/caffeinalab/php-fpm-oci8/master/oracle/instantclient-sdk-linux.x64-12.2.0.1.0.zip | bsdtar -xvf- -C /usr/local
@@ -78,6 +58,12 @@ RUN ln -s /usr/local/instantclient/sqlplus /usr/bin/sqlplus
78
58
  RUN docker-php-ext-configure oci8 --with-oci8=instantclient,/usr/local/instantclient
79
59
  RUN docker-php-ext-install oci8
80
60
 
61
+ # Extensão PHP "pcntl"
62
+ RUN docker-php-ext-install pcntl
63
+
64
+ # Extensão PHP "pdo_mysql"
65
+ RUN docker-php-ext-install pdo_mysql
66
+
81
67
  # Extensão PHP pdo_oci
82
68
  RUN mkdir /tmp/php_source
83
69
  RUN curl %%PHP_DIST_CURL_ARGS%% | \
@@ -90,18 +76,42 @@ RUN make install
90
76
  RUN echo extension=pdo_oci.so > "$PHP_INI_DIR/conf.d/pdo_oci.ini"
91
77
  RUN echo 'date.timezone = "America/Sao_Paulo"' >> "$PHP_INI_DIR/php.ini"
92
78
 
79
+ # Extensão PHP "pdo_pgsql"
80
+ RUN apt-get install -y libpq-dev
81
+ RUN docker-php-ext-install pdo_pgsql
82
+
83
+ # Extensão PHP "pgsql"
84
+ RUN docker-php-ext-install pgsql
85
+
86
+ # Extensão PHP "snmp"
87
+ RUN apt-get install -y libsnmp-dev snmp
88
+ RUN docker-php-ext-install snmp
89
+
90
+ # Extensão PHP "soap"
91
+ RUN apt-get install -y libxml2-dev
92
+ RUN docker-php-ext-install soap
93
+
94
+ # Extensão PHP "xdebug"
95
+ %%XDEBUG_INSTALL%%
96
+ RUN docker-php-ext-enable xdebug
97
+
98
+ # Extensão PHP "xsl"
99
+ RUN apt-get install -y libxslt1-dev
100
+ RUN docker-php-ext-install xsl
101
+
102
+ # Extensão PHP "zip"
103
+ RUN apt-get install -y libzip-dev
104
+ RUN docker-php-ext-install zip
105
+
93
106
  # Composer
94
107
  RUN apt-get install -y git unzip
95
108
  RUN curl -sS https://getcomposer.org/installer | \
96
109
  php -- --install-dir=/usr/local/bin --filename=composer
97
110
 
98
- # SSL
99
- RUN apt-get install -y ssl-cert
100
-
101
111
  # Inicializador
102
112
  RUN mkdir '/aux'
103
113
  RUN mkdir '/aux/eac-bash-lib'
104
- RUN curl -sS https://codeload.github.com/esquilo-azul/eac-bash-lib/tar.gz/refs/tags/v0.17.1 \
114
+ RUN curl -sS https://codeload.github.com/esquilo-azul/eac-bash-lib/tar.gz/refs/tags/v0.27.0 \
105
115
  | tar -xzf - --strip-components 1 -C '/aux/eac-bash-lib'
106
116
  ADD aux '/aux'
107
117
  CMD '/aux/start.sh'
@@ -17,6 +17,8 @@ function setup_site() {
17
17
  a2ensite "${2}"
18
18
  }
19
19
 
20
+ export APACHE_SITE_COMMONS="$(template_apply "$TEMPLATES_ROOT/apache_site_commons.conf")"
21
+
20
22
  infom "Configuração site Apache..."
21
23
  setup_site 'apache_site_nossl' '000-default'
22
24
  setup_site 'apache_site_ssl' 'default-ssl'
@@ -0,0 +1,12 @@
1
+ DocumentRoot "%%DOCUMENT_ROOT%%"
2
+
3
+ ErrorLog ${APACHE_LOG_DIR}/error.log
4
+ CustomLog ${APACHE_LOG_DIR}/access.log combined
5
+
6
+ <Directory %%DOCUMENT_ROOT%%>
7
+ Options Indexes FollowSymLinks
8
+ AllowOverride All
9
+ Require all granted
10
+ </Directory>
11
+
12
+ RedirectMatch 404 /\.
@@ -1,12 +1,3 @@
1
1
  <VirtualHost *:80>
2
- DocumentRoot %%DOCUMENT_ROOT%%
3
-
4
- ErrorLog ${APACHE_LOG_DIR}/error.log
5
- CustomLog ${APACHE_LOG_DIR}/access.log combined
6
-
7
- <Directory %%DOCUMENT_ROOT%%>
8
- Options Indexes FollowSymLinks
9
- AllowOverride All
10
- Require all granted
11
- </Directory>
2
+ %%APACHE_SITE_COMMONS%%
12
3
  </VirtualHost>
@@ -3,14 +3,5 @@
3
3
  SSLCertificateFile "%%SSL_CERTIFICATE_FILE%%"
4
4
  SSLCertificateKeyFile "%%SSL_CERTIFICATE_KEY_FILE%%"
5
5
 
6
- DocumentRoot "%%DOCUMENT_ROOT%%"
7
-
8
- ErrorLog ${APACHE_LOG_DIR}/error.log
9
- CustomLog ${APACHE_LOG_DIR}/access.log combined
10
-
11
- <Directory %%DOCUMENT_ROOT%%>
12
- Options Indexes FollowSymLinks
13
- AllowOverride All
14
- Require all granted
15
- </Directory>
6
+ %%APACHE_SITE_COMMONS%%
16
7
  </VirtualHost>
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pd1_tools
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.45.2
4
+ version: 0.48.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Eduardo H. Bogoni
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2025-02-10 00:00:00.000000000 Z
11
+ date: 2025-02-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: aranha-parsers
@@ -543,6 +543,7 @@ files:
543
543
  - template/pd1_tools/php/docker_images/base/aux/setup_apache_modules.sh
544
544
  - template/pd1_tools/php/docker_images/base/aux/setup_apache_sites.sh
545
545
  - template/pd1_tools/php/docker_images/base/aux/start.sh
546
+ - template/pd1_tools/php/docker_images/base/aux/templates/apache_site_commons.conf
546
547
  - template/pd1_tools/php/docker_images/base/aux/templates/apache_site_nossl.conf
547
548
  - template/pd1_tools/php/docker_images/base/aux/templates/apache_site_ssl.conf
548
549
  - template/pd1_tools/php/docker_images/base/aux/variables.sh