Skip to content

Commit 1f07231

Browse files
authored
Implement a saver way of running container commands (#8)
- Update compose file to allow webserver is running on a selected port for local testing, also in non-priveleged environments - Try catching exception in running container cmds - Update matrix versions - Split api and database test into separate steps - Remove deprecated eslint comments - Update build version
1 parent b86be8b commit 1f07231

File tree

7 files changed

+1729
-515
lines changed

7 files changed

+1729
-515
lines changed

.github/workflows/main.yml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,16 @@ jobs:
3333
runs-on: ubuntu-latest
3434
strategy:
3535
matrix:
36-
phpipam: ['1.4x','1.5x']
36+
phpipam: ['v1.4x','v1.5x']
3737
steps:
3838
- uses: actions/checkout@v2
39-
- name: run phpipam-action
39+
- name: Run phpipam-action
4040
uses: ./ # use action in the root directory
4141
with:
4242
ipam_version: ${{ matrix.phpipam }}
43-
- name: "Test phpipam api and database"
43+
- name: "Test phpipam api"
4444
run: |
4545
curl -k --user Admin:ipamadmin -X POST https://localhost/api/ansible/user/
46+
- name: "Test database"
47+
run: |
4648
mysql -h 127.0.01 -u ${{ env.IPAM_DATABASE_USER }} -p${{ env.IPAM_DATABASE_PASS }} ${{ env.IPAM_DATABASE_NAME }} --execute="SHOW TABLES"

dist/docker-compose.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ services:
33
phpipam:
44
image: phpipam/phpipam-www:${IPAM_VERSION:-1.4x}
55
ports:
6-
- "443:443"
6+
- "${PHPIPAM_PORT:-443}:443"
77
environment:
88
IPAM_DATABASE_HOST: "${IPAM_DATABASE_HOST:-database}"
99
IPAM_DATABASE_USER: "${IPAM_DATABASE_USER:-phpipam}"

0 commit comments

Comments
 (0)