ci: install colmena

This commit is contained in:
silver 2023-08-09 20:45:33 +01:00
parent fa13fc1397
commit a2d16e60f4

View file

@ -28,7 +28,7 @@ update:
- git config --global user.email "${CI_EMAIL}" - git config --global user.email "${CI_EMAIL}"
- git config --global user.name "${CI_USERNAME}" - git config --global user.name "${CI_USERNAME}"
# the part that updates the flake # the part that updates the flake
- nix --experimental-features 'nix-command flakes' flake lock --update-input $PACKAGE_NAME - nix flake lock --update-input $PACKAGE_NAME
- git add flake.lock - git add flake.lock
- git commit -m "[skip ci] Updated flake for $PACKAGE_NAME" || echo "No changes, nothing to commit" - git commit -m "[skip ci] Updated flake for $PACKAGE_NAME" || echo "No changes, nothing to commit"
# we have a custom domain # we have a custom domain
@ -44,6 +44,7 @@ update:
# load nix environment # load nix environment
- . "$HOME/.nix-profile/etc/profile.d/nix.sh" - . "$HOME/.nix-profile/etc/profile.d/nix.sh"
- git pull origin $CI_COMMIT_REF_NAME - git pull origin $CI_COMMIT_REF_NAME
- nix-shell -p colmena
.scripts_deploy: &scripts_deploy .scripts_deploy: &scripts_deploy
# setup ssh key # setup ssh key
@ -79,7 +80,7 @@ build:
<<: *builder <<: *builder
stage: test stage: test
script: script:
- nix --experimental-features 'nix-command flakes' run nixpkgs#colmena -- build - colmena build
# dns always has to be deployed first # dns always has to be deployed first
deploy_dns: deploy_dns:
@ -87,7 +88,7 @@ deploy_dns:
<<: *deployment <<: *deployment
stage: deploy stage: deploy
script: script:
- nix --experimental-features 'nix-command flakes' run nixpkgs#colmena -- apply --on @active-dns - colmena apply --on @active-dns
deploy_core: deploy_core:
<<: *builder <<: *builder
@ -96,7 +97,7 @@ deploy_core:
needs: needs:
- deploy_dns - deploy_dns
script: script:
- nix --experimental-features 'nix-command flakes' run nixpkgs#colmena -- apply --on @active-core - colmena apply --on @active-core
deploy_active: deploy_active:
<<: *builder <<: *builder
@ -105,12 +106,12 @@ deploy_active:
needs: needs:
- deploy_dns - deploy_dns
script: script:
- nix --experimental-features 'nix-command flakes' run nixpkgs#colmena -- apply --on @active - colmena apply --on @active
deploy_gitlab: deploy_gitlab:
<<: *builder <<: *builder
<<: *deployment <<: *deployment
stage: deploy_gitlab stage: deploy_gitlab
script: script:
- nix --experimental-features 'nix-command flakes' run nixpkgs#colmena -- apply --on @active-gitlab - colmena apply --on @active-gitlab
when: manual when: manual