Commit graph

40 commits

Author SHA1 Message Date
snipe
71d8f1eb89
Merge pull request #16701 from grokability/repo-move
Update references to the repo to reflect move to Grokability org
2025-04-15 19:54:08 +01:00
Jeremy Price
b00594052c [Docker] Don't cache composer deps, remove any .git repos that creep in
There is a failure mode in composer where if it has a connection trying to get
a dependency tarball from the github API, it will fall-back to
downloading the entire repo for the dependency and use that... and it
will cache it outside of vendor/, using a whopping 1.5G of space

that full 1.5G is _then_ copied into vendor/

```
98M     league
100M	tecnickcom
133M	laravel
323M	sebastian
681M	aws
```

for a total of a 1.8G vendor/ directory

vs the trimmed-down version with a 552M vendor/ directory

```
53M	league
30M	tecnickcom
31M	laravel
70M	sebastian
241M	aws
```

This is still a far cry from the proper 150M version when everything
works as it should, but it's still a vast improvement

```
3.2M    league
14M     laravel
30M     tecnickcom
260K	sebastian
52M     aws
```

Ideally this never happens, but it'd be great tp avoid the bloat if/when
it does..

To wit: Our ARM/Ubuntu Docker images are currently bloated because of this
issue due builds happening on an emulated ARM environment, and the resultant
performance penalties causing composer issues

