1
0
mirror of https://github.com/Mailu/Mailu.git synced 2024-12-14 10:53:30 +02:00
Commit Graph

56 Commits

Author SHA1 Message Date
Florent Daigniere
e79d7fed55 Reduce the number of warnings on the CI 2022-11-17 16:21:52 +01:00
Dimitri Huisman
2a3266b6b8
Forgot to update both deploy jobs 2022-11-04 14:13:06 +01:00
Dimitri Huisman
b2e47642f7
Tag the images with latest tag as well. 2022-11-04 13:49:05 +01:00
Florent Daigniere
3e9def6cd9 Use the new notation: arm64/v8 instead of arm64 2022-11-04 10:46:45 +01:00
Dimitri Huisman
db7ce8c83e
Login docker.io to prevent rate limiting for pulling images 2022-11-01 15:18:03 +00:00
Dimitri Huisman
b3151e9904
Actually push the build arm images to ghcr.io 2022-11-01 14:36:17 +00:00
Dimitri Huisman
6549dbf247
Sigh. needs.* context is only available if you include it in needs: 2022-11-01 10:56:33 +00:00
Dimitri Huisman
c7cba1b075
Finishing touches for fixing arm builds
- Use self-hosted runners for arm base image
- Use seperate docker image cache for arm build
- Remove unneeded needs items.
2022-11-01 10:49:44 +00:00
Dimitri Huisman
e915e444e9
Remove superfluous cache export entry for arm 2022-11-01 09:38:14 +00:00
Dimitri Huisman
4be0cbf4da
Switch workflow to ghcr.io
- Build images & build cache are pushed to ghcr.io.
- Tests will make use of the images pushed to ghcr.io.
- Deploy step only copies images from ghcr.io to docker.io.
- Resolves strange build errors tied to buildx+intermediate builds
- Results in quicker build times.
2022-10-28 11:52:49 +00:00
Dimitri Huisman
451738e32b We want the function result. Not the function statement. 2022-10-19 11:35:57 +00:00
Dimitri Huisman
f9ba0e688f Removed syntax error 2022-10-19 11:25:42 +00:00
Dimitri Huisman
92cb8c146b Refine build_test_deploy.yml:
Build base image before the other images.
Change cache key to make it is re-used for all builds. This is not
dangerous. The docker build process can determine itself whether
a cache can be safely re-used or not.
2022-10-19 11:02:22 +00:00
Florent Daigniere
254277a829
runner.temp is what should be used 2022-09-01 14:45:44 +02:00
Dimitri Huisman
22fe65e4d8 Use RUNNER_TEMP for storing cache files. 2022-09-01 12:39:23 +00:00
Dimitri Huisman
56d0e795eb
Push arm images via arm self-hosted runner 2022-08-31 21:07:27 +02:00
Dimitri Huisman
d76d3b4959 Switch to ARM64 self-hosted for ARM build 2022-08-31 18:17:45 +00:00
Dimitri Huisman
5732b2316f Switch to local build cache, cached via actions/cache@v3
The previous method of using gha cache via buildx proved to be
unreliable. Using local cache via actions/cache@v3 is much more
reliable.
The build job will re-use cache from previous workflow runs.
The total workflow time is still similar ~12 minutes.
2022-08-23 21:09:03 +00:00
Dimitri Huisman
312a733ae3 prefix the cache key with a hash (to help with sharding) 2022-08-20 09:18:54 +00:00
Dimitri Huisman
f35d82b3a0 Also ${{ github.run_id }} for cache key.
This makes rue that the cache key is unique across workflow runs
2022-08-20 08:51:56 +00:00
Dimitri Huisman
d56eb16f52 Hotfix for workflow. For build step do not build from cache.
Make sure cache layers are unique by using ${{ github.ref }}
2022-08-20 08:43:27 +00:00
Dimitri Huisman
dd3f1a3376 Switch to mode=min for GHA cache for docker buildx to prevent ratelimiting in GHA workflow 2022-08-20 07:49:36 +00:00
Dimitri Huisman
ae18217e07 Fix adding -arm tag correctly to PINNED_MAILU_VERSION in arm.yml. 2022-08-03 13:15:32 +00:00
Dimitri Huisman
7e21ab4007 Merge master cont'd 2022-08-03 09:48:54 +00:00
Dimitri Huisman
f6de2b2938 Switch from docker build to buildx for CI/CD.
- The main workflow file has been optimised and simplified.
- Images are built in parallel when building locally resulting in faster build times.
- The github action workflow is about 50% faster.
- Arm images are built as well. These images are not tested due to restrictions of github actions (no arm runners). The tags of the images have -arm appended to it.
- Arm images can also be built locally.
- Reusable workflow is introduced for building, testing and deploying the images.
  This allows the workflow to be reused for other purposes in the future.
