Skip to content

Commit e542385

Browse files
committed
Some fixes
1 parent 70bf57a commit e542385

File tree

3 files changed

+33
-18
lines changed

3 files changed

+33
-18
lines changed

.depl/config.yaml

Lines changed: 31 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
project_name: deployer
22
version: 7
33
ignore_files:
4-
- .git
54
- .*.kate-swp
5+
- .git
66
- Cargo.lock
77
- target
88
cache_files:
@@ -16,6 +16,7 @@ variables:
1616
value: target/release/depl
1717
actions:
1818
- info: cargo-fmt@0.1.0
19+
exec_in_project_dir: true
1920
action:
2021
type: staged
2122
stage: build
@@ -92,8 +93,6 @@ pipelines:
9293
- ci
9394
- gitlab
9495
- github
95-
exclusive_exec_tag: ci
96-
driver: shell
9796
gh_opts:
9897
on_push_branches:
9998
- stable
@@ -104,21 +103,23 @@ pipelines:
104103
- name: Install Rust Toolchain
105104
uses: actions-rust-lang/setup-rust-toolchain@v1
106105
with:
107-
toolchain: nightly
108106
components: clippy
109107
target: x86_64-unknown-linux-gnu
108+
toolchain: nightly
110109
gl_opts:
111110
rules:
112-
- "$CI_COMMIT_BRANCH == \"unstable\""
113-
- "$CI_COMMIT_BRANCH == \"stable\""
114-
- "$CI_PIPELINE_SOURCE == \"merge_request_event\""
111+
- $CI_COMMIT_BRANCH == "unstable"
112+
- $CI_COMMIT_BRANCH == "stable"
113+
- $CI_PIPELINE_SOURCE == "merge_request_event"
115114
base_image: rust
116115
preflight_cmds:
117-
- "rustup install nightly"
118-
- "rustup component add --toolchain nightly clippy"
116+
- rustup install nightly
117+
- rustup component add --toolchain nightly clippy
118+
exclusive_exec_tag: ci
119119
artifacts:
120120
- from: target/release/depl
121121
to: depl
122+
driver: shell
122123
actions:
123124
- title: Lint
124125
used: cargo-lint@0.1.0
@@ -129,8 +130,6 @@ pipelines:
129130
tags:
130131
- ci
131132
- docker
132-
exclusive_exec_tag: ci-docker
133-
driver: deployer
134133
containered_opts:
135134
preflight_cmds:
136135
- RUN apt-get update && apt-get install -y build-essential curl git && rm -rf /var/lib/apt/lists/*
@@ -148,18 +147,37 @@ pipelines:
148147
- DEPL
149148
- copy_cmds:
150149
- COPY src/ src/
151-
- COPY DOCS.en.md .
152-
- COPY DOCS.ru.md .
150+
- COPY DOCS.md .
153151
- COPY MIGRATIONS.md .
154152
pre_cache_cmds:
155153
- RUN touch src/main.rs
156154
- RUN touch src/lib.rs
157155
- DEPL
158156
use_containerd_local_storage_cache: true
159157
prevent_metadata_loading: true
158+
exclusive_exec_tag: ci-docker
159+
artifacts:
160+
- from: target/release/depl
161+
to: depl
162+
driver: shell
163+
actions:
164+
- title: Lint
165+
used: cargo-lint@0.1.0
166+
- title: Build in release
167+
used: cargo-release@0.1.0
168+
- title: ci-ansible
169+
info: deployer-ci-ansible@0.1.0
170+
tags:
171+
- ci
172+
- docker
173+
ansible_opts:
174+
create_inventory:
175+
- localhost-test
176+
exclusive_exec_tag: ci-ansible
160177
artifacts:
161178
- from: target/release/depl
162179
to: depl
180+
driver: deployer
163181
actions:
164182
- title: Lint
165183
used: cargo-lint@0.1.0

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "deployer"
3-
version = "2.0.0-beta.1"
3+
version = "2.0.0-beta.2"
44
edition = "2024"
55

66
[[bin]]

src/ansible.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -184,10 +184,7 @@ pub fn make_playbook(
184184
.replace("{host-group}", opts.host_group.as_deref().unwrap_or("all"))
185185
.replace("{sudo}", needs_sudo)
186186
.replace("{project_name}", config.project_name.as_str())
187-
.replace(
188-
"{exclude_files}",
189-
if !env.ignore.is_empty() { exclude.as_str() } else { "" },
190-
)
187+
.replace("{exclude_files}", exclude.as_str())
191188
.replace(
192189
"{possible_artifacts}",
193190
if !pipeline.artifacts.is_empty() {

0 commit comments

Comments
 (0)