All that to say, this change sets OMPOSER_CACHE_DIR to /dev/null to
avoid the caching, and then removes vendor/*/*/.git to remove that
needless bloat if it occurs. It's a no-op in general practice.
2025-04-14 11:55:20 -07:00
Jeremy Price
70e9c6b947 Update relevant snipe/snipe-it references to grokability/snipe-it in Docker files 2025-04-03 11:44:27 -07:00
Brady Wetherington
271bcc66bf Remove lib-mcrypt as a dependency 2025-02-24 23:19:08 +00:00
snipe
4800f4c853
Merge branch 'develop' into remove_mcrypt 2025-02-24 22:12:56 +00:00
Brady Wetherington
5e85891b10 Updated default Dockerfile to handle newer PHP versions 2025-02-22 12:43:30 +00:00
snipe
99526cfc2c Remove mcrypt and legacy recrypter
Signed-off-by: snipe <snipe@snipe.net>
2025-01-13 19:54:00 +00:00
Lee Porte
6783dc1312 Fixed #12299: permissions on storage dir in Docker
Fixes #12299, where currently there is no recursive permissions set on
/var/www/html/storage/ during build time. As a result this requires
users to run an exec into the container and change the permissions
before they are able to initiate the setup. Without this a 500 error is
thrown and little is evident in the docker logs as to what the issue
is.
2024-05-22 16:54:07 +01:00
snipe
dc43985884 Applied #13143 to develop
Signed-off-by: snipe <snipe@snipe.net>
2023-06-12 14:05:26 +01:00
Joe Ferguson
1d8a4ca090
Update Dockerfile to Ubuntu 22.04 and PHP 8.1 2023-04-14 07:59:16 -05:00
Iisakki Jaakkola
9452973845
Added php memcached extension to the docker image. 2022-10-25 16:16:25 +03:00
Raden Farid Nugraha
c3698053ea Fixed ( #10910 ) : Add php redis extension 2022-06-06 06:58:07 +07:00
Brady Wetherington
b96303cb38 Clean up errors, add new required package to Dockerfile 2022-03-07 19:51:21 -08:00
Tom Misilo
fb585955b4 Replace .my.cnf with column-statistics.cnf at the system level for mysqldump
Fixes #10176

The `column-statistics.cnf` file is copied to `/etc/mysql/conf.d/column-statistics.cnf` for each Dockerfile that exists.

This puts it as a system level mysql client change, so the web ui interface also works.
2022-01-29 07:24:50 -06:00
Thomas Misilo
930666ffa0 Adding .my.cnf to disable column-statistics backup
Fixes #10176

The ```.my.cnf``` file is copied to ```/root/.my.cnf``` for each
Dockerfile that exists
2022-01-13 14:36:00 -06:00
snipe
f2f8f96991 Merge remote-tracking branch 'origin/master' into develop
Signed-off-by: snipe <snipe@snipe.net>

# Conflicts:
#	app/Http/Controllers/Api/AssetsController.php
#	app/Http/Transformers/AssetsTransformer.php
#	app/Importer/ConsumableImporter.php
#	app/Models/Consumable.php
#	config/version.php
#	package-lock.json
#	package.json
#	public/css/dist/all.css
#	public/css/dist/bootstrap-table.css
#	public/js/build/app.js
#	public/js/dist/all.js
#	public/js/dist/bootstrap-table.js
#	public/mix-manifest.json
#	resources/views/custom_fields/fieldsets/view.blade.php
#	resources/views/layouts/default.blade.php
#	routes/web.php
#	routes/web/fields.php
2021-11-15 19:24:38 -08:00
Andrew Shulgin
d3ddafdff4
Dockerfile: symlink for ldap_client_tls.{cert,key} 2021-11-13 03:00:09 +02:00
Sajjad
f036e2b2a3 Specify docker images versions
Fix unquoted sentences
2021-10-03 11:12:53 +03:30
Brady Wetherington
37fe4e91b1 Upgrade Docker to PHP 7.4 2021-09-13 15:24:30 -07:00
snipe
105f57e059 Possible fix for Docker failing on master
Signed-off-by: snipe <snipe@snipe.net>
2021-04-06 06:09:04 -07:00
snipe
7da32443ff Move develop fixes to master
Signed-off-by: snipe <snipe@snipe.net>
2021-04-06 05:05:16 -07:00
Jan Kiesewetter
d61d189328
Change owner while copy (#7552)
* Change owner while copy

Copy all files and chown them in a 2nd layer leads to a larger image.
See layer 22 and 26 of https://hub.docker.com/layers/snipe/snipe-it/v4.7.8/images/sha256-67c865d91df1b90cef1112f12bbc9c64402dfeafde0bdb160c4f07e785ee0bcc

* Copy docker.env as user docker
2021-04-05 21:15:54 -07:00
Peter Dave Hello
ca8b152549
Remove unnecessary apt-get clean in Dockerfile (#9201)
This image is built from the official Debian image as upstream, so there
is no need to do apt-get clean manually.

Ref:
- docs.docker.com/develop/develop-images/dockerfile_best-practices/#apt-get

> Official Debian and Ubuntu images automatically run apt-get clean, so
> explicit invocation is not required.
2021-03-17 20:33:54 -07:00
snipe
bca82684a1 Merge branch 'hotfixes/2fa_qr' into develop
# Conflicts:
#	.all-contributorsrc
#	Dockerfile
#	README.md
#	app/Console/Commands/LdapSync.php
#	app/Http/Controllers/Api/ImportController.php
#	app/Http/Controllers/AssetModelsController.php
#	app/Http/Controllers/Assets/AssetsController.php
#	app/Http/Controllers/Auth/LoginController.php
#	app/Http/Controllers/CategoriesController.php
#	app/Http/Controllers/CompaniesController.php
#	app/Http/Controllers/DepartmentsController.php
#	app/Http/Controllers/ImportsController.php
#	app/Http/Controllers/LocationsController.php
#	app/Http/Controllers/ManufacturersController.php
#	app/Http/Controllers/SuppliersController.php
#	app/Http/Requests/ItemImportRequest.php
#	app/Http/Transformers/ActionlogsTransformer.php
#	composer.json
#	composer.lock
#	config/app.php
#	config/version.php
#	docker/startup.sh
#	public/css/build/all.css
#	public/css/dist/all.css
#	public/js/build/all.js
#	public/js/build/vue.js
#	public/js/build/vue.js.map
#	public/js/dist/all.js
#	public/mix-manifest.json
2019-03-20 02:17:02 -07:00
Jonathon Reinhart
e59ec8b27f Run Laravel schedule in docker image using supervisord (#6606)
* docker: Rename /entrypoint.sh to /startup.sh

This script is not configured as the docker image ENTRYPOINT, thus it is
misleading to name it so.

* docker: Terminate supervisord if a process enters the FATAL state

By terminating PID 1, this will also terminate the Docker container.

* docker: Use supervisord to start up apache and cron

Note that this uses `apache2ctl -DFOREGROUND` rather than manually
sourcing /etc/apache2/envvars and running apache2, as recommended at
https://advancedweb.hu/2018/07/03/supervisor_docker/.

* docker: Add artisan schedule:run to crontab

This also switches to executing /var/www/html/artisan directly.

* docker: Run artisan schedule:run directly from supervisor

This has the following benefits over using cron:
- Cron doesn't need to be installed
- Docker-provided environment variables are preserved
- It's easy and explicit to run as the docker user
2019-03-07 12:42:00 -08:00
Colin Campbell
f8d9301bd4 fix-docker-pecl: Fix Dockerfile after pear.php.net hack (#6641) 2019-01-25 13:41:39 -08:00
Kasey
5e06d53d8c buildable dockerfile (#6525)
Awesome, thanks!
2018-12-17 15:29:05 -08:00
Earl Ramirez
ef1e8df001 Disable file browsing (#5922)
* Added cron to list of packages

* Disable file browsing from the public directory
2018-07-23 20:40:04 -07:00
Earl Ramirez
fa465a84df Added cron to list of packages (#5729) 2018-06-20 23:28:35 -07:00
Brady Wetherington
a6fc7ba07a Remove silly docker.env file; fix Dockerfile to preserve Oauth keys (#5377) 2018-04-16 16:29:42 -07:00
Brady Wetherington
cef67695cd New Dockerfile fixes to add support for the new barcode library (#3856) 2017-08-16 13:10:25 -07:00
snipe
2d3ea4eec6 Apply PR #3616 (Docker updates) 2017-06-01 20:53:01 -07:00
Kasey
5663429280 applying PR #3456 changes to develop branch (#3472)
* updating with changes made to master

apply PR # 3456 to develop as well

* updating develop with changes made to master

apply PR # 3456 to develop as well

* updating paveit with passport-created oauth tables
2017-03-31 15:43:37 -07:00
snipe
e74a0171a6 Fixes dockerfile for persistent assets 2016-11-11 20:30:04 -08:00
snipe
7ecb8d7bc1 Patches PR#2526 to develop 2016-08-30 12:13:29 -07:00
Brady Wetherington
093bcdfe4f Fix to Dockerfile build; backup path must've changed. 2016-06-02 21:10:50 -07:00
Brady Wetherington
008482203e Fixes to Dockerfile, updated docker/develop.sh for new options. 2016-05-14 16:46:53 -07:00
Brady Wetherington
f03ecd9d08 Update docker support for upcoming v3 2016-05-14 15:43:46 -07:00
Brady Wetherington
a2ebc0d983 Pin down Ubuntu version for dockerfile in v3 2016-05-05 12:45:00 -07:00
snipe
fe00b0e401 Version 3 - hold onto your butts 2016-03-25 01:18:05 -07:00