- Workflow can be manually triggered. This allows forked Mailu projects to also use the workflow for building images.
2022-08-03 09:36:53 +00:00
Dimitri Huisman
413ecea479 Switched from "$(/usr/bin/git log -1 --format='%H')" to "$(/usr/bin/git rev-parse HEAD)" 2022-01-26 15:54:20 +00:00
Dimitri Huisman
5cef8925dc Remove superfluous parentheses 2022-01-25 11:42:22 +00:00
Dimitri Huisman
cf328cdf33 Tag for release is correctly tagged to branch x.y. 2022-01-25 10:14:53 +00:00
Dimitri Huisman
b4d3d4b3c9 Preparations for 1.9 release. 2021-12-29 14:40:45 +00:00
Dimitri Huisman
2efad07c0b Merge branch 'master' of github.com:Diman0/Mailu into remove-mailu-postgresql 2021-12-15 10:00:47 +00:00
Dimitri Huisman
15e64e8e50 Add concurrency to ensure that only a single workflow can run for a branch. 2021-12-06 15:22:42 +00:00
Dimitri Huisman
9eba2feae2 Remove Mailu PostgreSQL from CI.yml. 2021-12-01 16:26:44 +00:00
Dimitri Huisman
f7677543c6 Process code review remarks
- Moved run to bottom of Dockerfile to allow using unmodified / cached states.
- Simplified bash code in deploy.sh.
- Improved the large bash one-liner in CI.yml. It could not handle >9 for 1.x.
2021-11-18 17:21:56 +00:00
Dimitri Huisman
56dd70cf4a Implement versioning for CI/CD workflow (see #1182). 2021-11-17 20:00:04 +00:00
Dimitri Huisman
b20d0a83d5 Doh! 2021-11-15 16:17:31 +00:00
Dimitri Huisman
b391692698 It is handy to close strings. 2021-11-15 15:44:31 +00:00
Dimitri Huisman
e2512c7cdc Testing images are pushed to DOCKER_ORG_TESTS again. 2021-11-15 15:34:38 +00:00
Diman0
3157fc3623 Give docker containers in each test one more minute for starting. 2021-08-07 09:27:47 +02:00
Dimitri Huisman
609e0f9f7c
Env vars are not shared between jobs 2021-08-05 00:12:37 +02:00
Dimitri Huisman
c3f47f1ca0 Forgot that env var set in job 1 is not shared with job 2. Added logic for deriving MAILU_VERSION to deploy job. 2021-07-05 17:44:10 +00:00
Dimitri Huisman
58e751415c Yet another small typo. One day computers will understand I meant env.MAILU_BRANCH instead of MAILU_BRANCH. 2021-07-05 17:21:28 +00:00
Dimitri Huisman
7aa9b496fa Moved logic for building testing images from deploy job to build job. This should save time. Test number for ci workflow #1234 2021-07-05 17:09:48 +00:00
Dimitri Huisman
1566dfb077
Forgot to add condition to load docker images step 2021-06-29 08:58:44 +02:00
Dimitri Huisman
b2840fed26
Update CI.yml 2021-06-28 22:51:23 +02:00
Dimitri Huisman
cf894dae03
Merge branch 'Mailu:master' into test-ci-parallel 2021-06-28 22:50:34 +02:00
Dimitri Huisman
75ee2cd1f7
Added manual trigger for workflow
Workflow file only triggers if it resides in the branch. If an old PR based on the mailu repo without CI.yml is tested, then the workflow run will not trigger. The merged commit on TESTING/STAGING branch does not contain the required CI.yml workflow file after all. In these cases simply run the workflow manually on the TESTING or STAGING branch,
2021-06-28 22:38:01 +02:00
Dimitri Huisman
c2b1f23652 It helps to also load the docker images for the tests. 2021-06-27 09:44:38 +00:00
Dimitri Huisman
c6da021106 Forgot to adapt all creat folder steps 2021-06-27 09:31:39 +00:00
Dimitri Huisman
782ffc084f Fixed typo 2021-06-27 09:26:11 +00:00
Dimitri Huisman
0468fb2064 Forgot to set permissions on images folder. Added changelog. 2021-06-27 09:24:17 +00:00