Difference between #136 and #137 of
Yii v2 snippet guide

Revision #137 has been created by rackycz on Oct 4, 2019, 4:12:47 PM with the memo:

edit
« previous (#136) next (#138) »

Changes

Title unchanged

Yii v2 snippet guide

Category unchanged

Tutorials

Yii version unchanged

2.0

Tags unchanged

tutorial,beginner,yii2

Content changed

[...]
You only need to create 1 file in your GitLab repository. It is named .gitlab-ci.yml and it should contain following code:

```
variables:
HOST: "
url.to.my.ftpexample.com:21" USERNAME: "your_username" PASSWORD: "your_password" FOLDER: "relative path if needed or just ././project_root/web" deploy: script: - apt-get update -qq && apt-get install -y -qq lftp - lftp -c "set ftp:ssl-allow no; open -u $USERNAME,$PASSWORD $HOST; mirror -Rnev ./ $FOLDER --ignore-time --parallel=10 --exclude-glob .git* --exclude .git/" --exclude vendor --exclude web/assets --exclude web/index.php --exclude web/index-test.php"  only: - master ``` I just added **--exclude vendor**some exclusions (listed below) and will probably add **--delete** in the future. Read linked webs.  
- exclude vendor = huge folder with 3rd party SW which is not in GIT
 
- exclude web/assets = also some cache
 
- exclude web/index.php = in GIT is your devel index witn DEBU mode enabled. You dont wanna have this file in productive environment
 
- exclude web/index-test.php = tests are only on your computer and in GIT


**User management + DB creation + login via DB**
[...]
**Saving contact inqueries into DB**
---
```
SQLsql
DROP TABLE IF EXISTS `contact` ;

CREATE TABLE IF NOT EXISTS `contact` (
`id` INT NOT NULL AUTO_INCREMENT,
`name` VARCHAR(45) NOT NULL,
[...]
7 0
4 followers
Viewed: 274 816 times
Version: 2.0
Category: Tutorials
Written by: rackycz
Last updated by: rackycz
Created on: Sep 19, 2019
Last updated: a year ago
Update Article

Revisions

View all history