2025-02-07 20:51:52 +01:00
|
|
|
when:
|
|
|
|
- branch: main
|
|
|
|
event: push
|
|
|
|
|
|
|
|
steps:
|
2024-02-02 21:46:22 +01:00
|
|
|
update:
|
|
|
|
image: earthly/earthly:v0.8.1
|
|
|
|
volumes:
|
|
|
|
- /var/run/docker.sock:/var/run/docker.sock
|
|
|
|
environment:
|
2025-02-07 20:51:52 +01:00
|
|
|
FORCE_COLOR: 1
|
|
|
|
EARTHLY_EXEC_CMD: "/bin/sh"
|
|
|
|
EARTHLY_CONFIGURATION:
|
|
|
|
from_secret: EARTHLY_CONFIGURATION
|
|
|
|
SSH_CONFIG:
|
|
|
|
from_secret: SSH_CONFIG
|
|
|
|
SSH_UPLOAD_KEY:
|
|
|
|
from_secret: SSH_UPLOAD_KEY
|
|
|
|
SSH_KNOWN_HOSTS:
|
|
|
|
from_secret: SSH_KNOWN_HOSTS
|
|
|
|
SSH_TARGET:
|
|
|
|
from_secret: SSH_TARGET
|
2024-02-02 21:46:22 +01:00
|
|
|
commands:
|
|
|
|
- mkdir ~/.earthly && echo "$EARTHLY_CONFIGURATION" > ~/.earthly/config.yaml
|
|
|
|
- earthly bootstrap
|
|
|
|
- earthly --secret SSH_CONFIG --secret SSH_UPLOAD_KEY --secret SSH_KNOWN_HOSTS --secret SSH_TARGET --push +deploy
|
|
|
|
when:
|
|
|
|
branch: ["main"]
|